Skip to content
Browse files

fix clearing when using jquery 1.6. fixes #386

  • Loading branch information...
1 parent 2adb8d3 commit 6690cc449cfbe2bcb3d5937092a8ec1d19fb52dc @ivaynberg ivaynberg committed
Showing with 5 additions and 1 deletion.
  1. +5 −1 select2.js
View
6 select2.js
@@ -230,6 +230,10 @@
event.preventDefault();
event.stopPropagation();
}
+ function killEventImmediately(event) {
+ event.preventDefault();
+ event.stopImmediatePropagation();
+ }
function measureTextWidth(e) {
if (!sizer){
@@ -1578,7 +1582,7 @@
selection.delegate("abbr", "mousedown", this.bind(function (e) {
if (!this.enabled) return;
this.clear();
- killEvent(e);
+ killEventImmediately(e);
this.close();
this.triggerChange();
this.selection.focus();

0 comments on commit 6690cc4

Please sign in to comment.
Something went wrong with that request. Please try again.