src/js/widgets.js
branchpopcorn-port
changeset 95 da3ab0bfadf3
parent 93 8c066a79a14f
child 98 ed4ac18baf07
equal deleted inserted replaced
94:457ab20a99a9 95:da3ab0bfadf3
   198     var annotation = annotations[i];
   198     var annotation = annotations[i];
   199     var begin = Math.round((+ annotation.begin) / 1000);
   199     var begin = Math.round((+ annotation.begin) / 1000);
   200     var end = Math.round((+ annotation.end) / 1000);
   200     var end = Math.round((+ annotation.end) / 1000);
   201 
   201 
   202     this._Popcorn = this._Popcorn.code({start: begin, end: end, 
   202     this._Popcorn = this._Popcorn.code({start: begin, end: end, 
   203                                         onStart: function() { console.log(begin, end); _this.displayAnnotation(annotation); }, 
   203                                         onStart: 
   204                                         onEnd: function() { console.log("end", end); }});                                             
   204                                           function(annotation) { return function() { _this.displayAnnotation(annotation); } }(annotation) });                                             
   205   }
   205   }
   206 };
   206 };