# HG changeset patch # User Nicholas Jillings # Date 1432977647 -3600 # Node ID 20823d1467b11f9014cf34e8af2237a404d76bd5 # Parent 1265e2aebf17f54ebf225319b306ee5a9076ccc5# Parent 0dbb90fa6e90c76d70a9d76ac868afb28c6e34b4 Merge from the default branch diff -r 0dbb90fa6e90 -r 20823d1467b1 ape.js --- a/ape.js Fri May 29 12:38:26 2015 +0100 +++ b/ape.js Sat May 30 10:20:47 2015 +0100 @@ -179,7 +179,13 @@ pagetitle.appendChild(titleSpan); // Store the return URL path in global projectReturn - projectReturn = xmlSetup[0].attributes['projectReturn'].value; + projectReturn = xmlSetup[0].attributes['projectReturn']; + if (projectReturn == undefined) { + console.log("WARNING - projectReturn not specified! Will assume null."); + projectReturn = "null"; + } else { + projectReturn = projectReturn.value; + } // Create Interface buttons! var interfaceButtons = document.createElement('div'); diff -r 0dbb90fa6e90 -r 20823d1467b1 core.js --- a/core.js Fri May 29 12:38:26 2015 +0100 +++ b/core.js Sat May 30 10:20:47 2015 +0100 @@ -511,7 +511,7 @@ this.id = id; this.state = 0; // 0 - no data, 1 - ready this.url = null; // Hold the URL given for the output back to the results. - this.metric = new metricTracker(); + this.metric = new metricTracker(this); this.played = false; @@ -654,7 +654,7 @@ this.initialiseTest = function(){}; } -function metricTracker() +function metricTracker(caller) { /* Custom object to track and collect metric data * Used only inside the audioObjects object. @@ -668,6 +668,7 @@ this.wasListenedTo = false; this.wasMoved = false; this.hasComments = false; + this.parent = caller; this.initialised = function(position) { @@ -689,8 +690,9 @@ this.wasListenedTo = true; this.listenStart = time; this.listenHold = true; - } - } + console.log('slider ' + this.parent.id + ' played (' + time + ')'); // DEBUG/SAFETY: show played slider id + } + }; this.stopListening = function(time) { diff -r 0dbb90fa6e90 -r 20823d1467b1 example_eval/project.xml --- a/example_eval/project.xml Fri May 29 12:38:26 2015 +0100 +++ b/example_eval/project.xml Sat May 30 10:20:47 2015 +0100 @@ -1,6 +1,6 @@ - + Please enter your location. Please listen to all mixes