Merge pull request #3039 from Diapolo/Qt_misc
several small Qt-related fixes
This commit is contained in:
commit
75d31c84db
6 changed files with 10 additions and 12 deletions
|
@ -155,11 +155,14 @@ static void initTranslations(QTranslator &qtTranslatorBase, QTranslator &qtTrans
|
|||
#if QT_VERSION < 0x050000
|
||||
void DebugMessageHandler(QtMsgType type, const char * msg)
|
||||
{
|
||||
Q_UNUSED(type);
|
||||
LogPrint("qt", "Bitcoin-Qt: %s\n", msg);
|
||||
}
|
||||
#else
|
||||
void DebugMessageHandler(QtMsgType type, const QMessageLogContext& context, const QString &msg)
|
||||
{
|
||||
Q_UNUSED(type);
|
||||
Q_UNUSED(context);
|
||||
LogPrint("qt", "Bitcoin-Qt: %s\n", qPrintable(msg));
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -751,13 +751,9 @@ void BitcoinGUI::handlePaymentRequest(const SendCoinsRecipient& recipient)
|
|||
walletFrame->handlePaymentRequest(recipient);
|
||||
}
|
||||
|
||||
void BitcoinGUI::showPaymentACK(QString msg)
|
||||
void BitcoinGUI::showPaymentACK(const QString& msg)
|
||||
{
|
||||
#if QT_VERSION < 0x050000
|
||||
message(tr("Payment acknowledged"), Qt::escape(msg), CClientUIInterface::MODAL);
|
||||
#else
|
||||
message(tr("Payment acknowledged"), msg.toHtmlEscaped(), CClientUIInterface::MODAL);
|
||||
#endif
|
||||
message(tr("Payment acknowledged"), GUIUtil::HtmlEscape(msg), CClientUIInterface::MODAL);
|
||||
}
|
||||
|
||||
void BitcoinGUI::setEncryptionStatus(int status)
|
||||
|
|
|
@ -154,7 +154,7 @@ public slots:
|
|||
void askFee(qint64 nFeeRequired, bool *payFee);
|
||||
|
||||
void handlePaymentRequest(const SendCoinsRecipient& recipient);
|
||||
void showPaymentACK(QString msg);
|
||||
void showPaymentACK(const QString& msg);
|
||||
|
||||
/** Show incoming transaction notification for new transactions. */
|
||||
void incomingTransaction(const QString& date, int unit, qint64 amount, const QString& type, const QString& address);
|
||||
|
|
|
@ -24,9 +24,8 @@ ClientModel::ClientModel(OptionsModel *optionsModel, QObject *parent) :
|
|||
numBlocksAtStartup(-1), pollTimer(0)
|
||||
{
|
||||
pollTimer = new QTimer(this);
|
||||
pollTimer->setInterval(MODEL_UPDATE_DELAY);
|
||||
pollTimer->start();
|
||||
connect(pollTimer, SIGNAL(timeout()), this, SLOT(updateTimer()));
|
||||
pollTimer->start(MODEL_UPDATE_DELAY);
|
||||
|
||||
subscribeToCoreSignals();
|
||||
}
|
||||
|
|
|
@ -32,7 +32,7 @@ qint64 WalletModelTransaction::getTransactionFee()
|
|||
|
||||
void WalletModelTransaction::setTransactionFee(qint64 newFee)
|
||||
{
|
||||
fee=newFee;
|
||||
fee = newFee;
|
||||
}
|
||||
|
||||
qint64 WalletModelTransaction::getTotalTransactionAmount()
|
||||
|
@ -40,7 +40,7 @@ qint64 WalletModelTransaction::getTotalTransactionAmount()
|
|||
qint64 totalTransactionAmount = 0;
|
||||
foreach(const SendCoinsRecipient &rcp, recipients)
|
||||
{
|
||||
totalTransactionAmount+=rcp.amount;
|
||||
totalTransactionAmount += rcp.amount;
|
||||
}
|
||||
return totalTransactionAmount;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue