Mercurial > hg > webaudioevaluationtool
comparison core.js @ 1537:18bb9a840145
Feature #1295: Page count can be displayed below the Start/Submit buttons
author | Nicholas Jillings <nickjillings@users.noreply.github.com> |
---|---|
date | Thu, 23 Jul 2015 10:48:14 +0100 |
parents | eade64ba381a |
children | 0e525f772934 |
comparison
equal
deleted
inserted
replaced
1536:eade64ba381a | 1537:18bb9a840145 |
---|---|
539 | 539 |
540 // New check if we need to randomise the test order | 540 // New check if we need to randomise the test order |
541 if (specification.randomiseOrder) | 541 if (specification.randomiseOrder) |
542 { | 542 { |
543 specification.audioHolders = randomiseOrder(specification.audioHolders); | 543 specification.audioHolders = randomiseOrder(specification.audioHolders); |
544 for (var i=0; i<specification.audioHolders.length; i++) | |
545 { | |
546 specification.audioHolders[i].presentedId = i; | |
547 } | |
544 } | 548 } |
545 | 549 |
546 $(specification.audioHolders).each(function(index,elem){ | 550 $(specification.audioHolders).each(function(index,elem){ |
547 testState.stateMap.push(elem); | 551 testState.stateMap.push(elem); |
548 }); | 552 }); |
1458 this.enabled = name; | 1462 this.enabled = name; |
1459 }; | 1463 }; |
1460 | 1464 |
1461 this.audioHolderNode = function(parent,xml) { | 1465 this.audioHolderNode = function(parent,xml) { |
1462 this.type = 'audioHolder'; | 1466 this.type = 'audioHolder'; |
1467 this.presentedId = parent.audioHolders.length; | |
1463 this.interfaceNode = function(DOM) { | 1468 this.interfaceNode = function(DOM) { |
1464 var title = DOM.getElementsByTagName('title'); | 1469 var title = DOM.getElementsByTagName('title'); |
1465 if (title.length == 0) {this.title = null;} | 1470 if (title.length == 0) {this.title = null;} |
1466 else {this.title = title[0].textContent;} | 1471 else {this.title = title[0].textContent;} |
1467 this.options = parent.commonInterface.options; | 1472 this.options = parent.commonInterface.options; |