Opened 7 years ago
Closed 6 years ago
#14971 closed bug (notabug)
Jquery UI Selectable - event fires twice when browser was left
Reported by: | thmoeller | Owned by: | thmoeller |
---|---|---|---|
Priority: | minor | Milestone: | none |
Component: | ui.selectable | Version: | 1.11.3 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
I have a selectable table with jquery ui and metakey active. For testing purpose i am alerting whenever a row is selected or deselected. This works as long as the focus remains within the browser (tested with Chrome, latest release). But when i click on an other application window and then return to the table directly clicking on a row, the selected event fires twice (two alerts).
$("#sel-table tbody").bind("mousedown", function(e) {
e.metaKey = true;
}).selectable({
selected: function( e, ui ) {
alert('Selected')
}
},{
unselected: function( e, ui ) {
alert('Unselected')
}
} );
Complete code on JS Fiddle (https://jsfiddle.net/tmoeller/pg9264d1)
Is it a bug or feature. If feature, how can this be avoided?? Any ideas on this??
tmoe
Change History (3)
comment:1 Changed 7 years ago by
Owner: | set to thmoeller |
---|---|
Status: | new → pending |
comment:2 Changed 7 years ago by
Component: | ui.core → ui.selectable |
---|
comment:3 Changed 6 years ago by
Resolution: | → notabug |
---|---|
Status: | pending → closed |
Closing due to inactivity.
I'm not seeing this behavior. Can you please list the steps in detail? Are you seeing this only in certain browsers? Are you seeing this if you don't use
alert()
?