MDL-43992 Javascript: Remove <return> key listener for confirmation
authorAndrew Nicols <andrew@nicols.co.uk>
Wed, 5 Feb 2014 04:14:01 +0000 (12:14 +0800)
committerAndrew Nicols <andrew@nicols.co.uk>
Fri, 7 Feb 2014 08:35:49 +0000 (16:35 +0800)
The listener was previously confirming, even when the cancel or 'No'
buttons were selected. However, having the default action as 'Confirm'
seems dangerous in this situation, so removing this option entirely.

lib/yui/build/moodle-core-notification-confirm/moodle-core-notification-confirm-debug.js
lib/yui/build/moodle-core-notification-confirm/moodle-core-notification-confirm-min.js
lib/yui/build/moodle-core-notification-confirm/moodle-core-notification-confirm.js
lib/yui/src/notification/js/confirm.js

index c34e867..3c6c547 100644 (file)
Binary files a/lib/yui/build/moodle-core-notification-confirm/moodle-core-notification-confirm-debug.js and b/lib/yui/build/moodle-core-notification-confirm/moodle-core-notification-confirm-debug.js differ
index 0a7c636..b3ee827 100644 (file)
Binary files a/lib/yui/build/moodle-core-notification-confirm/moodle-core-notification-confirm-min.js and b/lib/yui/build/moodle-core-notification-confirm/moodle-core-notification-confirm-min.js differ
index c34e867..3c6c547 100644 (file)
Binary files a/lib/yui/build/moodle-core-notification-confirm/moodle-core-notification-confirm.js and b/lib/yui/build/moodle-core-notification-confirm/moodle-core-notification-confirm.js differ
index 6c4bfaa..ec6cf76 100644 (file)
@@ -38,7 +38,6 @@ Y.extend(CONFIRM, M.core.dialogue, {
                 '<h1 id="moodle-dialogue-'+this.get('COUNT')+'-header-text">' + this.get(TITLE) + '</h1>', Y.WidgetStdMod.REPLACE);
 
         this.closeEvents.push(
-            Y.on('key', this.submit, window, 'down:13', this, true),
             Y.on('key', this.submit, window, 'down:27', this, false),
             yes.on('click', this.submit, this, true),
             no.on('click', this.submit, this, false)