Permalink
Browse files

Popup: Binds document mousedown instead of click. The click event is …

…triggered when the mouse button is released, which virtually always exceeds _closeTry delay, leading to erroneous popup close.
  • Loading branch information...
1 parent c6cce9c commit 96c6b94c8de7b67cb0619fbd5eb24cdf4ce47739 @rxaviers committed May 26, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 ui/jquery.ui.popup.js
View
2 ui/jquery.ui.popup.js
@@ -181,7 +181,7 @@ $.widget( "ui.popup", {
});
this._bind( this.document, {
- click: function( event ) {
+ mousedown: function( event ) {
if ( this.isOpen ) {
if ( $( event.target ).closest( this.element.add( this.options.trigger ) ).length ) {
this._closeVet();

0 comments on commit 96c6b94

Please sign in to comment.