r3316 committed - Buttons: Removed the partial click event prevention. It's better to no...

r3316 committed - Buttons: Removed the partial click event prevention. It's better to no...


Revision: 3316
Author: scott.gonzalez
Date: Mon Sep 28 18:44:00 2009
Log: Buttons: Removed the partial click event prevention. It's better to
not have any prevention than to have a partial prevention. Also, actually
disabling a native button would prevent the click from happening anyway.
http://code.google.com/p/jquery-ui/source/detail?r=3316
Modified:
/branches/dev/ui/jquery.ui.button.js
=======================================
--- /branches/dev/ui/jquery.ui.button.js    Mon Sep 28 16:56:41 2009
+++ /branches/dev/ui/jquery.ui.button.js    Mon Sep 28 18:44:00 2009
@@ -41,13 +41,6 @@
            .bind("mouseup.button", function() {
                if (self.options.disabled) { return; }
                $(this).removeClass("ui-state-active");
-            })
-            .bind("click", function(event) {
-                if (self.options.disabled) {
-                    // this works only when .button() is called before .click(), not that
useful
-                    // also, should we instead offer a click option, and leave the native
click alone?
-                    event.stopImmediatePropagation();
-                }
            });
    },