add hides to WP

This commit is contained in:
Matias Alejo Garcia 2015-01-03 14:26:45 -03:00
commit 04ab9f9971
4 changed files with 37 additions and 10 deletions

View file

@ -10,6 +10,9 @@ angular.module('copayApp.controllers').controller('CreateProfileController', fun
go.walletHome();
$scope.isMobile = isMobile.any();
$scope.isWindowsPhoneApp = isMobile.Windows() && isCordova;
$scope.hideForWP = 0;
$scope.createStep = 'storage';
$scope.useLocalstorage = false;
@ -41,6 +44,14 @@ angular.module('copayApp.controllers').controller('CreateProfileController', fun
};
$scope.formFocus = function() {
if ($scope.isWindowsPhoneApp) {
$scope.hideForWP = true;
$timeout(function() {
$scope.$digest();
}, 1);
}
};
$scope.createPin = function(pin) {
preconditions.checkArgument(pin);
preconditions.checkState($rootScope.iden);

View file

@ -6,6 +6,8 @@ angular.module('copayApp.controllers').controller('HomeController', function($sc
$scope.init = function() {
$scope.isMobile = isMobile.any();
$scope.isWindowsPhoneApp = isMobile.Windows() && isCordova;
$scope.isWindowsPhoneApp = 1;
$scope.hideForWP = 0;
$scope.attempt = 0;
// This is only for backwards compat, insight api should link to #!/confirmed directly
@ -31,6 +33,16 @@ angular.module('copayApp.controllers').controller('HomeController', function($sc
$scope.usingLocalStorage = config.plugins.EncryptedLocalStorage;
};
$scope.formFocus = function() {
if ($scope.isWindowsPhoneApp) {
$scope.hideForWP = true;
$timeout(function() {
$scope.$digest();
}, 1);
}
};
pinService.makePinInput($scope, 'pin', function(newValue) {
$scope.openWithPin(newValue);
});