parent
3cfd4d7889
commit
793d86c9c3
|
@ -2399,22 +2399,41 @@ the specific language governing permissions and limitations under the Apache Lic
|
|||
}
|
||||
}));
|
||||
|
||||
selection.on("mousedown touchstart", this.bind(function (e) {
|
||||
// Prevent IE from generating a click event on the body
|
||||
reinsertElement(selection);
|
||||
if(this.supportsTouchEvents) {
|
||||
selection.on("mousedown touchstart", this.bind(function (e) {
|
||||
// Prevent IE from generating a click event on the body
|
||||
reinsertElement(selection);
|
||||
|
||||
if (!this.container.hasClass("select2-container-active")) {
|
||||
this.opts.element.trigger($.Event("select2-focus"));
|
||||
}
|
||||
if (!this.container.hasClass("select2-container-active")) {
|
||||
this.opts.element.trigger($.Event("select2-focus"));
|
||||
}
|
||||
|
||||
if (this.opened()) {
|
||||
this.close();
|
||||
} else if (this.isInterfaceEnabled()) {
|
||||
this.open();
|
||||
}
|
||||
if (this.opened()) {
|
||||
this.close();
|
||||
} else if (this.isInterfaceEnabled()) {
|
||||
this.open();
|
||||
}
|
||||
|
||||
killEvent(e);
|
||||
}));
|
||||
killEvent(e);
|
||||
}));
|
||||
} else {
|
||||
selection.on("mousedown", this.bind(function (e) {
|
||||
// Prevent IE from generating a click event on the body
|
||||
reinsertElement(selection);
|
||||
|
||||
if (!this.container.hasClass("select2-container-active")) {
|
||||
this.opts.element.trigger($.Event("select2-focus"));
|
||||
}
|
||||
|
||||
if (this.opened()) {
|
||||
this.close();
|
||||
} else if (this.isInterfaceEnabled()) {
|
||||
this.open();
|
||||
}
|
||||
|
||||
killEvent(e);
|
||||
}));
|
||||
}
|
||||
|
||||
dropdown.on("mousedown touchstart", this.bind(function() {
|
||||
if (this.opts.shouldFocusInput(this)) {
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue