mirror of
https://github.com/overte-org/overte.git
synced 2025-04-23 15:13:41 +02:00
Raise and lower keyboard on password fields
This commit is contained in:
parent
c9a00e86d1
commit
20623ebddb
2 changed files with 2 additions and 2 deletions
|
@ -19,7 +19,7 @@
|
|||
function shouldRaiseKeyboard() {
|
||||
var nodeName = document.activeElement.nodeName;
|
||||
var nodeType = document.activeElement.type;
|
||||
if (nodeName === "INPUT" && (nodeType === "text" || nodeType === "number")
|
||||
if (nodeName === "INPUT" && (nodeType === "text" || nodeType === "number" || nodeType === "password")
|
||||
|| document.activeElement.nodeName === "TEXTAREA") {
|
||||
return true;
|
||||
} else {
|
||||
|
|
|
@ -56,7 +56,7 @@ function setUpKeyboardControl() {
|
|||
}
|
||||
}
|
||||
|
||||
var inputs = document.querySelectorAll("input[type=text], input[type=number], textarea");
|
||||
var inputs = document.querySelectorAll("input[type=text], input[type=password], input[type=number], textarea");
|
||||
for (var i = 0, length = inputs.length; i < length; i++) {
|
||||
inputs[i].addEventListener("focus", raiseKeyboard);
|
||||
inputs[i].addEventListener("blur", lowerKeyboard);
|
||||
|
|
Loading…
Reference in a new issue