remove ionic-scroll-delegate
This commit is contained in:
parent
b6b619eaca
commit
9a3d833a80
3 changed files with 3 additions and 31 deletions
|
|
@ -1,7 +1,7 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
angular.module('copayApp.controllers').controller('createController',
|
angular.module('copayApp.controllers').controller('createController',
|
||||||
function($scope, $ionicScrollDelegate, $rootScope, $timeout, $log, lodash, go, profileService, configService, gettext, ledger, trezor, platformInfo, derivationPathHelper, ongoingProcess) {
|
function($scope, $rootScope, $timeout, $log, lodash, go, profileService, configService, gettext, ledger, trezor, platformInfo, derivationPathHelper, ongoingProcess) {
|
||||||
|
|
||||||
var isChromeApp = platformInfo.isChromeApp;
|
var isChromeApp = platformInfo.isChromeApp;
|
||||||
var isCordova = platformInfo.isCordova;
|
var isCordova = platformInfo.isCordova;
|
||||||
|
|
@ -89,7 +89,6 @@ angular.module('copayApp.controllers').controller('createController',
|
||||||
this.create = function(form) {
|
this.create = function(form) {
|
||||||
if (form && form.$invalid) {
|
if (form && form.$invalid) {
|
||||||
this.error = gettext('Please enter the required fields');
|
this.error = gettext('Please enter the required fields');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -117,7 +116,6 @@ angular.module('copayApp.controllers').controller('createController',
|
||||||
var pathData = derivationPathHelper.parse($scope.derivationPath);
|
var pathData = derivationPathHelper.parse($scope.derivationPath);
|
||||||
if (!pathData) {
|
if (!pathData) {
|
||||||
this.error = gettext('Invalid derivation path');
|
this.error = gettext('Invalid derivation path');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -131,7 +129,6 @@ angular.module('copayApp.controllers').controller('createController',
|
||||||
|
|
||||||
if (setSeed && !opts.mnemonic && !opts.extendedPrivateKey) {
|
if (setSeed && !opts.mnemonic && !opts.extendedPrivateKey) {
|
||||||
this.error = gettext('Please enter the wallet recovery phrase');
|
this.error = gettext('Please enter the wallet recovery phrase');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -139,7 +136,6 @@ angular.module('copayApp.controllers').controller('createController',
|
||||||
var account = $scope.account;
|
var account = $scope.account;
|
||||||
if (!account || account < 1) {
|
if (!account || account < 1) {
|
||||||
this.error = gettext('Invalid account number');
|
this.error = gettext('Invalid account number');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -155,7 +151,6 @@ angular.module('copayApp.controllers').controller('createController',
|
||||||
ongoingProcess.set('connecting' + self.seedSourceId, false);
|
ongoingProcess.set('connecting' + self.seedSourceId, false);
|
||||||
if (err) {
|
if (err) {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
@ -176,7 +171,6 @@ angular.module('copayApp.controllers').controller('createController',
|
||||||
if (err) {
|
if (err) {
|
||||||
$log.warn(err);
|
$log.warn(err);
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$timeout(function() {
|
$timeout(function() {
|
||||||
$rootScope.$apply();
|
$rootScope.$apply();
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
angular.module('copayApp.controllers').controller('importController',
|
angular.module('copayApp.controllers').controller('importController',
|
||||||
function($scope, $rootScope, $ionicScrollDelegate, $timeout, $log, profileService, configService, notification, go, sjcl, gettext, lodash, ledger, trezor, derivationPathHelper, platformInfo, bwsError, bwcService, ongoingProcess) {
|
function($scope, $rootScope, $timeout, $log, profileService, configService, notification, go, sjcl, gettext, lodash, ledger, trezor, derivationPathHelper, platformInfo, bwsError, bwcService, ongoingProcess) {
|
||||||
|
|
||||||
var isChromeApp = platformInfo.isChromeApp;
|
var isChromeApp = platformInfo.isChromeApp;
|
||||||
var isDevel = platformInfo.isDevel;
|
var isDevel = platformInfo.isDevel;
|
||||||
|
|
@ -53,7 +53,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
|
|
||||||
if (err) {
|
if (err) {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$timeout(function() {
|
$timeout(function() {
|
||||||
$rootScope.$apply();
|
$rootScope.$apply();
|
||||||
});
|
});
|
||||||
|
|
@ -69,7 +68,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
ongoingProcess.set('importingWallet', false);
|
ongoingProcess.set('importingWallet', false);
|
||||||
if (err) {
|
if (err) {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
} else {
|
} else {
|
||||||
$rootScope.$emit('Local/WalletImported', walletId);
|
$rootScope.$emit('Local/WalletImported', walletId);
|
||||||
notification.success(gettext('Success'), gettext('Your wallet has been imported correctly'));
|
notification.success(gettext('Success'), gettext('Your wallet has been imported correctly'));
|
||||||
|
|
@ -90,7 +88,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
} else {
|
} else {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
}
|
}
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return $timeout(function() {
|
return $timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
});
|
});
|
||||||
|
|
@ -116,7 +113,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
} else {
|
} else {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
}
|
}
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return $timeout(function() {
|
return $timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
});
|
});
|
||||||
|
|
@ -143,7 +139,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
this.importBlob = function(form) {
|
this.importBlob = function(form) {
|
||||||
if (form.$invalid) {
|
if (form.$invalid) {
|
||||||
this.error = gettext('There is an error in the form');
|
this.error = gettext('There is an error in the form');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$timeout(function() {
|
$timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
});
|
});
|
||||||
|
|
@ -156,7 +151,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
|
|
||||||
if (!backupFile && !backupText) {
|
if (!backupFile && !backupText) {
|
||||||
this.error = gettext('Please, select your backup file');
|
this.error = gettext('Please, select your backup file');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$timeout(function() {
|
$timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
});
|
});
|
||||||
|
|
@ -176,7 +170,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
this.importMnemonic = function(form) {
|
this.importMnemonic = function(form) {
|
||||||
if (form.$invalid) {
|
if (form.$invalid) {
|
||||||
this.error = gettext('There is an error in the form');
|
this.error = gettext('There is an error in the form');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$timeout(function() {
|
$timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
});
|
});
|
||||||
|
|
@ -191,7 +184,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
var pathData = derivationPathHelper.parse($scope.derivationPath);
|
var pathData = derivationPathHelper.parse($scope.derivationPath);
|
||||||
if (!pathData) {
|
if (!pathData) {
|
||||||
this.error = gettext('Invalid derivation path');
|
this.error = gettext('Invalid derivation path');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
opts.account = pathData.account;
|
opts.account = pathData.account;
|
||||||
|
|
@ -203,7 +195,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
|
|
||||||
if (!words) {
|
if (!words) {
|
||||||
this.error = gettext('Please enter the recovery phrase');
|
this.error = gettext('Please enter the recovery phrase');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
} else if (words.indexOf('xprv') == 0 || words.indexOf('tprv') == 0) {
|
} else if (words.indexOf('xprv') == 0 || words.indexOf('tprv') == 0) {
|
||||||
return _importExtendedPrivateKey(words, opts);
|
return _importExtendedPrivateKey(words, opts);
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -211,7 +202,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
|
|
||||||
if ((wordList.length % 3) != 0) {
|
if ((wordList.length % 3) != 0) {
|
||||||
this.error = gettext('Wrong number of recovery words:') + wordList.length;
|
this.error = gettext('Wrong number of recovery words:') + wordList.length;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -234,7 +224,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
ongoingProcess.clear();
|
ongoingProcess.clear();
|
||||||
if (err) {
|
if (err) {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
@ -248,7 +237,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
ongoingProcess.set('importingWallet', false);
|
ongoingProcess.set('importingWallet', false);
|
||||||
if (err) {
|
if (err) {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return $timeout(function() {
|
return $timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
});
|
});
|
||||||
|
|
@ -263,7 +251,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
this.importHW = function(form) {
|
this.importHW = function(form) {
|
||||||
if (form.$invalid || $scope.account < 0) {
|
if (form.$invalid || $scope.account < 0) {
|
||||||
this.error = gettext('There is an error in the form');
|
this.error = gettext('There is an error in the form');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$timeout(function() {
|
$timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
});
|
});
|
||||||
|
|
@ -277,7 +264,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
if (self.seedSourceId == 'trezor') {
|
if (self.seedSourceId == 'trezor') {
|
||||||
if (account < 1) {
|
if (account < 1) {
|
||||||
this.error = gettext('Invalid account number');
|
this.error = gettext('Invalid account number');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
account = account - 1;
|
account = account - 1;
|
||||||
|
|
@ -313,7 +299,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
ongoingProcess.clear();
|
ongoingProcess.clear();
|
||||||
if (err) {
|
if (err) {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
@ -327,7 +312,6 @@ angular.module('copayApp.controllers').controller('importController',
|
||||||
ongoingProcess.set('importingWallet', false);
|
ongoingProcess.set('importingWallet', false);
|
||||||
if (err) {
|
if (err) {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return $timeout(function() {
|
return $timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
angular.module('copayApp.controllers').controller('joinController',
|
angular.module('copayApp.controllers').controller('joinController',
|
||||||
function($scope, $rootScope, $timeout, $ionicScrollDelegate, go, notification, profileService, configService, storageService, applicationService, $modal, gettext, lodash, ledger, trezor, platformInfo, derivationPathHelper, ongoingProcess) {
|
function($scope, $rootScope, $timeout, go, notification, profileService, configService, storageService, applicationService, $modal, gettext, lodash, ledger, trezor, platformInfo, derivationPathHelper, ongoingProcess) {
|
||||||
|
|
||||||
var isChromeApp = platformInfo.isChromeApp;
|
var isChromeApp = platformInfo.isChromeApp;
|
||||||
var isDevel = platformInfo.isDevel;
|
var isDevel = platformInfo.isDevel;
|
||||||
|
|
@ -55,7 +55,6 @@ angular.module('copayApp.controllers').controller('joinController',
|
||||||
this.join = function(form) {
|
this.join = function(form) {
|
||||||
if (form && form.$invalid) {
|
if (form && form.$invalid) {
|
||||||
self.error = gettext('Please enter the required fields');
|
self.error = gettext('Please enter the required fields');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -78,7 +77,6 @@ angular.module('copayApp.controllers').controller('joinController',
|
||||||
var pathData = derivationPathHelper.parse($scope.derivationPath);
|
var pathData = derivationPathHelper.parse($scope.derivationPath);
|
||||||
if (!pathData) {
|
if (!pathData) {
|
||||||
this.error = gettext('Invalid derivation path');
|
this.error = gettext('Invalid derivation path');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
opts.account = pathData.account;
|
opts.account = pathData.account;
|
||||||
|
|
@ -92,7 +90,6 @@ angular.module('copayApp.controllers').controller('joinController',
|
||||||
if (setSeed && !opts.mnemonic && !opts.extendedPrivateKey) {
|
if (setSeed && !opts.mnemonic && !opts.extendedPrivateKey) {
|
||||||
|
|
||||||
this.error = gettext('Please enter the wallet recovery phrase');
|
this.error = gettext('Please enter the wallet recovery phrase');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -100,7 +97,6 @@ angular.module('copayApp.controllers').controller('joinController',
|
||||||
var account = $scope.account;
|
var account = $scope.account;
|
||||||
if (!account || account < 1) {
|
if (!account || account < 1) {
|
||||||
this.error = gettext('Invalid account number');
|
this.error = gettext('Invalid account number');
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -115,7 +111,6 @@ angular.module('copayApp.controllers').controller('joinController',
|
||||||
ongoingProcess.set('connecting' + self.seedSourceId, false);
|
ongoingProcess.set('connecting' + self.seedSourceId, false);
|
||||||
if (err) {
|
if (err) {
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
@ -135,7 +130,6 @@ angular.module('copayApp.controllers').controller('joinController',
|
||||||
if (err) {
|
if (err) {
|
||||||
ongoingProcess.set('joiningWallet', false);
|
ongoingProcess.set('joiningWallet', false);
|
||||||
self.error = err;
|
self.error = err;
|
||||||
$ionicScrollDelegate.scrollTop();
|
|
||||||
$rootScope.$apply();
|
$rootScope.$apply();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue