changeset 943:759c2ace3c65

Merge
author Nicholas Jillings <nicholas.jillings@eecs.qmul.ac.uk>
date Sun, 17 May 2015 21:37:08 +0100
parents b5262d076f0b (diff) 36d5c460f04b (current diff)
children 23bf5007b552
files ape.css ape.js core.js example_eval/project.xml index.html
diffstat 4 files changed, 20 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/ape.css	Sun May 17 21:35:30 2015 +0100
+++ b/ape.css	Sun May 17 21:37:08 2015 +0100
@@ -43,7 +43,11 @@
 
 div.sliderScale {
 	width: 100%;
-	min-height: 20px;
+	min-height: 30px;
+}
+
+div.sliderScale span{
+	font-size: 1.2em;
 }
 
 div.sliderScale span {
--- a/ape.js	Sun May 17 21:35:30 2015 +0100
+++ b/ape.js	Sun May 17 21:37:08 2015 +0100
@@ -389,11 +389,9 @@
 		audioEngineContext.stop = function() {
 			// Send stop and reset command to all playback buffers
 			if (this.status == 1) {
-				if (this.loopPlayback) {
-					for (var i=0; i<this.audioObjects.length; i++)
-					{
-						this.audioObjects[i].stop();
-					}
+				for (var i=0; i<this.audioObjects.length; i++)
+				{
+					this.audioObjects[i].stop();
 				}
 				this.status = 0;
 			}
@@ -402,13 +400,12 @@
 		audioEngineContext.selectedTrack = function(id) {
 			for (var i=0; i<this.audioObjects.length; i++)
 			{
-				if (id == i) {
-					this.audioObjects[i].outputGain.gain.value = 1.0;
-					this.audioObjects[i].play(audioContext.currentTime+0.01);
-				} else {
-					this.audioObjects[i].outputGain.gain.value = 0.0;
-					this.audioObjects[i].stop();
-				}
+				this.audioObjects[i].outputGain.gain.value = 0.0;
+				this.audioObjects[i].stop();
+			}
+			if (this.status == 1) {
+				this.audioObjects[id].outputGain.gain.value = 1.0;
+				this.audioObjects[id].play(audioContext.currentTime+0.01);
 			}
 		};
 	}
--- a/core.js	Sun May 17 21:35:30 2015 +0100
+++ b/core.js	Sun May 17 21:37:08 2015 +0100
@@ -170,8 +170,11 @@
 	};
 	
 	this.stop = function() {
-		this.bufferNode.stop(0);
-		this.bufferNode = undefined;
+		if (this.bufferNode != undefined)
+		{
+			this.bufferNode.stop(0);
+			this.bufferNode = undefined;
+		}
 	};
 
 	this.constructTrack = function(url) {
--- a/example_eval/project.xml	Sun May 17 21:35:30 2015 +0100
+++ b/example_eval/project.xml	Sun May 17 21:37:08 2015 +0100
@@ -18,7 +18,7 @@
 			<metricEnable>elementFlagMoved</metricEnable>
 		</Metric>
 	</setup>
-	<audioHolder id='0' hostURL="example_eval/" sampleRate="44100" randomiseOrder='true' repeatCount='1' loop='true' elementComments='true'>
+	<audioHolder id='0' hostURL="example_eval/" sampleRate="44100" randomiseOrder='true' repeatCount='1' loop='false' elementComments='true'>
 		<interface>
 			<title>Example Test Question</title>
 			<scale position="0">Min</scale>