From e8c6faee94fd75c1451c6702ce551cdee0c5c455 Mon Sep 17 00:00:00 2001 From: David Seifried Date: Fri, 9 Sep 2011 09:42:50 -0400 Subject: [PATCH] Early work on style fixes for plugin files --- plugins/attribution/popcorn.attribution.html | 38 ++++--- plugins/attribution/popcorn.attribution.js | 94 ++++++++++++------ .../attribution/popcorn.attribution.unit.html | 30 +++--- .../attribution/popcorn.attribution.unit.js | 65 ++++++------ plugins/flickr/popcorn.flickr.html | 12 +-- plugins/flickr/popcorn.flickr.js | 9 +- plugins/flickr/popcorn.flickr.unit.html | 30 +++--- plugins/flickr/popcorn.flickr.unit.js | 32 +++--- plugins/googlefeed/popcorn.googlefeed.html | 40 ++++---- plugins/googlefeed/popcorn.googlefeed.js | 48 ++++----- .../googlefeed/popcorn.googlefeed.unit.html | 30 +++--- plugins/googlefeed/popcorn.googlefeed.unit.js | 58 +++++------ plugins/lowerthird/popcorn.lowerthird.html | 42 ++++---- plugins/lowerthird/popcorn.lowerthird.js | 55 +++++++---- .../lowerthird/popcorn.lowerthird.unit.html | 28 +++--- plugins/lowerthird/popcorn.lowerthird.unit.js | 40 ++++---- plugins/pause/popcorn.pause.html | 22 +++-- plugins/pause/popcorn.pause.unit.html | 22 ++--- plugins/pause/popcorn.pause.unit.js | 99 ++++++++++--------- .../tagthisperson/popcorn.tagthisperson.html | 60 +++++------ .../tagthisperson/popcorn.tagthisperson.js | 68 ++++++++----- .../popcorn.tagthisperson.unit.html | 33 +++---- .../popcorn.tagthisperson.unit.js | 70 ++++++------- plugins/webpage/popcorn.webpage.html | 50 +++++----- plugins/webpage/popcorn.webpage.js | 14 +-- 25 files changed, 585 insertions(+), 504 deletions(-) diff --git a/plugins/attribution/popcorn.attribution.html b/plugins/attribution/popcorn.attribution.html index 1e7d3fa..6b509e2 100755 --- a/plugins/attribution/popcorn.attribution.html +++ b/plugins/attribution/popcorn.attribution.html @@ -2,13 +2,13 @@ Popcorn attribution Plug-in Demo - + @@ -39,22 +37,22 @@

A attribution displaying 'A Shared Culture, Jesse Dylan, license: CC-BY-N6' will appear at 0 seconds and disappear at 10 seconds.

A attribution displaying 'Internet, The Computer Chronicles' will appear at 5 seconds and disappear at 15 seconds.

