]> source.dussan.org Git - jquery-ui.git/commitdiff
Dialog: Update to 96e5c24 - keyup apparently doesn't work like I thought it would...
authorCorey Frang <gnarf@gnarf.net>
Sat, 20 Aug 2011 23:05:39 +0000 (18:05 -0500)
committerCorey Frang <gnarf@gnarf.net>
Sat, 20 Aug 2011 23:06:16 +0000 (18:06 -0500)
(cherry picked from commit dfe75e1b552013c440186645a7a1ae9ec3c757b5)

tests/unit/dialog/dialog_tickets.js
ui/jquery.ui.dialog.js

index acfddab4352d4dd5934e60d528ef76671c630847..db591bae87beef0347aef6222d753d2b00fd4f92 100644 (file)
@@ -14,7 +14,7 @@ asyncTest( "#3123: Prevent tabbing out of modal dialogs", function() {
 
        inputs.eq( 1 ).focus();
        equal( document.activeElement, inputs[1], "Focus set on second input" );
-       inputs.eq( 1 ).simulate( "keyup", { keyCode: $.ui.keyCode.TAB });
+       inputs.eq( 1 ).simulate( "keydown", { keyCode: $.ui.keyCode.TAB });
 
        setTimeout( checkTab, 2 );
 
index 3d11cf948c361c85066048e57ba916633693bf74..f6ecdf6a28e799ddceb88a352f886abf744b9c9e 100644 (file)
@@ -330,7 +330,7 @@ $.widget("ui.dialog", {
 
                // prevent tabbing out of modal dialogs
                if ( options.modal ) {
-                       uiDialog.bind( "keyup.ui-dialog", function( event ) {
+                       uiDialog.bind( "keydown.ui-dialog", function( event ) {
                                if ( event.keyCode !== $.ui.keyCode.TAB ) {
                                        return;
                                }