Merge with local popcorn-port
authorhamidouk
Thu, 09 Feb 2012 12:06:35 +0100
branchpopcorn-port
changeset 796 6d8a83ef4949
parent 795 8b69c3dbbc18 (diff)
parent 793 6ff51024d2db (current diff)
child 797 8407313c144f
child 799 5293a2c52fc6
Merge with local
Binary file src/css/imgs/user_default_icon.png has changed
Binary file src/css/imgs/video_sequence.png has changed
--- a/src/js/init.js	Thu Feb 09 11:09:28 2012 +0100
+++ b/src/js/init.js	Thu Feb 09 12:06:35 2012 +0100
@@ -157,7 +157,9 @@
 
 /** configure modules. @see configureWidgets */
 IriSP.configureModules = function (popcornInstance, modulesList) {
- 
+  if (IriSP.null_or_undefined(modulesList))
+    return;
+  
   var serialFactory = new IriSP.SerializerFactory(IriSP.__dataloader);
   var ret_modules = [];
   var index;
@@ -246,6 +248,11 @@
   IriSP.paths = IriSP.underscore.defaults(IriSP.paths, IriSP.defaults.paths);
   IriSP.default_templates_vars = IriSP.underscore.defaults(IriSP.default_templates_vars, 
                                        IriSP.defaults.default_templates_vars());
+
+  if (IriSP.null_or_undefined(IriSP.user))
+    IriSP.user = {};
+  
+  IriSP.user = IriSP.underscore.defaults(IriSP.user, IriSP.defaults.user());
 };
 
 /** single point of entry for the metadataplayer */
--- a/src/js/site.js.templ	Thu Feb 09 11:09:28 2012 +0100
+++ b/src/js/site.js.templ	Thu Feb 09 12:06:35 2012 +0100
@@ -115,12 +115,13 @@
 /*
 Override this if you want to change the info the player receives about the user.
 It's typically overrided in server-side templates with user-specific data.
+*/
+IriSP.defaults.user = function() { return {
+      "name" : "Anonymous user",
+      "avatar" : IriSP.paths.imgs + "/user_default_icon.png"
+    }
+};
 
-IriSP.user = {
-  "name" : "loic",
-  "avatar" : "http://a1.twimg.com/profile_images/39270812/loicempuria_normal.jpg"
-};
-*/
 
 IriSP.defaults.paths = {
 //  "imgs": "/tweetlive/res/metadataplayer/src/css/imgs"
--- a/src/templates/annotationsListWidget.html	Thu Feb 09 11:09:28 2012 +0100
+++ b/src/templates/annotationsListWidget.html	Thu Feb 09 12:06:35 2012 +0100
@@ -16,7 +16,7 @@
         {{/url}}
           <div style='overflow: auto; margin-top: 5px; margin-bottom: 5px;'>
             <div class='Ldt-AnnotationsList-Caption'>
-              <img src='http://i.imgur.com/aoUlC.jpg'></img>
+              <img src='{{img_dir}}/video_sequence.png'></img>
             </div>
             <div class='Ldt-AnnotationsList-Duration'>{{begin}} - {{end}}</div>
             <div class='Ldt-AnnotationsList-Title'>{{title}}</div>