-
diff --git a/plugins/attribution/popcorn.attribution.js b/plugins/attribution/popcorn.attribution.js index db24c71..ab56fc5 100755 --- a/plugins/attribution/popcorn.attribution.js +++ b/plugins/attribution/popcorn.attribution.js @@ -1,23 +1,23 @@ // PLUGIN: Attribution (function( Popcorn ) { - + /** - * Attribution popcorn plug-in + * Attribution popcorn plug-in * Adds text to an element on the page. * Options parameter will need a mandatory start, end, target. * Optional parameters include nameofwork, NameOfWorkUrl, CopyrightHolder, CopyrightHolderUrl, license & licenseUrl. * Start is the time that you want this plug-in to execute - * End is the time that you want this plug-in to stop executing + * End is the time that you want this plug-in to stop executing * Target is the id of the document element that the text needs to be attached to, this target element must exist on the DOM - * nameofwork is the title of the attribution + * nameofwork is the title of the attribution * NameOfWorkUrl is a url that provides more details about the attribution * CopyrightHolder is the name of the person/institution that holds the rights to the attribution * CopyrightHolderUrl is the url that provides more details about the copyrightholder * license is the type of license that the work is copyrighted under * LicenseUrl is the url that provides more details about the ticense type * @param {Object} options - * + * * Example: var p = Popcorn('#video') .attribution({ @@ -27,9 +27,9 @@ } ) * */ - Popcorn.plugin( "attribution" , (function(){ - - var + Popcorn.plugin( "attribution" , (function() { + + var common = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFgAAAAfCAYAAABjyArgAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEA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+ _setup: function( options ) { - var attrib = "", + var attrib = "", license = options.license && licenses[ options.license.toLowerCase() ], - tar = "target=_blank"; + tar = "target=_blank"; // make a div to put the information into options._container = document.createElement( "div" ); @@ -89,17 +89,17 @@ } } else { attrib += ", license: "; - + if ( options.licenseurl ) { attrib += "" + options.license + " "; } else { attrib += options.license; } - } + } } else if ( options.licenseurl ) { attrib += ", license "; } - + options._container.innerHTML = attrib; if ( !target && Popcorn.plugin.debug ) { @@ -108,18 +108,18 @@ target && target.appendChild( options._container ); }, /** - * @member attribution - * The start function will be executed when the currentTime - * of the video reaches the start time provided by the + * @member attribution + * The start function will be executed when the currentTime + * of the video reaches the start time provided by the * options variable */ start: function( event, options ) { options._container.style.display = "inline"; }, /** - * @member attribution - * The end function will be executed when the currentTime - * of the video reaches the end time provided by the + * @member attribution + * The end function will be executed when the currentTime + * of the video reaches the end time provided by the * options variable */ end: function( event, options ) { @@ -142,15 +142,47 @@ website: "github.com/rwldrn" }, options:{ - start: { elem:"input", type:"text", label:"In" }, - end: { elem:"input", type:"text", label:"Out" }, - nameofwork: { elem:"input", type:"text", label:"Name of Work" }, - nameofworkurl: { elem:"input", type:"text", label:"Url of Work" }, - copyrightholder: { elem:"input", type:"text", label:"Copyright Holder" }, - copyrightholderurl: { elem:"input", type:"text", label:"Copyright Holder Url" }, - license: { elem:"input", type:"text", label:"License type" }, - licenseurl: { elem:"input", type:"text", label:"License URL" }, + start: { + elem: "input", + type: "text", + label: "In" + }, + end: { + elem: "input", + type: "text", + label: "Out" + }, + nameofwork: { + elem: "input", + type: "text", + label: "Name of Work" + }, + nameofworkurl: { + elem: "input", + type: "text", + label: "Url of Work" + }, + copyrightholder: { + elem: "input", + type: "text", + label: "Copyright Holder" + }, + copyrightholderurl: { + elem: "input", + type: "text", + label: "Copyright Holder Url" + }, + license: { + elem: "input", + type: "text", + label: "License type" + }, + licenseurl: { + elem: "input", + type: "text", + label: "License URL" + }, target: "attribution-container" - } + } }); })( Popcorn ); diff --git a/plugins/attribution/popcorn.attribution.unit.html b/plugins/attribution/popcorn.attribution.unit.html index 02b6f03..52592b3 100755 --- a/plugins/attribution/popcorn.attribution.unit.html +++ b/plugins/attribution/popcorn.attribution.unit.html @@ -4,11 +4,11 @@ Popcorn Attribution Plugin - - + @@ -21,23 +21,23 @@

    - - -
    + +
    diff --git a/plugins/attribution/popcorn.attribution.unit.js b/plugins/attribution/popcorn.attribution.unit.js index 7a40e22..81359ce 100755 --- a/plugins/attribution/popcorn.attribution.unit.js +++ b/plugins/attribution/popcorn.attribution.unit.js @@ -1,80 +1,79 @@ test("Popcorn attribution Plugin", function () { - + var popped = Popcorn("#video"), - expects = 10, + expects = 10, count = 0, setupId, - attributiondiv = document.getElementById('attribdiv'); + attributiondiv = document.getElementById( "attribdiv" ); + + expect( expects ); - expect(expects); - function plus() { - if ( ++count===expects) { + if ( ++count===expects ) { start(); } } - + stop(); - - ok ('attribution' in popped, "attribution is a method of the popped instance"); + + ok ( "attribution" in popped, "attribution is a method of the popped instance" ); plus(); - + equals ( attributiondiv.childElementCount, 0, "initially, there is nothing inside the attributiondiv" ); plus(); - - + popped.attribution({ - start: 0, // seconds - end: 2, // seconds + start: 0, + end: 2, nameofwork: "A Shared Culture", - copyrightholder:"Jesse Dylan", + copyrightholder: "Jesse Dylan", licenseurl: "http://creativecommons.org/licenses/by-nc/2.0/", - target: 'attribdiv' - } ) + target: "attribdiv" + }) .attribution({ - start: 2, // seconds - end: 4, // seconds + start: 2, + end: 4, nameofwork: "Internet", - nameofworkurl:"http://www.archive.org/details/CC1232_internet", - copyrightholder:"The Computer Chronicles", - license:"CC-BY-NC-ND", + nameofworkurl: "http://www.archive.org/details/CC1232_internet", + copyrightholder: "The Computer Chronicles", + license: "CC-BY-NC-ND", licenseurl: "http://creativecommons.org/licenses/by-nc-nd/2.0/", - target: 'attribdiv' - } ) - .volume(0); + target: "attribdiv" + }) + .volume( 0 ); setupId = popped.getLastTrackEventId(); popped.exec( 0, function() { equals ( attributiondiv.childElementCount, 2, "attributiondiv now has two inner elements" ); plus(); - equals (attributiondiv.children[0].style.display , "inline", "attribution is visible on the page" ); + equals ( attributiondiv.children[ 0 ].style.display , "inline", "attribution is visible on the page" ); plus(); }); - + popped.exec( 2, function() { ok( /target="_blank"/.test( attributiondiv.innerHTML ), "attributions create anchors that target=_blank" ); plus(); - equals (attributiondiv.children[1].style.display , "inline", "second attribution is visible on the page" ); + equals ( attributiondiv.children[ 1 ].style.display , "inline", "second attribution is visible on the page" ); plus(); equals ( typeof popped.data.trackEvents.byStart[ 1 ]._license, "undefined", "undefined license is properly being handled" ); plus(); }); - + popped.exec( 4, function() { - equals(attributiondiv.children[1].style.display , "none", "second attribution is no longer visible on the page" ); + equals( attributiondiv.children[ 1 ].style.display , "none", "second attribution is no longer visible on the page" ); plus(); - equals(attributiondiv.children[0].style.display , "none", "first attribution is no longer visible on the page" ); + equals( attributiondiv.children[ 0 ].style.display , "none", "first attribution is no longer visible on the page" ); plus(); popped.pause().removeTrackEvent( setupId ); - ok( !attributiondiv.children[1], "removed attribution was properly destroyed" ); + ok( !attributiondiv.children[ 1 ], "removed attribution was properly destroyed" ); plus(); }); - + popped.play(); }); diff --git a/plugins/flickr/popcorn.flickr.html b/plugins/flickr/popcorn.flickr.html index 31d2208..c71e038 100755 --- a/plugins/flickr/popcorn.flickr.html +++ b/plugins/flickr/popcorn.flickr.html @@ -4,7 +4,7 @@ Popcorn Flickr Plug-in Demo @@ -57,19 +57,19 @@ +
    diff --git a/plugins/flickr/popcorn.flickr.js b/plugins/flickr/popcorn.flickr.js index a4d9738..b231c60 100755 --- a/plugins/flickr/popcorn.flickr.js +++ b/plugins/flickr/popcorn.flickr.js @@ -50,7 +50,7 @@ _uri, _link, _image, - _count = options.numberofimages || 4 , + _count = options.numberofimages || 4, _height = options.height || "50px", _width = options.width || "50px", _padding = options.padding || "5px", @@ -66,10 +66,10 @@ idx++; // ensure the target container the user chose exists - if ( !target && Popcorn.plugin.debug ) { throw new Error( "flickr target container doesn't exist" ); } + target && target.appendChild( containerDiv ); // get the userid from Flickr API by using the username and apikey @@ -90,16 +90,21 @@ }, 5 ); } }; + // get the photos from Flickr API by using the user_id and/or tags var getFlickrData = function() { + _uri = "http://api.flickr.com/services/feeds/photos_public.gne?"; + if ( _userid ) { _uri += "id=" + _userid + "&"; } if ( options.tags ) { _uri += "tags=" + options.tags + "&"; } + _uri += "lang=en-us&format=json&jsoncallback=flickr"; + Popcorn.xhr.getJSONP( _uri, function( data ) { var fragment = document.createElement( "p" ); diff --git a/plugins/flickr/popcorn.flickr.unit.html b/plugins/flickr/popcorn.flickr.unit.html index 356b11d..f810b60 100755 --- a/plugins/flickr/popcorn.flickr.unit.html +++ b/plugins/flickr/popcorn.flickr.unit.html @@ -4,11 +4,11 @@ Popcorn Flickr - - + @@ -23,23 +23,23 @@

      - - -
      + +
      diff --git a/plugins/flickr/popcorn.flickr.unit.js b/plugins/flickr/popcorn.flickr.unit.js index e9688fc..2e2c7ad 100755 --- a/plugins/flickr/popcorn.flickr.unit.js +++ b/plugins/flickr/popcorn.flickr.unit.js @@ -1,27 +1,27 @@ test("Popcorn Flickr Plugin", function () { - + var popped = Popcorn( "#video" ), - expects = 11, + expects = 11, count = 0, setupId, flickrdiv = document.getElementById( "flickrdiv" ); - + expect( expects ); - + function plus() { if ( ++count === expects ) { start(); } } - stop(); - + stop(); + ok( "flickr" in popped, "flickr is a method of the popped instance" ); plus(); equals ( flickrdiv.innerHTML, "", "initially, there is nothing inside the flickrdiv" ); plus(); - + popped.flickr({ start: 0, end: 3, @@ -57,28 +57,28 @@ test("Popcorn Flickr Plugin", function () { popped.exec( 5, function() { - var numberOfImages = document.getElementById( "flickrdiv" ).childNodes[1].getElementsByTagName( "a" ).length; + var numberOfImages = document.getElementById( "flickrdiv" ).childNodes[ 1 ].getElementsByTagName( "a" ).length; ok( /display: inline;/.test( flickrdiv.innerHTML ), "Div contents are displayed" ); plus(); - + ok( /img/.test( flickrdiv.innerHTML ), "An image exists" ); plus(); - + ok( /display: inline;/.test( flickrdiv.innerHTML ), "Images tagged 'georgia' are displayed in div" ); plus(); - + equal( numberOfImages, 8, "There are 8 images tagged 'georgia' being displayed" ); plus(); }); - + popped.exec( 11, function() { ok( /display: none;/.test( flickrdiv.innerHTML ), "Div contents are hidden again" ); plus(); popped.pause().removeTrackEvent( setupId ); - ok( !flickrdiv.children[2], "Removed flickr was properly destroyed" ); + ok( !flickrdiv.children[ 2 ], "Removed flickr was properly destroyed" ); plus(); }); @@ -90,10 +90,10 @@ test("Popcorn Flickr Plugin", function () { try { popped.flickr({}); } catch( e ) { - ok(true, 'empty event was caught by debug'); + ok( true, "empty event was caught by debug" ); plus(); } - popped.volume(0).play(); - + popped.volume( 0 ).play(); + }); diff --git a/plugins/googlefeed/popcorn.googlefeed.html b/plugins/googlefeed/popcorn.googlefeed.html index 72bc9a1..e426303 100755 --- a/plugins/googlefeed/popcorn.googlefeed.html +++ b/plugins/googlefeed/popcorn.googlefeed.html @@ -2,30 +2,30 @@ Popcorn Google Feed Plug-in Demo - + @@ -34,26 +34,30 @@

      A Blog feed of Seneca's Planet Feed will be displayed from 0 seconds to 15 seconds

      A Blog feed of pikiGeek's feed will be displayed from 5 seconds to 20 seconds

      -
      -

      Vertical Feed:

      -

      Horizontal Feed:

      +
      +

      Vertical Feed:

      +
      +
      +

      Horizontal Feed:

      +
      diff --git a/plugins/googlefeed/popcorn.googlefeed.js b/plugins/googlefeed/popcorn.googlefeed.js index 1a6d1cd..1d84f6b 100755 --- a/plugins/googlefeed/popcorn.googlefeed.js +++ b/plugins/googlefeed/popcorn.googlefeed.js @@ -46,7 +46,7 @@ callback: function () { - dynamicFeedLoad(); + dynamicFeedLoad(); } }); }); @@ -80,6 +80,7 @@ */ Popcorn.plugin( "googlefeed" , function( options ) { + // create a new div and append it to the parent div so nothing // that already exists in the parent div gets overwritten var newdiv = document.createElement( "div" ), @@ -88,7 +89,7 @@ //ensure that the script has been loaded if ( !scriptLoaded ) { setTimeout( function () { - initialize(); + initialize(); }, 5 ); } else { // Create the feed control using the user entered url and title @@ -118,7 +119,7 @@ target && target.appendChild( newdiv ); initialize(); - + return { /** * @member webpage @@ -146,39 +147,38 @@ }, { about: { - name: "Popcorn Google Feed Plugin", + name: "Popcorn Google Feed Plugin", version: "0.1", - author: "David Seifried", + author: "David Seifried", website: "dseifried.wordpress.com" }, options: { start: { - elem: "input", - type: "text", - label: "In" + elem: "input", + type: "text", + label: "In" }, - end: { - elem: "input", - type: "text", - label: "Out" + end: { + elem: "input", + type: "text", + label: "Out" }, target: "feed-container", - url: { - elem: "input", - type: "text", - label: "url" + url: { + elem: "input", + type: "text", + label: "url" }, - title: { - elem: "input", - type: "text", - label: "title" + title: { + elem: "input", + type: "text", + label: "title" }, orientation: { - elem: "select", - options: [ "Vertical","Horizontal" ], - label: "orientation" + elem: "select", + options: [ "Vertical","Horizontal" ], + label: "orientation" } } }); - })( Popcorn ); diff --git a/plugins/googlefeed/popcorn.googlefeed.unit.html b/plugins/googlefeed/popcorn.googlefeed.unit.html index 9bfc36b..59e2029 100755 --- a/plugins/googlefeed/popcorn.googlefeed.unit.html +++ b/plugins/googlefeed/popcorn.googlefeed.unit.html @@ -4,8 +4,8 @@ Popcorn API - @@ -20,24 +20,24 @@

        - - -
        -
        + +
        +
        diff --git a/plugins/googlefeed/popcorn.googlefeed.unit.js b/plugins/googlefeed/popcorn.googlefeed.unit.js index 06aff4a..0ae1743 100755 --- a/plugins/googlefeed/popcorn.googlefeed.unit.js +++ b/plugins/googlefeed/popcorn.googlefeed.unit.js @@ -1,71 +1,71 @@ test("Popcorn Google Feed Plugin", function () { - + var popped = Popcorn( "#video" ), expects = 13, - setupId, + setupId, count = 0; - - expect(expects); - + + expect( expects ); + function plus() { if ( ++count === expects) { start(); } } - + stop(); - ok ( 'googlefeed' in popped, "googlefeed is a method of the popped instance" ); + ok ( "googlefeed" in popped, "googlefeed is a method of the popped instance" ); plus(); - ok ( document.getElementById('feed').innerHTML === "", "initially, there is nothing inside the feed" ); + ok ( document.getElementById( "feed" ).innerHTML === "", "initially, there is nothing inside the feed" ); plus(); - ok ( document.getElementById('feed1').innerHTML === "", "initially, there is nothing inside the feed1" ); + ok ( document.getElementById( "feed1" ).innerHTML === "", "initially, there is nothing inside the feed1" ); plus(); - + popped.googlefeed({ - start: 1, // seconds - end: 2, // seconds + start: 1, + end: 2, target: "feed", url: "http://zenit.senecac.on.ca/~chris.tyler/planet/rss20.xml", title: "Planet Feed", }) .googlefeed({ - start: 2, // seconds - end: 3, // seconds + start: 2, + end: 3, target: "feed1", url: "http://blog.pikimal.com/geek/feed/", title: "pikiGeek", orientation: "Horizontal" }) - .volume(0); + .volume( 0 ); setupId = popped.getLastTrackEventId(); - + popped.exec( 1, function() { - ok( google.load, "Google Feed is available"); + ok( google.load, "Google Feed is available" ); plus(); - ok( GFdynamicFeedControl, "Dynamic Feed Control Available"); + ok( GFdynamicFeedControl, "Dynamic Feed Control Available" ); plus(); - ok ( document.getElementById('_feed1'), "First feed is on the page" ); + ok ( document.getElementById( "_feed1" ), "First feed is on the page" ); plus(); - equals ( document.getElementById('_feed1').offsetParent.id, "feed", "First feed is inside the 'feed' div" ); + equals ( document.getElementById( "_feed1" ).offsetParent.id, "feed", "First feed is inside the 'feed' div" ); plus(); - equals( popped.data.trackEvents.byStart[1].orientation, "vertical", "Defaulting to vertical orientation" ); + equals( popped.data.trackEvents.byStart[ 1 ].orientation, "vertical", "Defaulting to vertical orientation" ); plus(); }); popped.exec( 2, function() { - ok ( document.getElementById('_feed2'), "Second feed is on the page" ); + ok ( document.getElementById( "_feed2" ), "Second feed is on the page" ); plus(); - equals ( document.getElementById('_feed2').offsetParent.id, "feed1", "Second feed is inside the 'feed2' div" ); + equals ( document.getElementById( "_feed2" ).offsetParent.id, "feed1", "Second feed is inside the 'feed2' div" ); plus(); }); popped.exec( 3, function() { - ok ( document.getElementById('_feed2').style.display === "none" && - document.getElementById('_feed1').style.display === "none", "Both feeds are no lnger visible" ); + ok ( document.getElementById( "_feed2" ).style.display === "none" && + document.getElementById( "_feed1" ).style.display === "none", "Both feeds are no lnger visible" ); plus(); popped.pause().removeTrackEvent( setupId ); - ok( !document.getElementById('feed1').children[0], "removed feed was properly destroyed" ); + ok( !document.getElementById( "feed1" ).children[ 0 ], "removed feed was properly destroyed" ); plus(); }); @@ -77,10 +77,10 @@ test("Popcorn Google Feed Plugin", function () { try { popped.googlefeed({}); } catch( e ) { - ok(true, 'empty event was caught by debug'); + ok( true, "empty event was caught by debug" ); plus(); - } + } popped.play(); - + }); diff --git a/plugins/lowerthird/popcorn.lowerthird.html b/plugins/lowerthird/popcorn.lowerthird.html index 7fb234f..c3cb774 100755 --- a/plugins/lowerthird/popcorn.lowerthird.html +++ b/plugins/lowerthird/popcorn.lowerthird.html @@ -2,32 +2,30 @@ Popcorn Lower Third Plug-in Demo - + @@ -36,17 +34,17 @@

        At 20 seconds info will appear in the lower third of the video and disappear at 45 seconds.

        -