Merge pull request #936 from yemel/feature/android-cordova

Android - Migration to Cordova + Crosswalk Framework
This commit is contained in:
Matias Alejo Garcia 2014-07-25 16:40:13 -03:00
commit 560702df58
51 changed files with 4706 additions and 12 deletions

View file

@ -59,13 +59,16 @@ Structure.parseBitcoinURI = function(uri) {
data = splitDots[1];
var splitQuestion = data.split('?');
ret.address = splitQuestion[0];
var search = splitQuestion[1];
data = JSON.parse('{"' + search.replace(/&/g, '","').replace(/=/g, '":"') + '"}',
function(key, value) {
return key === "" ? value : decodeURIComponent(value);
});
ret.amount = parseFloat(data.amount);
ret.message = data.message;
if (splitQuestion.length > 1) {
var search = splitQuestion[1];
data = JSON.parse('{"' + search.replace(/&/g, '","').replace(/=/g, '":"') + '"}',
function(key, value) {
return key === "" ? value : decodeURIComponent(value);
});
ret.amount = parseFloat(data.amount);
ret.message = data.message;
}
return ret;
};