]> 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:05:39 +0000 (18:05 -0500)
tests/unit/dialog/dialog_tickets.js
ui/jquery.ui.dialog.js

index e65f939e02a05f1b928f2635e522ef932949ce29..b203ca7d58d62b36daf0210b30e9aab6892f5aed 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 e8107db7ccf50c75b58372841e4dbafd8faddb8d..065d640fb313e7516aef3fcb8203c638db096046 100644 (file)
@@ -293,7 +293,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;
                                }