aboutsummaryrefslogtreecommitdiff
path: root/src/qt/optionsmodel.cpp
diff options
context:
space:
mode:
authorCozz Lovan <cozzlovan@yahoo.com>2013-08-12 17:03:03 +0200
committerWladimir J. van der Laan <laanwj@gmail.com>2013-11-14 14:25:10 +0100
commit6a86c24db146d9ca5d1d5c83099d935c3feb63bb (patch)
tree84ea08401061e81d178a4c2caf34233281227da4 /src/qt/optionsmodel.cpp
parent8dfd8c62dccac96afbda5ad0e66e68ee4820481f (diff)
Coin Control Features
Diffstat (limited to 'src/qt/optionsmodel.cpp')
-rw-r--r--src/qt/optionsmodel.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/qt/optionsmodel.cpp b/src/qt/optionsmodel.cpp
index 65c017f088..bd08a46803 100644
--- a/src/qt/optionsmodel.cpp
+++ b/src/qt/optionsmodel.cpp
@@ -59,6 +59,7 @@ void OptionsModel::Init()
fMinimizeOnClose = settings.value("fMinimizeOnClose", false).toBool();
nTransactionFee = settings.value("nTransactionFee").toLongLong();
language = settings.value("language", "").toString();
+ fCoinControlFeatures = settings.value("fCoinControlFeatures", false).toBool();
// These are shared with core Bitcoin; we want
// command-line options to override the GUI settings:
@@ -207,6 +208,8 @@ QVariant OptionsModel::data(const QModelIndex & index, int role) const
return QVariant(bDisplayAddresses);
case Language:
return settings.value("language", "");
+ case CoinControlFeatures:
+ return QVariant(fCoinControlFeatures);
default:
return QVariant();
}
@@ -275,6 +278,7 @@ bool OptionsModel::setData(const QModelIndex & index, const QVariant & value, in
case Fee:
nTransactionFee = value.toLongLong();
settings.setValue("nTransactionFee", (qint64) nTransactionFee);
+ emit transactionFeeChanged(nTransactionFee);
break;
case DisplayUnit:
nDisplayUnit = value.toInt();
@@ -288,6 +292,12 @@ bool OptionsModel::setData(const QModelIndex & index, const QVariant & value, in
case Language:
settings.setValue("language", value);
break;
+ case CoinControlFeatures: {
+ fCoinControlFeatures = value.toBool();
+ settings.setValue("fCoinControlFeatures", fCoinControlFeatures);
+ emit coinControlFeaturesChanged(fCoinControlFeatures);
+ }
+ break;
default:
break;
}
@@ -302,6 +312,11 @@ qint64 OptionsModel::getTransactionFee()
return (qint64) nTransactionFee;
}
+bool OptionsModel::getCoinControlFeatures()
+{
+ return fCoinControlFeatures;
+}
+
bool OptionsModel::getProxySettings(QString& proxyIP, quint16 &proxyPort) const
{
std::string proxy = GetArg("-proxy", "");