فهرست منبع

Merge pull request #610 from MaxxSoftware/master

Firefox Tab and Enter keys issue.
Igor Vaynberg 12 سال پیش
والد
کامیت
fa908972b4
1فایلهای تغییر یافته به همراه3 افزوده شده و 0 حذف شده
  1. 3 0
      select2.js

+ 3 - 0
select2.js

@@ -1607,6 +1607,9 @@ the specific language governing permissions and limitations under the Apache Lic
                 }
             }));
             selection.bind("keypress", this.bind(function(e) {
+		if (e.which == KEY.DELETE || e.which == KEY.BACKSPACE || e.which == KEY.TAB || e.which == KEY.ENTER || e.which == 0) {
+			return
+		}
                 var key = String.fromCharCode(e.which);
                 this.search.val(key);
                 this.open();