Merge pull request #217 from Bitcoin-com/wallet/task/416

Improvement - 416 - New Send Tab screen
This commit is contained in:
Brendon Duncan 2018-07-17 19:13:13 +12:00 committed by GitHub
commit 4cbaef5af6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 744 additions and 318 deletions

View file

@ -17,7 +17,27 @@ angular.module('copayApp.services').factory('clipboardService', function ($http,
// No supported
return;
}
};
root.readFromClipboard = function (cb) {
$log.debug("Read from clipboard");
if (platformInfo.isCordova) {
cordova.plugins.clipboard.paste(function(text) {
cb(text);
})
} else if (platformInfo.isNW) {
cb(nodeWebkitService.readFromClipboard());
} else {
navigator.clipboard.readText()
.then(text => {
cb(text);
})
.catch(err => {
$log.debug("Clipboard reading is not supported in browser..");
});
return;
}
};
return root;

View file

@ -228,10 +228,12 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat
} else if (/^https?:\/\//.test(data)) {
payproService.getPayProDetails(data, coin, function(err, details) {
if (err) {
root.showMenu({
data: data,
type: 'url'
});
if ($state.includes('tabs.scan')) {
root.showMenu({
data: data,
type: 'url'
});
}
return;
}
handlePayPro(details);