Mercurial > hg > webaudioevaluationtool
changeset 2726:c74c698795a9
#163. Fixed
author | Nicholas Jillings <nicholas.jillings@mail.bcu.ac.uk> |
---|---|
date | Sat, 15 Apr 2017 12:05:31 +0100 |
parents | 9c01d5dd22a2 |
children | 03edc9db9f8c 07fcccd5e1a6 9c3f50d6e544 |
files | css/core.css interfaces/AB.js interfaces/ABX.js interfaces/ape.js interfaces/discrete.js interfaces/mushra.js interfaces/timeline.js |
diffstat | 7 files changed, 90 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/css/core.css Sat Apr 15 11:59:21 2017 +0100 +++ b/css/core.css Sat Apr 15 12:05:31 2017 +0100 @@ -8,6 +8,7 @@ margin-bottom: 10px; font-size: 2em; } + div.indicator-box { position: absolute; left: 150px; @@ -18,6 +19,7 @@ border-radius: 10px; background-color: rgb(100, 200, 200); } + div.comment-div { border: 1px solid #444444; max-width: 600px; @@ -27,9 +29,11 @@ height: 90px; border-radius: 10px; } + div.comment-div span { margin-left: 15px; } + div.popupHolder { width: 500px; min-height: 250px; @@ -40,16 +44,19 @@ z-index: 10; position: fixed; } + div#popupContent { margin-top: 20px; margin-bottom: 35px; overflow: auto; } + div#popupContent iframe { width: 100%; border: 0px none; height: 290px; } + div#popupTitleHolder { width: inherit; min-height: 25px; @@ -59,9 +66,11 @@ padding: 8px; text-align: center; } + #popupTitle { white-space: pre-line; } + div#popupResponse { width: inherit; min-height: 50px; @@ -69,6 +78,7 @@ overflow: auto; position: relative; } + button.popupButton { /* Button for popup window */ @@ -81,6 +91,7 @@ border-style: solid; background-color: #fff; } + div.popup-option-checbox { /* Popup window checkbox */ padding: 5px; @@ -88,33 +99,41 @@ width: -moz-fit-content; width: -webkit-fit-content; } + div.popup-option-checbox input { /* Popup window checkbox */ margin-right: 15px; } + table.popup-option-list { margin: auto; } + table.popup-option-list tr { padding: 5px; } + table.popup-option-list tr td { padding: 5px; } + div.survey-slider-text-holder { display: flex; flex-direction: row; justify-content: space-between; padding: 0px 15px; } + button#popup-proceed { bottom: 10px; right: 10px; } + button#popup-previous { bottom: 10px; left: 10px; } + div.testHalt { /* Specify any colouring during the test halt for pre/post questions */ background-color: rgba(0, 0, 0, 0.5); @@ -126,6 +145,7 @@ left: 0px; top: 0px; } + div#lightbox-root { visibility: hidden; z-index: 20; @@ -133,6 +153,7 @@ min-height: 50px; max-height: 250px; } + div.lightbox-error { margin: 25px; margin-bottom: 50px; @@ -141,6 +162,7 @@ background-color: rgb(255, 220, 220); border: 2px rgb(200, 0, 0) solid; } + div.lightbox-warning { margin: 25px; margin-bottom: 50px; @@ -149,6 +171,7 @@ background-color: rgb(255, 255, 220); border: 2px rgb(255, 250, 0) solid; } + div.lightbox-message { margin: 25px; margin-bottom: 50px; @@ -157,22 +180,26 @@ background-color: rgb(200, 220, 255); border: 2px rgb(50, 100, 250) solid; } + div#lightbox-blanker { visibility: hidden; z-index: 19; } + button.outside-reference { width: 120px; height: 20px; margin-bottom: 5px; position: absolute; } + textarea.trackComment { max-width: 594px; min-width: 350px; max-height: 60px; resize: none; } + div.playhead { width: 500px; height: 50px; @@ -180,22 +207,26 @@ border-radius: 10px; padding: 10px; } + div.playhead-scrub-track { width: 100%; height: 10px; border-style: solid; border-width: 1px; } + div#playhead-scrubber { width: 10px; height: 10px; position: relative; background-color: #000; } + div.master-volume-holder-inline { width: 100%; padding: 5px; } + div.master-volume-holder-float { position: absolute; top: 20px; @@ -203,6 +234,7 @@ width: 250px%; padding: 5px; } + div#master-volume-root { margin: auto; border: black 1px solid; @@ -210,6 +242,7 @@ width: 250px; height: 40px; } + input#master-volume-control { width: 190px; height: 25px; @@ -217,23 +250,28 @@ margin: 0px; padding: 0px; } + span#master-volume-feedback { height: 25px; margin: 0px 5px; float: right; } + div.error-colour { background-color: #FF8F8F; } + button.error-colour { background-color: #FF8F8F; color: black; } + div.calibration-holder { text-align: center; align-content: center; height: auto; } + div.calibration-slider { width: 50px; margin: 2px; @@ -241,6 +279,7 @@ align-content: center; float: left; } + div.calibration-slider input[type=range][orient=vertical] { writing-mode: bt-lr; /* IE */ @@ -251,6 +290,7 @@ height: 290px; } + /* Comment Boxes */ div.comment-slider-text-holder { @@ -258,18 +298,25 @@ flex-direction: row; justify-content: space-between; } + div.comment-slider-text-holder span { margin: 0px 5px; } + div.comment-checkbox-inputs-holder { display: flex; flex-direction: row; justify-content: space-around; margin: 10px 5px; } + div.comment-checkbox-inputs-flex { display: flex; flex-direction: column; justify-content: space-between; align-items: center; -} \ No newline at end of file +} + +div.comment-box-playing { + background-color: #FFDDDD; +}
--- a/interfaces/AB.js Sat Apr 15 11:59:21 2017 +0100 +++ b/interfaces/AB.js Sat Apr 15 12:05:31 2017 +0100 @@ -294,6 +294,7 @@ } $(this.playback).text('Stop'); this.playback.setAttribute("playstate", "playing"); + interfaceContext.commentBoxes.highlightById(audioElement.id); }; this.stopPlayback = function () { if (this.playback.getAttribute("playstate") == "playing") { @@ -301,6 +302,12 @@ $('.comparator-button').removeAttr("disabled"); this.playback.setAttribute("playstate", "ready"); } + var box = interfaceContext.commentBoxes.boxes.find(function (a) { + return a.id === audioElement.id; + }); + if (box) { + box.highlight(false); + } }; this.exportXMLDOM = function (audioObject) { var node = storage.document.createElement('value');
--- a/interfaces/ABX.js Sat Apr 15 11:59:21 2017 +0100 +++ b/interfaces/ABX.js Sat Apr 15 12:05:31 2017 +0100 @@ -280,6 +280,7 @@ } $(this.playback).text('Stop'); this.playback.setAttribute("playstate", "playing"); + interfaceContext.commentBoxes.highlightById(element.id); }; this.stopPlayback = function () { if (this.playback.getAttribute("playstate") == "playing") { @@ -287,6 +288,12 @@ $('.comparator-button').removeAttr("disabled"); this.playback.setAttribute("playstate", "ready"); } + var box = interfaceContext.commentBoxes.boxes.find(function (a) { + return a.id === element.id; + }); + if (box) { + box.highlight(false); + } }; this.getValue = function () { // Return the current value of the object. If there is no value, return 0
--- a/interfaces/ape.js Sat Apr 15 11:59:21 2017 +0100 +++ b/interfaces/ape.js Sat Apr 15 12:05:31 2017 +0100 @@ -590,8 +590,7 @@ $('.track-slider').removeClass('track-slider-playing'); var name = ".track-slider-" + this.parent.id; $(name).addClass('track-slider-playing'); - $('.comment-div').removeClass('comment-box-playing'); - $('#comment-div-' + this.parent.id).addClass('comment-box-playing'); + interfaceContext.commentBoxes.highlightById(audioObject.id); $('.outside-reference').removeClass('track-slider-playing'); this.playing = true; @@ -605,9 +604,14 @@ this.playing = false; var name = ".track-slider-" + this.parent.id; $(name).removeClass('track-slider-playing'); - $('#comment-div-' + this.parent.id).removeClass('comment-box-playing'); $('.track-slider').removeClass('track-slider-disabled'); $('.outside-reference').removeClass('track-slider-disabled'); + var box = interfaceContext.commentBoxes.boxes.find(function (a) { + return a.id === audioObject.id; + }); + if (box) { + box.highlight(false); + } } }; this.exportXMLDOM = function (audioObject) {
--- a/interfaces/discrete.js Sat Apr 15 11:59:21 2017 +0100 +++ b/interfaces/discrete.js Sat Apr 15 12:05:31 2017 +0100 @@ -338,6 +338,7 @@ $('.track-slider-button').text = "Wait"; $('.track-slider-button').attr("disabled", "true"); } + interfaceContext.commentBoxes.highlightById(audioObject.id); }; this.stopPlayback = function () { // Called by audioObject when playback stops @@ -347,6 +348,12 @@ $('.track-slider-button').text = "Play"; this.play.textContent = "Play"; $('.track-slider-button').removeAttr("disabled"); + var box = interfaceContext.commentBoxes.boxes.find(function (a) { + return a.id === audioObject.id; + }); + if (box) { + box.highlight(false); + } } };
--- a/interfaces/mushra.js Sat Apr 15 11:59:21 2017 +0100 +++ b/interfaces/mushra.js Sat Apr 15 12:05:31 2017 +0100 @@ -316,6 +316,7 @@ this.play.setAttribute("playstate", "playing"); $(".track-slider").removeClass('track-slider-playing'); $(this.holder).addClass('track-slider-playing'); + interfaceContext.commentBoxes.highlightById(audioObject.id); var outsideReference = document.getElementById('outside-reference'); if (outsideReference !== null) { $(outsideReference).removeClass('track-slider-playing'); @@ -347,6 +348,12 @@ $(this.slider).addClass("track-slider-range-disabled"); this.slider.setAttribute("disabled", "true"); } + var box = interfaceContext.commentBoxes.boxes.find(function (a) { + return a.id === audioObject.id; + }); + if (box) { + box.highlight(false); + } }; this.getValue = function () { return this.slider.value;
--- a/interfaces/timeline.js Sat Apr 15 11:59:21 2017 +0100 +++ b/interfaces/timeline.js Sat Apr 15 12:05:31 2017 +0100 @@ -430,12 +430,19 @@ // Called when playback has begun canvasIntervalID = window.setInterval(this.canvas.drawTicker.bind(this.canvas), 100); this.playButton.DOM.textContent = "Stop"; + interfaceContext.commentBoxes.highlightById(audioObject.id); }; this.stopPlayback = function () { // Called when playback has stopped. This gets called even if playback never started! window.clearInterval(canvasIntervalID); this.canvas.clearCanvas(this.canvas.layer2); this.playButton.DOM.textContent = "Play"; + var box = interfaceContext.commentBoxes.boxes.find(function (a) { + return a.id === audioObject.id; + }); + if (box) { + box.highlight(false); + } }; this.getValue = function () { // Return the current value of the object. If there is no value, return 0