aboutsummaryrefslogtreecommitdiffstats
path: root/ui/jquery.ui.mouse.js
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2011-08-01 14:16:16 -0400
committerScott González <scott.gonzalez@gmail.com>2011-08-01 14:16:16 -0400
commit350e4ab5b854d2f6aca22d5202c03dcbf59ff4aa (patch)
tree1dad2b0063c554cc2c9f17fcfee65d1559ab30d2 /ui/jquery.ui.mouse.js
parent38028f6de1ae1bb34a30d04cacab5d49a1433e7a (diff)
downloadjquery-ui-350e4ab5b854d2f6aca22d5202c03dcbf59ff4aa.tar.gz
jquery-ui-350e4ab5b854d2f6aca22d5202c03dcbf59ff4aa.zip
Revert "Mouse: Changed mouseHandled check to a local var rather than using originalEvent. Fixed #4333 - Nested draggables problem in IE"
This reverts commit 9c50bdfde0260fc8412eec1c5020ed6b61558ebd.
Diffstat (limited to 'ui/jquery.ui.mouse.js')
-rw-r--r--ui/jquery.ui.mouse.js12
1 files changed, 4 insertions, 8 deletions
diff --git a/ui/jquery.ui.mouse.js b/ui/jquery.ui.mouse.js
index 582eaf9c0..054e5dc63 100644
--- a/ui/jquery.ui.mouse.js
+++ b/ui/jquery.ui.mouse.js
@@ -12,11 +12,6 @@
*/
(function( $, undefined ) {
-var mouseHandled = false;
-$(document).mousedown(function(e) {
- mouseHandled = false;
-});
-
$.widget("ui.mouse", {
version: "@VERSION",
options: {
@@ -50,7 +45,9 @@ $.widget("ui.mouse", {
_mouseDown: function(event) {
// don't let more than one widget handle mouseStart
- if(mouseHandled) {return};
+ // TODO: figure out why we have to use originalEvent
+ event.originalEvent = event.originalEvent || {};
+ if (event.originalEvent.mouseHandled) { return; }
// we may have missed mouseup (out of window)
(this._mouseStarted && this._mouseUp(event));
@@ -96,8 +93,7 @@ $.widget("ui.mouse", {
.bind('mouseup.'+this.widgetName, this._mouseUpDelegate);
event.preventDefault();
-
- mouseHandled = true;
+ event.originalEvent.mouseHandled = true;
return true;
},