]> source.dussan.org Git - jquery-ui.git/commitdiff
Mouse: Unbind events bound to document on destroy. Fixes #8199 - _mouseDestroy keeps...
authorScott González <scott.gonzalez@gmail.com>
Mon, 19 Mar 2012 13:47:38 +0000 (09:47 -0400)
committerScott González <scott.gonzalez@gmail.com>
Mon, 19 Mar 2012 13:47:38 +0000 (09:47 -0400)
ui/jquery.ui.mouse.js

index 64a081961eb08f3b27a6168eb17a773ec3114299..5e7744418e3330c04ccda783a5aaeb20d86f1cd0 100644 (file)
@@ -46,6 +46,9 @@ $.widget("ui.mouse", {
        // other instances of mouse
        _mouseDestroy: function() {
                this.element.unbind('.'+this.widgetName);
+               $(document)
+                       .unbind('mousemove.'+this.widgetName, this._mouseMoveDelegate)
+                       .unbind('mouseup.'+this.widgetName, this._mouseUpDelegate);
        },
 
        _mouseDown: function(event) {