diff options
author | Paul Bakaus <paul.bakaus@googlemail.com> | 2008-05-29 16:43:04 +0000 |
---|---|---|
committer | Paul Bakaus <paul.bakaus@googlemail.com> | 2008-05-29 16:43:04 +0000 |
commit | cd2adeb7259d1705630fa5c9537667066cc8ae8b (patch) | |
tree | e4c0ef81455466ad5a270c48dff686d0def7eb45 /ui | |
parent | 8c1d7753156086393ba5c200f83cc5868d5e24c2 (diff) | |
download | jquery-ui-cd2adeb7259d1705630fa5c9537667066cc8ae8b.tar.gz jquery-ui-cd2adeb7259d1705630fa5c9537667066cc8ae8b.zip |
core: fixed mouse plugin event binding - now binds events with the namespace this.widgetName
Diffstat (limited to 'ui')
-rw-r--r-- | ui/source/ui.core.js | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/ui/source/ui.core.js b/ui/source/ui.core.js index f9b76aa4f..722794bd3 100644 --- a/ui/source/ui.core.js +++ b/ui/source/ui.core.js @@ -159,8 +159,8 @@ $.ui.mouse = {
mouseInit: function() {
var self = this;
-
- this.element.bind('mousedown.mouse', function(e) {
+
+ this.element.bind('mousedown.'+this.widgetName, function(e) {
return self.mouseDown(e);
});
@@ -176,7 +176,7 @@ // TODO: make sure destroying one instance of mouse doesn't mess with
// other instances of mouse
mouseDestroy: function() {
- this.element.unbind('.mouse');
+ this.element.unbind('.'+this.widgetName);
// Restore text selection in IE
($.browser.msie
@@ -211,8 +211,8 @@ return self.mouseUp(e);
};
$(document)
- .bind('mousemove.mouse', this._mouseMoveDelegate)
- .bind('mouseup.mouse', this._mouseUpDelegate);
+ .bind('mousemove.'+this.widgetName, this._mouseMoveDelegate)
+ .bind('mouseup.'+this.widgetName, this._mouseUpDelegate);
return false;
},
@@ -239,8 +239,8 @@ mouseUp: function(e) {
$(document)
- .unbind('mousemove.mouse', this._mouseMoveDelegate)
- .unbind('mouseup.mouse', this._mouseUpDelegate);
+ .unbind('mousemove.'+this.widgetName, this._mouseMoveDelegate)
+ .unbind('mouseup.'+this.widgetName, this._mouseUpDelegate);
if (this._mouseStarted) {
this._mouseStarted = false;
|