|
|
@ -142,8 +142,10 @@ QVariant OptionsModel::data(const QModelIndex & index, int role) const |
|
|
|
return settings.value("fUseUPnP", GetBoolArg("-upnp", true)); |
|
|
|
return settings.value("fUseUPnP", GetBoolArg("-upnp", true)); |
|
|
|
case MinimizeOnClose: |
|
|
|
case MinimizeOnClose: |
|
|
|
return QVariant(fMinimizeOnClose); |
|
|
|
return QVariant(fMinimizeOnClose); |
|
|
|
case ProxyUse: |
|
|
|
case ProxyUse: { |
|
|
|
return settings.value("fUseProxy", false); |
|
|
|
proxyType proxy; |
|
|
|
|
|
|
|
return QVariant(GetProxy(NET_IPV4, proxy)); |
|
|
|
|
|
|
|
} |
|
|
|
case ProxyIP: { |
|
|
|
case ProxyIP: { |
|
|
|
proxyType proxy; |
|
|
|
proxyType proxy; |
|
|
|
if (GetProxy(NET_IPV4, proxy)) |
|
|
|
if (GetProxy(NET_IPV4, proxy)) |
|
|
@ -158,8 +160,13 @@ QVariant OptionsModel::data(const QModelIndex & index, int role) const |
|
|
|
else |
|
|
|
else |
|
|
|
return QVariant(9050); |
|
|
|
return QVariant(9050); |
|
|
|
} |
|
|
|
} |
|
|
|
case ProxySocksVersion: |
|
|
|
case ProxySocksVersion: { |
|
|
|
return settings.value("nSocksVersion", 5); |
|
|
|
proxyType proxy; |
|
|
|
|
|
|
|
if (GetProxy(NET_IPV4, proxy)) |
|
|
|
|
|
|
|
return QVariant(proxy.second); |
|
|
|
|
|
|
|
else |
|
|
|
|
|
|
|
return QVariant(5); |
|
|
|
|
|
|
|
} |
|
|
|
case Fee: |
|
|
|
case Fee: |
|
|
|
return QVariant(nTransactionFee); |
|
|
|
return QVariant(nTransactionFee); |
|
|
|
case DisplayUnit: |
|
|
|
case DisplayUnit: |
|
|
@ -203,7 +210,7 @@ bool OptionsModel::setData(const QModelIndex & index, const QVariant & value, in |
|
|
|
break; |
|
|
|
break; |
|
|
|
case ProxyUse: |
|
|
|
case ProxyUse: |
|
|
|
settings.setValue("fUseProxy", value.toBool()); |
|
|
|
settings.setValue("fUseProxy", value.toBool()); |
|
|
|
ApplyProxySettings(); |
|
|
|
successful = ApplyProxySettings(); |
|
|
|
break; |
|
|
|
break; |
|
|
|
case ProxyIP: { |
|
|
|
case ProxyIP: { |
|
|
|
proxyType proxy; |
|
|
|
proxyType proxy; |
|
|
|