Changeset View
Changeset View
Standalone View
Standalone View
src/qt/transactiondesc.cpp
// Copyright (c) 2011-2016 The Bitcoin Core developers | // Copyright (c) 2011-2016 The Bitcoin Core developers | ||||
// Distributed under the MIT software license, see the accompanying | // Distributed under the MIT software license, see the accompanying | ||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | // file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||||
#include <qt/transactiondesc.h> | #include <qt/transactiondesc.h> | ||||
#include <cashaddrenc.h> | #include <cashaddrenc.h> | ||||
#include <chain.h> | #include <chain.h> | ||||
#include <consensus/consensus.h> | #include <consensus/consensus.h> | ||||
#include <interfaces/node.h> | #include <interfaces/node.h> | ||||
#include <key_io.h> | #include <key_io.h> | ||||
#include <policy/policy.h> | |||||
#include <qt/bitcoinunits.h> | #include <qt/bitcoinunits.h> | ||||
#include <qt/guiutil.h> | #include <qt/guiutil.h> | ||||
#include <qt/paymentserver.h> | #include <qt/paymentserver.h> | ||||
#include <qt/transactionrecord.h> | #include <qt/transactionrecord.h> | ||||
#include <script/script.h> | #include <script/script.h> | ||||
#include <timedata.h> | #include <timedata.h> | ||||
#include <util.h> | #include <util.h> | ||||
#include <validation.h> | #include <validation.h> | ||||
▲ Show 20 Lines • Show All 266 Lines • ▼ Show 20 Lines | if (wtx.value_map.count("comment") && !wtx.value_map["comment"].empty()) { | ||||
strHTML += "<br><b>" + tr("Comment") + ":</b><br>" + | strHTML += "<br><b>" + tr("Comment") + ":</b><br>" + | ||||
GUIUtil::HtmlEscape(wtx.value_map["comment"], true) + "<br>"; | GUIUtil::HtmlEscape(wtx.value_map["comment"], true) + "<br>"; | ||||
} | } | ||||
strHTML += | strHTML += | ||||
"<b>" + tr("Transaction ID") + ":</b> " + rec->getTxID() + "<br>"; | "<b>" + tr("Transaction ID") + ":</b> " + rec->getTxID() + "<br>"; | ||||
strHTML += "<b>" + tr("Transaction total size") + ":</b> " + | strHTML += "<b>" + tr("Transaction total size") + ":</b> " + | ||||
QString::number(wtx.tx->GetTotalSize()) + " bytes<br>"; | QString::number(wtx.tx->GetTotalSize()) + " bytes<br>"; | ||||
strHTML += "<b>" + tr("Transaction virtual size") + ":</b> " + | |||||
QString::number(GetVirtualTransactionSize(*wtx.tx)) + | |||||
" bytes<br>"; | |||||
strHTML += "<b>" + tr("Output index") + ":</b> " + | strHTML += "<b>" + tr("Output index") + ":</b> " + | ||||
QString::number(rec->getOutputIndex()) + "<br>"; | QString::number(rec->getOutputIndex()) + "<br>"; | ||||
// Message from normal bitcoincash:URI (bitcoincash:123...?message=example) | // Message from normal bitcoincash:URI (bitcoincash:123...?message=example) | ||||
for (const std::pair<std::string, std::string> &r : orderForm) { | for (const std::pair<std::string, std::string> &r : orderForm) { | ||||
if (r.first == "Message") { | if (r.first == "Message") { | ||||
strHTML += "<br><b>" + tr("Message") + ":</b><br>" + | strHTML += "<br><b>" + tr("Message") + ":</b><br>" + | ||||
GUIUtil::HtmlEscape(r.second, true) + "<br>"; | GUIUtil::HtmlEscape(r.second, true) + "<br>"; | ||||
▲ Show 20 Lines • Show All 98 Lines • Show Last 20 Lines |