--- a/crea/integration/metadataplayer/LdtPlayer-core.js Tue Jun 12 18:37:23 2012 +0200
+++ b/crea/integration/metadataplayer/LdtPlayer-core.js Wed Jun 13 18:33:28 2012 +0200
@@ -77,8 +77,13 @@
.script(IriSP.getLib("underscore"))
.script(IriSP.getLib("Mustache"))
.script(IriSP.getLib("jQuery"))
- .script(IriSP.getLib("swfObject"))
- .wait()
+ .script(IriSP.getLib("swfObject"));
+
+ if (typeof JSON == "undefined") {
+ $L.script(IriSP.getLib("json"));
+ }
+
+ $L.wait()
.script(IriSP.getLib("jQueryUI"));
if (this.config.player.type === "jwplayer" || this.config.player.type === "auto") {
@@ -604,7 +609,9 @@
IriSP.PopcornReplacement.player.prototype.roundTime = function() {
var currentTime = this.currentTime();
return Math.round(currentTime);
-};/* model.js is where data is stored in a standard form, whatever the serializer */
+};/* TODO: Separate Project-specific data from Source */
+
+/* model.js is where data is stored in a standard form, whatever the serializer */
IriSP.Model = {
_SOURCE_STATUS_EMPTY : 0,
@@ -1385,6 +1392,9 @@
}
IriSP.Model.Directory.prototype.remoteSource = function(_properties) {
+ if (typeof _properties !== "object" || typeof _properties.url === "undefined") {
+ throw "Error : IriSP.Model.Directory.remoteSource(configuration): configuration.url is undefined";
+ }
var _config = IriSP._({ directory: this }).extend(_properties);
if (typeof this.remoteSources[_properties.url] === "undefined") {
this.remoteSources[_properties.url] = new IriSP.Model.RemoteSource(_config);
@@ -1428,7 +1438,8 @@
jwplayer : "jwplayer.js",
raphael : "raphael-min.js",
tracemanager : "tracemanager.js",
- jwPlayerSWF : "player.swf"
+ jwPlayerSWF : "player.swf",
+ json : "json2.js"
},
locations : {
// use to define locations outside defautl_dir