|
|
|
@ -40,7 +40,7 @@ QVariant OptionsModel::data(const QModelIndex & index, int role) const
@@ -40,7 +40,7 @@ QVariant OptionsModel::data(const QModelIndex & index, int role) const
|
|
|
|
|
case ProxyIP: |
|
|
|
|
return QVariant(QString::fromStdString(addrProxy.ToStringIP())); |
|
|
|
|
case ProxyPort: |
|
|
|
|
return QVariant(QString::fromStdString(addrProxy.ToStringPort())); |
|
|
|
|
return QVariant(addrProxy.GetPort()); |
|
|
|
|
case Fee: |
|
|
|
|
return QVariant(nTransactionFee); |
|
|
|
|
case DisplayUnit: |
|
|
|
@ -87,7 +87,7 @@ bool OptionsModel::setData(const QModelIndex & index, const QVariant & value, in
@@ -87,7 +87,7 @@ bool OptionsModel::setData(const QModelIndex & index, const QVariant & value, in
|
|
|
|
|
case ProxyIP: |
|
|
|
|
{ |
|
|
|
|
// Use CAddress to parse and check IP
|
|
|
|
|
CAddress addr(value.toString().toStdString() + ":1"); |
|
|
|
|
CNetAddr addr(value.toString().toStdString()); |
|
|
|
|
if (addr.IsValid()) |
|
|
|
|
{ |
|
|
|
|
addrProxy.SetIP(addr); |
|
|
|
|