# HG changeset patch # User Brecht De Man # Date 1447841332 -3600 # Node ID cf08f2881a391234d4e7f81b7e93534c98ad9e3f # Parent 025867e74b019bc6754a2a7d81c5161a87cc1c40 Hitting enter in any pop-up goes to the next window (or submits, or starts the test) diff -r 025867e74b01 -r cf08f2881a39 ape.js --- a/ape.js Fri Nov 13 17:59:39 2015 +0000 +++ b/ape.js Wed Nov 18 11:08:52 2015 +0100 @@ -588,7 +588,7 @@ { if (audioEngineContext.timer.testStarted == false) { - alert('You have not started the test! Please press start to begin the test!'); + alert('You have not started the test! Please click a fragment to begin the test!'); return; } } diff -r 025867e74b01 -r cf08f2881a39 core.js --- a/core.js Fri Nov 13 17:59:39 2015 +0000 +++ b/core.js Wed Nov 18 11:08:52 2015 +0100 @@ -190,6 +190,12 @@ textArea.rows = "10"; break; } + document.onkeydown=function(){ + if(window.event.keyCode=='13'){ // when you hit enter + window.event.preventDefault(); // don't make newline + popup.proceedClicked(); // go to the next window (or start the test or submit) + } + } this.popupResponse.appendChild(textArea); textArea.focus(); } else if (node.type == 'checkbox') {