comparison interfaces/discrete.js @ 2428:78f2dbe417da

WIP #29
author Nicholas Jillings <n.g.r.jillings@se14.qmul.ac.uk>
date Fri, 27 May 2016 16:16:10 +0100
parents b7ed9d43ea87
children 1647bb807186
comparison
equal deleted inserted replaced
2427:b33d6988152c 2428:78f2dbe417da
353 var outsideReference = document.getElementById('outside-reference'); 353 var outsideReference = document.getElementById('outside-reference');
354 this.play.textContent = "Listening"; 354 this.play.textContent = "Listening";
355 if (outsideReference != null) { 355 if (outsideReference != null) {
356 $(outsideReference).removeClass('track-slider-playing'); 356 $(outsideReference).removeClass('track-slider-playing');
357 } 357 }
358 if (this.parent.specification.parent.playOne || specification.playOne) {
359 $('.track-slider-button').text = "Wait";
360 $('.track-slider-button').attr("disabled","true");
361 }
358 } 362 }
359 this.stopPlayback = function() 363 this.stopPlayback = function()
360 { 364 {
361 // Called by audioObject when playback stops 365 // Called by audioObject when playback stops
362 this.play.setAttribute("playstate","ready"); 366 if (this.play.getAttribute("playstate") == "playing") {
363 $(this.holder).removeClass('track-slider-playing'); 367 this.play.setAttribute("playstate","ready");
364 this.play.textContent = "Play"; 368 $(this.holder).removeClass('track-slider-playing');
369 $('.track-slider-button').text = "Play";
370 this.play.textContent = "Play";
371 $('.track-slider-button').removeAttr("disabled");
372 }
365 } 373 }
366 374
367 this.getValue = function() 375 this.getValue = function()
368 { 376 {
369 // Return the current value of the object. If there is no value, return -1 377 // Return the current value of the object. If there is no value, return -1