1
0
mirror of synced 2024-11-22 04:56:08 +03:00

issue #77, blur on touchend - seems more native

This commit is contained in:
Igor Vaynberg 2012-06-07 23:56:51 -07:00
parent 5e18e71cb4
commit 3ba3e57715

View File

@ -317,7 +317,7 @@
* blurs any Select2 container that has focus when an element outside them was clicked or received focus
*/
$(document).ready(function () {
$(document).delegate("*", "mousedown focusin touchstart", function (e) {
$(document).delegate("*", "mousedown focusin touchend", function (e) {
var target = $(e.target).closest("div.select2-container").get(0);
$(document).find("div.select2-container-active").each(function () {
if (this !== target) $(this).data("select2").blur();