autofocus changes

This commit is contained in:
Gabriel Bazán 2015-09-29 15:48:55 -03:00
commit 4572b9a9c9
2 changed files with 11 additions and 8 deletions

View file

@ -16,7 +16,7 @@
<div class="input m20t"> <div class="input m20t">
<input type="password" placeholder="{{'Your password'|translate}}" <input type="password" placeholder="{{'Your password'|translate}}"
name="password" ng-model="pass.password" autofocus> id="passwordInput" name="password" ng-model="pass.password">
</div> </div>
</div> </div>
<div class="row"> <div class="row">

View file

@ -9,6 +9,8 @@ angular.module('copayApp.controllers').controller('passwordController',
self.isVerification = false; self.isVerification = false;
document.getElementById("passwordInput").focus();
self.close = function(cb) { self.close = function(cb) {
return cb('No password given'); return cb('No password given');
}; };
@ -17,6 +19,7 @@ angular.module('copayApp.controllers').controller('passwordController',
self.error = false; self.error = false;
if (isSetup && !self.isVerification) { if (isSetup && !self.isVerification) {
document.getElementById("passwordInput").focus();
self.isVerification = true; self.isVerification = true;
pass1 = self.password; pass1 = self.password;
self.password = null; self.password = null;