mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-12 23:18:14 +01:00
Cleanup code using forward declarations.
Use misc methods of avoiding unnecesary header includes. Replace int typedefs with int##_t from stdint.h. Replace PRI64[xdu] with PRI[xdu]64 from inttypes.h. Normalize QT_VERSION ifs where possible. Resolve some indirect dependencies as direct ones. Remove extern declarations from .cpp files.
This commit is contained in:
@@ -9,13 +9,13 @@
|
||||
#include "optionsmodel.h"
|
||||
|
||||
#include "bitcoinunits.h"
|
||||
#include "init.h"
|
||||
#include "core.h"
|
||||
#include "wallet.h"
|
||||
#include "netbase.h"
|
||||
#include "walletdb.h"
|
||||
#include "guiutil.h"
|
||||
|
||||
#include "init.h"
|
||||
#include "main.h"
|
||||
#include "net.h"
|
||||
#include "walletdb.h"
|
||||
|
||||
#include <QSettings>
|
||||
|
||||
OptionsModel::OptionsModel(QObject *parent) :
|
||||
@@ -200,7 +200,7 @@ QVariant OptionsModel::data(const QModelIndex & index, int role) const
|
||||
return QVariant(5);
|
||||
}
|
||||
case Fee:
|
||||
return QVariant(nTransactionFee);
|
||||
return QVariant((qint64) nTransactionFee);
|
||||
case DisplayUnit:
|
||||
return QVariant(nDisplayUnit);
|
||||
case DisplayAddresses:
|
||||
@@ -274,7 +274,7 @@ bool OptionsModel::setData(const QModelIndex & index, const QVariant & value, in
|
||||
break;
|
||||
case Fee:
|
||||
nTransactionFee = value.toLongLong();
|
||||
settings.setValue("nTransactionFee", nTransactionFee);
|
||||
settings.setValue("nTransactionFee", (qint64) nTransactionFee);
|
||||
break;
|
||||
case DisplayUnit:
|
||||
nDisplayUnit = value.toInt();
|
||||
@@ -299,7 +299,7 @@ bool OptionsModel::setData(const QModelIndex & index, const QVariant & value, in
|
||||
|
||||
qint64 OptionsModel::getTransactionFee()
|
||||
{
|
||||
return nTransactionFee;
|
||||
return (qint64) nTransactionFee;
|
||||
}
|
||||
|
||||
bool OptionsModel::getProxySettings(QString& proxyIP, quint16 &proxyPort) const
|
||||
|
||||
Reference in New Issue
Block a user