|
|
@@ -1184,10 +1184,15 @@
|
|
|
|
|
|
function mobileInputEvent(e) {
|
|
|
var input = this, $input = $(input);
|
|
|
+ input.focus();
|
|
|
|
|
|
//backspace in chrome32 only fires input event - detect & treat
|
|
|
var caretPos = caret(input),
|
|
|
currentValue = input._valueGet();
|
|
|
+
|
|
|
+ console.log(currentValue);
|
|
|
+ currentValue = currentValue.replace(new RegExp("(" + escapeRegex(getActiveBufferTemplate().join('')) + ")*"), "");
|
|
|
+ console.log(currentValue);
|
|
|
//correct caretposition for chrome
|
|
|
if (caretPos.begin > currentValue.length) {
|
|
|
caret(input, currentValue.length);
|
|
|
@@ -1199,7 +1204,6 @@
|
|
|
e.keyCode = opts.keyCode.BACKSPACE;
|
|
|
keydownEvent.call(input, e);
|
|
|
} else { //nonnumerics don't fire keypress
|
|
|
- currentValue = currentValue.replace(new RegExp("(" + escapeRegex(getActiveBufferTemplate().join('')) + ")*"), "");
|
|
|
checkVal(input, false, false, currentValue.split(''));
|
|
|
writeBuffer(input, getActiveBuffer());
|
|
|
if (isComplete(getActiveBuffer()) === true)
|
|
|
@@ -1382,6 +1386,11 @@
|
|
|
// as the other inputevents aren't reliable for the moment we only base on the input event
|
|
|
// needs follow-up
|
|
|
if (android || androidfirefox || androidchrome) {
|
|
|
+ $el.attr("autocomplete","off")
|
|
|
+ .attr("autocorrect","off")
|
|
|
+ .attr("autocapitalize","off")
|
|
|
+ .attr("spellcheck",false);
|
|
|
+
|
|
|
$el.unbind("keydown.inputmask", keydownEvent
|
|
|
).unbind("keypress.inputmask", keypressEvent
|
|
|
).unbind("keyup.inputmask", keyupEvent);
|