Skip to content

Commit 3735bab

Browse files
shellscapescottgonzalez
authored andcommitted
Button: adding event.preventDefault. Fixes #5945 - Disabled buttons still allow clicks
(cherry picked from commit 597a313)
1 parent ad947c7 commit 3735bab

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

ui/jquery.ui.button.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@ $.widget( "ui.button", {
9696
})
9797
.bind( "click.button", function( event ) {
9898
if ( options.disabled ) {
99+
event.preventDefault();
99100
event.stopImmediatePropagation();
100101
}
101102
});

0 commit comments

Comments
 (0)