# HG changeset patch # User Nicholas Jillings # Date 1437646236 -3600 # Node ID 02ca9ef612c30210d30da9ba26e8e8548f9d4069 # Parent 0e525f772934eec5f837907e95372607534a8094 Feature #1302: Enter key bounded to button proceed of popup. Only triggered if popup is visible. All enter codes are captured though. diff -r 0e525f772934 -r 02ca9ef612c3 core.js --- a/core.js Thu Jul 23 10:58:08 2015 +0100 +++ b/core.js Thu Jul 23 11:10:36 2015 +0100 @@ -105,6 +105,13 @@ var blank = document.getElementsByClassName('testHalt')[0]; blank.style.zIndex = 2; blank.style.visibility = 'visible'; + $(window).keypress(function(e){ + if (e.keyCode == 13 && popup.popup.style.visibility == 'visible') + { + // Enter key pressed + popup.buttonProceed.onclick(); + } + }); }; this.hidePopup = function(){