diff options
author | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2012-11-16 10:55:11 +0100 |
---|---|---|
committer | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2012-11-26 10:28:23 +0100 |
commit | d8b98ec3bb077224aff381101e6d845ea6ffe7a3 (patch) | |
tree | 0dc97748225a7346d8d2fa3026ab3bd85eeda141 /ui | |
parent | e3dcaf28ebd24c0e5745ef4807786c2835fc01e7 (diff) | |
download | jquery-ui-d8b98ec3bb077224aff381101e6d845ea6ffe7a3.tar.gz jquery-ui-d8b98ec3bb077224aff381101e6d845ea6ffe7a3.zip |
Dialog: Tiny code improvements
Diffstat (limited to 'ui')
-rw-r--r-- | ui/jquery.ui.dialog.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ui/jquery.ui.dialog.js b/ui/jquery.ui.dialog.js index 9bd1f44a0..23c973975 100644 --- a/ui/jquery.ui.dialog.js +++ b/ui/jquery.ui.dialog.js @@ -209,7 +209,9 @@ $.widget("ui.dialog", { this._size(); this._position( this.options.position ); - this.overlay = this.options.modal ? new $.ui.dialog.overlay( this ) : null; + if ( this.options.modal ) { + this.overlay = new $.ui.dialog.overlay( this ); + } this._moveToTop( null, true ); this._show( this.uiDialog, this.options.show ); @@ -277,7 +279,7 @@ $.widget("ui.dialog", { if ( event.keyCode !== $.ui.keyCode.TAB ) { return; } - var tabbables = $( ":tabbable", this.uiDialog ), + var tabbables = this.uiDialog.find( ":tabbable" ), first = tabbables.filter( ":first" ), last = tabbables.filter( ":last" ); |