diff options
-rw-r--r-- | ui/jquery.ui.popup.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ui/jquery.ui.popup.js b/ui/jquery.ui.popup.js index 508209a55..8e5cf198c 100644 --- a/ui/jquery.ui.popup.js +++ b/ui/jquery.ui.popup.js @@ -45,13 +45,13 @@ $.widget( "ui.popup", { .attr( "aria-owns", this.element.attr( "id" ) ); this.element - .addClass( "ui-popup" ) + .addClass( "ui-popup" ); this.close(); this._bind(this.options.trigger, { keydown: function( event ) { // prevent space-to-open to scroll the page, only happens for anchor ui.button - if ( this.options.trigger.is( "a:ui-button" ) && event.keyCode == $.ui.keyCode.SPACE ) { + if ( $.ui.button && this.options.trigger.is( "a:ui-button" ) && event.keyCode == $.ui.keyCode.SPACE ) { event.preventDefault(); } // TODO handle SPACE to open popup? only when not handled by ui.button |