diff options
author | Luke Dashjr <luke-jr+git@utopios.org> | 2012-03-25 17:25:10 -0400 |
---|---|---|
committer | Luke Dashjr <luke-jr+git@utopios.org> | 2012-04-06 12:53:37 -0400 |
commit | fa2544e79faf75923766624acd638e3cbdb9be0d (patch) | |
tree | 7785ea719ba3c922f5f691b6a7e17bae57c2971c /src/qt/guiutil.cpp | |
parent | 9362da78b0d8f0dd7bbad259adcb3e4d0cf58e56 (diff) |
Bugfix: Replace "URL" with "URI" where we aren't actually working with URLs
Diffstat (limited to 'src/qt/guiutil.cpp')
-rw-r--r-- | src/qt/guiutil.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/qt/guiutil.cpp b/src/qt/guiutil.cpp index ad530a78e4..2a3063ba35 100644 --- a/src/qt/guiutil.cpp +++ b/src/qt/guiutil.cpp @@ -52,15 +52,15 @@ void GUIUtil::setupAmountWidget(QLineEdit *widget, QWidget *parent) widget->setAlignment(Qt::AlignRight|Qt::AlignVCenter); } -bool GUIUtil::parseBitcoinURL(const QUrl &url, SendCoinsRecipient *out) +bool GUIUtil::parseBitcoinURI(const QUrl &uri, SendCoinsRecipient *out) { - if(url.scheme() != QString("bitcoin")) + if(uri.scheme() != QString("bitcoin")) return false; SendCoinsRecipient rv; - rv.address = url.path(); + rv.address = uri.path(); rv.amount = 0; - QList<QPair<QString, QString> > items = url.queryItems(); + QList<QPair<QString, QString> > items = uri.queryItems(); for (QList<QPair<QString, QString> >::iterator i = items.begin(); i != items.end(); i++) { bool fShouldReturnFalse = false; @@ -97,18 +97,18 @@ bool GUIUtil::parseBitcoinURL(const QUrl &url, SendCoinsRecipient *out) return true; } -bool GUIUtil::parseBitcoinURL(QString url, SendCoinsRecipient *out) +bool GUIUtil::parseBitcoinURI(QString uri, SendCoinsRecipient *out) { // Convert bitcoin:// to bitcoin: // // Cannot handle this later, because bitcoin:// will cause Qt to see the part after // as host, // which will lowercase it (and thus invalidate the address). - if(url.startsWith("bitcoin://")) + if(uri.startsWith("bitcoin://")) { - url.replace(0, 10, "bitcoin:"); + uri.replace(0, 10, "bitcoin:"); } - QUrl urlInstance(url); - return parseBitcoinURL(urlInstance, out); + QUrl uriInstance(uri); + return parseBitcoinURI(uriInstance, out); } QString GUIUtil::HtmlEscape(const QString& str, bool fMultiLine) |