1
0
mirror of synced 2024-11-26 14:56:07 +03:00

do not open when clicked on a search choice. fixes #336

This commit is contained in:
Igor Vaynberg 2012-08-16 22:24:58 -07:00
parent 045bff7fe4
commit 7b60524b35

View File

@ -1857,6 +1857,10 @@
this.container.delegate(selector, "mousedown", this.bind(function (e) { this.container.delegate(selector, "mousedown", this.bind(function (e) {
if (!this.enabled) return; if (!this.enabled) return;
if ($(e.target).closest(".select2-search-choice").length > 0) {
// clicked inside a select2 search choice, do not open
return;
}
this.clearPlaceholder(); this.clearPlaceholder();
this.open(); this.open();
this.focusSearch(); this.focusSearch();