Bug fixes - ledger testing

This commit is contained in:
Andy Phillipson 2017-04-07 10:54:30 -04:00
commit 413990f94c
9 changed files with 66 additions and 55 deletions

View file

@ -183,7 +183,7 @@ angular.module('copayApp.controllers').controller('createController',
return;
}
src.getInfoForNewWallet(opts, function(err, lopts) {
src.getInfoForNewWallet(opts.n > 1, account, function(err, lopts) {
ongoingProcess.set('connecting' + $scope.seedSource.id, false);
if (err) {
popupService.showAlert(gettextCatalog.getString('Error'), err);

View file

@ -35,7 +35,7 @@ angular.module('copayApp.controllers').controller('importController',
if ($scope.isChromeApp || $scope.isDevel) {
$scope.seedOptions.push({
id: walletService.externalSource.trezor.id,
label: walletService.externalSource.ledger.longName,
label: walletService.externalSource.trezor.longName,
});
$scope.formData.seedSource = $scope.seedOptions[0];
}

View file

@ -138,6 +138,7 @@ angular.module('copayApp.controllers').controller('joinController',
account = account - 1;
opts.account = account;
opts.isMultisig = true;
ongoingProcess.set('connecting' + self.seedSourceId, true);
var src = self.seedSourceId == walletService.externalSource.ledger.id ? ledger : trezor;

View file

@ -8,20 +8,22 @@ angular.module('copayApp.controllers').controller('preferencesExternalController
return source.id == wallet.getPrivKeyExternalSourceName();
});
$scope.hardwareConnected = $scope.externalSource.version.length > 0;
if ($scope.externalSource.hasEmbeddedHardware) {
$scope.hardwareConnected = $scope.externalSource.version.length > 0;
$scope.showMneumonicFromHardwarePopup = function() {
var title = gettextCatalog.getString('Warning!');
var message = gettextCatalog.getString('Are you being watched? Anyone with your recovery phrase can access or spend your bitcoin.');
popupService.showConfirm(title, message, null, null, function(res) {
if (res) {
walletService.showMneumonicFromHardware(wallet, function(err) {
if (err) {
popupService.showAlert(gettextCatalog.getString('Error'), err.message || err);
}
});
}
});
};
$scope.showMneumonicFromHardwarePopup = function() {
var title = gettextCatalog.getString('Warning!');
var message = gettextCatalog.getString('Are you being watched? Anyone with your recovery phrase can access or spend your bitcoin.');
popupService.showConfirm(title, message, null, null, function(res) {
if (res) {
walletService.showMneumonicFromHardware(wallet, function(err) {
if (err) {
popupService.showAlert(gettextCatalog.getString('Error'), err.message || err);
}
});
}
});
};
}
});