From: David Seifried Date: Mon, 26 Sep 2011 18:45:20 +0000 (-0400) Subject: Fixed merge conflict X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=d8123b91e1a1cce0623b21e8372bab80a648afeb;p=popcorn-js.git Fixed merge conflict --- d8123b91e1a1cce0623b21e8372bab80a648afeb diff --cc plugins/attribution/popcorn.attribution.unit.html index 92524a8,0f6879d..b3f4b7c --- a/plugins/attribution/popcorn.attribution.unit.html +++ b/plugins/attribution/popcorn.attribution.unit.html @@@ -21,23 -21,27 +21,30 @@@

    - - -
    + +
    diff --cc plugins/code/popcorn.code.js index 214185f,25200ff..205fae7 --- a/plugins/code/popcorn.code.js +++ b/plugins/code/popcorn.code.js @@@ -68,22 -68,20 +68,20 @@@ * */ - Popcorn.plugin( 'code' , function(options) { + Popcorn.plugin( "code" , function( options ) { var running = false; - + // Setup a proper frame interval function (60fps), favouring paint events. - var step = ( function() { - + var step = (function() { + var buildFrameRunner = function( runner ) { return function( f, options ) { - + var _f = function() { - f(); - if ( running ) { - runner( _f ); - } + running && f(); + running && runner( _f ); }; - + _f(); }; }; diff --cc plugins/code/popcorn.code.unit.html index edeef04,0501e57..35f9de4 --- a/plugins/code/popcorn.code.unit.html +++ b/plugins/code/popcorn.code.unit.html @@@ -35,9 -35,13 +35,13 @@@ src="../../test/trailer.mp4" type='video/mp4; codecs="avc1, mp4a"'> - + +

    Your user agent does not support the HTML5 Video element.

    diff --cc plugins/facebook/popcorn.facebook.unit.html index be9e4e2,1176f90..ccefc5e --- a/plugins/facebook/popcorn.facebook.unit.html +++ b/plugins/facebook/popcorn.facebook.unit.html @@@ -24,21 -26,25 +24,25 @@@
    -
    diff --cc plugins/facebook/popcorn.facebook.unit.js index 40dd43e,1e01cf9..bde1855 --- a/plugins/facebook/popcorn.facebook.unit.js +++ b/plugins/facebook/popcorn.facebook.unit.js @@@ -24,63 -24,82 +24,81 @@@ test( "Popcorn Facebook Plugin", functi popped.facebook({ target: "likediv", - start : 1, - end : 6 - } ) + start: 1, + end: 6 + }) .facebook({ - href : "http://www.facebook.com/senecacollege", - type : "LIKE_BOX", + href: "http://www.facebook.com/senecacollege", + type: "LIKE_BOX", target: "likeboxdiv", - start : 2, - end : 6 - } ) + start: 2, + end: 6 + }) .facebook({ - site : "http://popcornjs.org/", - type : "ACTIVITY", - target : "activitydiv", - start : 3, - end : 6 - } ) + site: "http://popcornjs.org/", + type: "ACTIVITY", + target: "activitydiv", + start: 3, + end: 6 + }) .facebook({ - href : "http://www.facebook.com/senecacollege", - type : "FACEPILE", - target : "facepilediv", - start : 4, - end : 6, - width : 300 - } ) - .volume(0) + href: "http://www.facebook.com/senecacollege", + type: "FACEPILE", + target: "facepilediv", + start: 4, + end: 6, + width: 300 + }) + .volume( 0 ) .play(); - - ok (document.getElementById('likediv'), "likediv exists on the page" ); + + ok( document.getElementById( "likediv" ), "likediv exists on the page" ); plus(); - ok (document.getElementById('likeboxdiv'), "likeboxdiv exists on the page" ); + ok( document.getElementById( "likeboxdiv" ), "likeboxdiv exists on the page" ); plus(); - ok (document.getElementById('activitydiv'), "activitydiv exists on the page" ); + ok( document.getElementById( "activitydiv" ), "activitydiv exists on the page" ); plus(); - ok (document.getElementById('facepilediv'), "facepilediv exists on the page" ); + ok( document.getElementById( "facepilediv" ), "facepilediv exists on the page" ); plus(); - + // I inspected the html genterated by facebook, and found that there are no uniquely identifying attributes between plug-in types // so right now, we just check ot make sure that facebook is returning a plugin and displaying it at the correct time. - + popped.exec( 2, function() { - ok ( document.getElementById( "likediv" ).innerHTML, "likediv is not empty at 0:02 (expected)" ); + ok( document.getElementById( "likediv" ).innerHTML, "likediv is not empty at 0:02 (expected)" ); plus(); }); - + popped.exec( 3, function() { - ok ( document.getElementById( "likeboxdiv" ).innerHTML, "likeboxdiv is not empty at 0:03 (expected)" ); + ok( document.getElementById( "likeboxdiv" ).innerHTML, "likeboxdiv is not empty at 0:03 (expected)" ); plus(); }); - + popped.exec( 4, function() { - ok ( document.getElementById( "activitydiv" ).innerHTML, "Activitydiv is not empty at 0:04 (expected)" ); + ok( document.getElementById( "activitydiv" ).innerHTML, "Activitydiv is not empty at 0:04 (expected)" ); plus(); }); - + popped.exec( 5, function() { - ok ( document.getElementById( "facepilediv" ).innerHTML, "Facepilediv is not empty at 0:05 (expected)" ); + ok( document.getElementById( "facepilediv" ).innerHTML, "Facepilediv is not empty at 0:05 (expected)" ); plus(); }); + + }); + + test( "Test Empty Block", function () { + + Popcorn.plugin.debug = true; + + var pop = Popcorn( "#video" ); + + expect( 1 ); + + // Tests for thrown Error on emtpy block + try { + pop.facebook({}); + } catch( e ) { + ok( true, "Empty event was caught by debugger" ); + } + }); - diff --cc plugins/flickr/popcorn.flickr.unit.html index 58626bd,219e19a..3eec398 --- a/plugins/flickr/popcorn.flickr.unit.html +++ b/plugins/flickr/popcorn.flickr.unit.html @@@ -23,23 -23,27 +23,27 @@@

      - - -
      + +
      diff --cc plugins/footnote/popcorn.footnote.unit.html index e42d2ff,cf15b49..d04bab6 --- a/plugins/footnote/popcorn.footnote.unit.html +++ b/plugins/footnote/popcorn.footnote.unit.html @@@ -31,9 -31,13 +31,13 @@@ src="../../test/trailer.mp4" type='video/mp4; codecs="avc1, mp4a"'> - + +

      Your user agent does not support the HTML5 Video element.

      diff --cc plugins/footnote/popcorn.footnote.unit.js index 20b4399,f35c366..592e385 --- a/plugins/footnote/popcorn.footnote.unit.js +++ b/plugins/footnote/popcorn.footnote.unit.js @@@ -84,18 -84,19 +84,19 @@@ test( "Popcorn Text Plugin", function( plus(); popped.text({ - start: 0, - end: 3, - start: 5, // seconds - end: 6, // seconds ++ start: 5, ++ end: 6, text: "I am an alias", target: "textdiv" }); stop(); - popped.exec( 2, function() { + popped.exec( 5, function() { - equal( textdiv.children[0].innerHTML , "I am an alias", "I am an alias set by Popcorn.p.text" ); + equal( textdiv.children[ 0 ].innerHTML, "I am an alias", "I am an alias set by Popcorn.p.text" ); plus(); - }).currentTime( 1 ).play(); + popped.pause(); - }).currentTime(5).play(); ++ }).currentTime( 5 ).play(); }); diff --cc plugins/gml/popcorn.gml.js index daa8c55,1416301..702758d --- a/plugins/gml/popcorn.gml.js +++ b/plugins/gml/popcorn.gml.js @@@ -1,6 -1,6 +1,5 @@@ // PLUGIN: GML -- - (function ( Popcorn ) { + (function( Popcorn ) { var gmlPlayer = function( $p ) { diff --cc plugins/gml/popcorn.gml.unit.html index eca2a62,0458169..4700b8f --- a/plugins/gml/popcorn.gml.unit.html +++ b/plugins/gml/popcorn.gml.unit.html @@@ -19,23 -21,27 +19,27 @@@

        - - -
        + +
        diff --cc plugins/googlefeed/popcorn.googlefeed.unit.html index a0cade8,14f8a7f..26f52a3 --- a/plugins/googlefeed/popcorn.googlefeed.unit.html +++ b/plugins/googlefeed/popcorn.googlefeed.unit.html @@@ -20,24 -20,28 +20,28 @@@

          - - -
          -
          + +
          +
          diff --cc plugins/googlemap/popcorn.googlemap.unit.html index 3cd1cf4,71e3a85..ddb3ee6 --- a/plugins/googlemap/popcorn.googlemap.unit.html +++ b/plugins/googlemap/popcorn.googlemap.unit.html @@@ -21,26 -21,30 +21,30 @@@

            - - -
            + +
            -
            +
            diff --cc plugins/image/popcorn.image.unit.html index fd714c0,6b660a3..d2b8c37 --- a/plugins/image/popcorn.image.unit.html +++ b/plugins/image/popcorn.image.unit.html @@@ -31,11 -33,15 +31,15 @@@ - - + ++ + -

            Your user agent does not support the HTML5 Video element.

            +

            Your user agent does not support the HTML5 Video element.

            - -
            + +
            diff --cc plugins/lastfm/popcorn.lastfm.unit.html index cfe5f54,7a98c91..df1c317 --- a/plugins/lastfm/popcorn.lastfm.unit.html +++ b/plugins/lastfm/popcorn.lastfm.unit.html @@@ -23,23 -23,27 +23,27 @@@

              - - -
              + +
              diff --cc plugins/linkedin/popcorn.linkedin.unit.html index 0a122c9,53b2ca3..e0aafc3 --- a/plugins/linkedin/popcorn.linkedin.unit.html +++ b/plugins/linkedin/popcorn.linkedin.unit.html @@@ -19,23 -20,27 +19,27 @@@

                - - +
                diff --cc plugins/lowerthird/popcorn.lowerthird.unit.html index a1c459b,dbb8ae1..62ef68d --- a/plugins/lowerthird/popcorn.lowerthird.unit.html +++ b/plugins/lowerthird/popcorn.lowerthird.unit.html @@@ -21,21 -21,25 +21,25 @@@

                  - -
                  diff --cc plugins/mustache/popcorn.mustache.unit.html index 6ac0735,0d9e20d..1578c68 --- a/plugins/mustache/popcorn.mustache.unit.html +++ b/plugins/mustache/popcorn.mustache.unit.html @@@ -34,9 -34,13 +34,13 @@@ src="../../test/trailer.mp4" type='video/mp4; codecs="avc1, mp4a"'> - + +

                  Your user agent does not support the HTML5 Video element.

                  diff --cc plugins/openmap/popcorn.openmap.unit.html index 87bdffc,802df2e..fbde0e7 --- a/plugins/openmap/popcorn.openmap.unit.html +++ b/plugins/openmap/popcorn.openmap.unit.html @@@ -19,24 -21,28 +19,28 @@@

                    - - -
                    + +
                    diff --cc plugins/pause/popcorn.pause.unit.html index 683a643,d4423f7..9b4300f --- a/plugins/pause/popcorn.pause.unit.html +++ b/plugins/pause/popcorn.pause.unit.html @@@ -34,9 -34,13 +34,13 @@@ src="../../test/trailer.mp4" type='video/mp4; codecs="avc1, mp4a"' /> - + +

                    Your user agent does not support the HTML5 Video element.

                    diff --cc plugins/processing/popcorn.processing.unit.html index 3d5aac4,536eaed..d633f52 --- a/plugins/processing/popcorn.processing.unit.html +++ b/plugins/processing/popcorn.processing.unit.html @@@ -26,9 -26,13 +26,13 @@@ src="../../test/trailer.mp4" type='video/mp4; codecs="avc1, mp4a"'> - + +

                    Your user agent does not support the HTML5 Video element.

                    diff --cc plugins/subtitle/popcorn.subtitle.unit.html index ba113b6,069fb2b..d700ce4 --- a/plugins/subtitle/popcorn.subtitle.unit.html +++ b/plugins/subtitle/popcorn.subtitle.unit.html @@@ -19,38 -21,42 +19,42 @@@

                      - - - diff --cc plugins/tagthisperson/popcorn.tagthisperson.unit.html index b06ad15,397eae8..293281a --- a/plugins/tagthisperson/popcorn.tagthisperson.unit.html +++ b/plugins/tagthisperson/popcorn.tagthisperson.unit.html @@@ -20,24 -21,28 +20,29 @@@

                        - - -
                        -
                        + +
                        +
                        ++ diff --cc plugins/timeline/popcorn.timeline.unit.html index fefbe62,b2aafa1..41b6dd7 --- a/plugins/timeline/popcorn.timeline.unit.html +++ b/plugins/timeline/popcorn.timeline.unit.html @@@ -21,24 -21,28 +21,28 @@@

                          - - +
                          diff --cc plugins/twitter/popcorn.twitter.unit.html index 2f9f49d,ebc749c..cdb03d2 --- a/plugins/twitter/popcorn.twitter.unit.html +++ b/plugins/twitter/popcorn.twitter.unit.html @@@ -21,23 -23,27 +21,27 @@@

                            - - -
                            + +
                            diff --cc plugins/webpage/popcorn.webpage.unit.html index 5901156,e6ba0a8..f7e36ef --- a/plugins/webpage/popcorn.webpage.unit.html +++ b/plugins/webpage/popcorn.webpage.unit.html @@@ -21,23 -21,27 +21,27 @@@

                              - - -
                              + +
                              diff --cc plugins/wikipedia/popcorn.wikipedia.unit.html index c85ea66,299b234..6e08e17 --- a/plugins/wikipedia/popcorn.wikipedia.unit.html +++ b/plugins/wikipedia/popcorn.wikipedia.unit.html @@@ -31,9 -31,13 +31,13 @@@ src="../../test/trailer.mp4" type='video/mp4; codecs="avc1, mp4a"'> - + +

                              Your user agent does not support the HTML5 Video element.

                              diff --cc plugins/wordriver/popcorn.wordriver.unit.html index 1d35b44,e78e83d..57ed373 --- a/plugins/wordriver/popcorn.wordriver.unit.html +++ b/plugins/wordriver/popcorn.wordriver.unit.html @@@ -19,23 -21,27 +19,27 @@@

                                - - -
                                + +