]> khamidou — GitHub mirrors - popcorn-js.git/commitdiff
Revert "Merge branch 'review' of github.com:annasob/popcorn-js into 0.1"
authorAnna Sobiepanek <annaopensource@gmail.com>
Tue, 22 Jun 2010 12:10:09 +0000 (08:10 -0400)
committerAnna Sobiepanek <annaopensource@gmail.com>
Tue, 22 Jun 2010 12:10:09 +0000 (08:10 -0400)
This reverts commit b6a2893d42ce3330b227c435c428280bb6e5c311, reversing
changes made to 6c6ea05091e4ac57b5376946590e6f946db07b52.

README
popcorn.js
xml/webMadeMovies.xml

diff --git a/README b/README
index ce334cb7c0c953f7e8f1403fce7bce8e7bd058c1..6b9bfaf3379bd2ea97a4faff38f046292b3ea319 100644 (file)
--- a/README
+++ b/README
   Bug Tracking      https://processing-js.lighthouseapp.com/projects/52212-popcornjs/overview
 
   IMPORTANT! - NOTE FOR DEVELOPERS
-
-  Please read the guidelines before pushing your code to the repository. The 
-  function(s) you are working on may already be finished and queued for push. 
+  Please read the guidelines before pushing your code to the repository. The function(s) you are working on may already be finished and queued for push. 
 
   GUIDELINES
   https://processing-js.lighthouseapp.com/projects/52212/project-workflow
-  
+
   IRC CHANNEL
   Join the development team at irc://irc.mozilla.org/popcorn for more info
 
index e99f279fdbd06e58b831a7aecdee10cabdaaaacb..6eed955b6a27b5927894da6acdbff9470a01fc37 100644 (file)
   };
 
   // Simple function to convert 0:05 to 0.5 in seconds
-  var toSeconds = function(time) {
+  var to_secs = function(time) {
     var t = time.split(":");
-    if (t.length === 3) {
-      return parseInt(t[0] * 60, 10) + parseFloat(t[1], 10) + parseFloat(t[2] / 30, 10);
-    } else if (t.length === 4) {
-      return parseInt(t[0] * 3600, 10) + parseInt(t[1] * 60, 10) + parseFloat(t[2], 10) + parseFloat(t[3] / 30, 10);
-    }
+    return parseInt(t[0] * 60, 10) + parseInt(t[1], 10);
   };
 
   ////////////////////////////////////////////////////////////////////////////
@@ -85,7 +81,7 @@
         var key = params[i].item(j).nodeName,
             data = params[i].item(j).nodeValue;
         if (key === "in" || key === "out") {
-          this.params[key] = toSeconds(data);
+          this.params[key] = to_secs(data);
         } else {
           this.params[key] = data;
         }
index c3238321e480b1ebb8d45723c1c06130c7c2c1aa..da740592177e3e297e4de32f749d2ebc052392f0 100644 (file)
@@ -1,26 +1,23 @@
 <popcorn>
   <subtitles>
-    <subtitle in="00:05:00" out="00:07:00">Hello! My name is Celine Celine</subtitle>
-    <subtitle in="00:07:00" out="00:09:00">And I help the Internet be easier</subtitle>
-    <subtitle in="00:09:00" out="00:12:00">by making things easier</subtitle>
-    <subtitle in="00:15:00" out="00:17:00">My name is Mona Kasra</subtitle>
-    <subtitle in="00:17:00" out="00:19:00">and I'm building a better internet</subtitle>
+    <subtitle in="0:05" out="0:07">Hello! My name is Celine Celine</subtitle>
+    <subtitle in="0:07" out="0:09">And I help the Internet be easier</subtitle>
+    <subtitle in="0:09" out="0:12">by making things easier</subtitle>
+    <subtitle in="0:15" out="0:17">My name is Mona Kasra</subtitle>
+    <subtitle in="0:17" out="0:19">and I'm building a better internet</subtitle>
   </subtitles>
   <inThisVideo>
-    <tagThisVideo in="00:03:00" out="00:14:00">Celine Celine</tagThisVideo>
-    <tagThisVideo in="00:03:15" out="00:14:00">Celine Celine2</tagThisVideo>
-    <tagThisVideo in="00:03:30" out="00:14:00">Celine Celine3</tagThisVideo>
-    <tagThisVideo in="00:03:45" out="00:14:00">Celine Celine4</tagThisVideo>
-         <tagThisVideo in="00:13:00" out="00:16:00">Bryan</tagThisVideo>
-    <tagThisVideo in="00:15:00" out="00:19:00">Mona Kasra</tagThisVideo>
-         <tagThisVideo in="00:19:00" out="00:21:00">Caleb</tagThisVideo>
-         <tagThisVideo in="00:21:00" out="00:31:00">Dave</tagThisVideo>
-         <tagThisVideo in="00:21:00" out="00:33:00">Noah</tagThisVideo>
-         <tagThisVideo in="00:39:00" out="00:41:00">Celine Celine</tagThisVideo>
+    <tagThisVideo in="0:03" out="0:14">Celine Celine</tagThisVideo>
+         <tagThisVideo in="0:13" out="0:16">Bryan</tagThisVideo>
+    <tagThisVideo in="0:15" out="0:19">Mona Kasra</tagThisVideo>
+         <tagThisVideo in="0:19" out="0:21">Caleb</tagThisVideo>
+         <tagThisVideo in="0:21" out="0:31">Dave</tagThisVideo>
+         <tagThisVideo in="0:21" out="0:33">Noah</tagThisVideo>
+         <tagThisVideo in="0:39" out="0:41">Celine Celine</tagThisVideo>
   </inThisVideo>
   <map>
-    <location id="map1" in="00:01:00" out="00:30:00" lat="45.505" long="-73.335" target="map" zoom="8"/>
-    <location id="map2" in="00:30:00" out="01:00:00" lat="43.771" long="-79.5" target="map" zoom="16"/>
-    <location id="map3" in="01:00:00" out="01:30:00" lat="41.771" long="-76.5" target="map" zoom="16"/>
+    <location id="map1" in="0:01" out="0:30" lat="45.505" long="-73.335" target="map" zoom="8"/>
+    <location id="map2" in="0:30" out="1:00" lat="43.771" long="-79.5" target="map" zoom="16"/>
+    <location id="map3" in="1:00" out="1:30" lat="41.771" long="-76.5" target="map" zoom="16"/>
   </map>
 </popcorn>