Add save request to string props
MODIFY
WalletWasabi.Fluent/ViewModels/Settings/BitcoinTabViewModel.cs
WalletWasabi.Fluent/ViewModels/Settings/BitcoinTabViewModel.cs
@@ -6,7 +6,6 @@ using NBitcoin;
using ReactiveUI;
using WalletWasabi.Gui;
using WalletWasabi.Gui.Validation;
-using WalletWasabi.Gui.ViewModels;
using WalletWasabi.Helpers;
using WalletWasabi.Models;
using WalletWasabi.Userfacing;
@@ -26,15 +25,17 @@ namespace WalletWasabi.Fluent.ViewModels.Settings
this.ValidateProperty(x => x.BitcoinP2PEndPoint, ValidateBitcoinP2PEndPoint);
_network = config.Network;
- StartLocalBitcoinCoreOnStartup = config.StartLocalBitcoinCoreOnStartup;
+ _startLocalBitcoinCoreOnStartup = config.StartLocalBitcoinCoreOnStartup;
_localBitcoinCoreDataDir = config.LocalBitcoinCoreDataDir;
- StopLocalBitcoinCoreOnShutdown = config.StopLocalBitcoinCoreOnShutdown;
+ _stopLocalBitcoinCoreOnShutdown = config.StopLocalBitcoinCoreOnShutdown;
_bitcoinP2PEndPoint = config.GetP2PEndpoint().ToString(defaultPort: -1);
this.WhenAnyValue(
x => x.Network,
x => x.StartLocalBitcoinCoreOnStartup,
- x => x.StopLocalBitcoinCoreOnShutdown)
+ x => x.StopLocalBitcoinCoreOnShutdown,
+ x => x.BitcoinP2PEndPoint,
+ x => x.LocalBitcoinCoreDataDir)
.ObserveOn(RxApp.TaskpoolScheduler)
.Subscribe(_ => RequestSave());
}

MODIFY
WalletWasabi.Fluent/ViewModels/Settings/GeneralTabViewModel.cs
WalletWasabi.Fluent/ViewModels/Settings/GeneralTabViewModel.cs
@@ -28,14 +28,18 @@ namespace WalletWasabi.Fluent.ViewModels.Settings
this.ValidateProperty(x => x.DustThreshold, ValidateDustThreshold);
_darkModeEnabled = true; // TODO: Get from config file.
- Autocopy = global.UiConfig.Autocopy;
- CustomFee = global.UiConfig.IsCustomFee;
- CustomChangeAddress = global.UiConfig.IsCustomChangeAddress;
- SelectedFeeDisplayFormat = Enum.IsDefined(typeof(FeeDisplayFormat), global.UiConfig.FeeDisplayFormat)
+ _autocopy = global.UiConfig.Autocopy;
+ _customFee = global.UiConfig.IsCustomFee;
+ _customChangeAddress = global.UiConfig.IsCustomChangeAddress;
+ _selectedFeeDisplayFormat = Enum.IsDefined(typeof(FeeDisplayFormat), global.UiConfig.FeeDisplayFormat)
? (FeeDisplayFormat)global.UiConfig.FeeDisplayFormat
: FeeDisplayFormat.SatoshiPerByte;
_dustThreshold = config.DustThreshold.ToString();
+ this.WhenAnyValue(x => x.DustThreshold)
+ .ObserveOn(RxApp.TaskpoolScheduler)
+ .Subscribe(_ => RequestSave());
+
this.WhenAnyValue(x => x.DarkModeEnabled)
.Skip(1)
.Subscribe(

MODIFY
WalletWasabi.Fluent/ViewModels/Settings/NetworkTabViewModel.cs
WalletWasabi.Fluent/ViewModels/Settings/NetworkTabViewModel.cs
@@ -20,13 +20,14 @@ namespace WalletWasabi.Fluent.ViewModels.Settings
{
this.ValidateProperty(x => x.TorSocks5EndPoint, ValidateTorSocks5EndPoint);
- UseTor = config.UseTor;
- TerminateTorOnExit = config.TerminateTorOnExit;
+ _useTor = config.UseTor;
+ _terminateTorOnExit = config.TerminateTorOnExit;
_torSocks5EndPoint = config.TorSocks5EndPoint.ToString(-1);
this.WhenAnyValue(
x => x.UseTor,
- x => x.TerminateTorOnExit)
+ x => x.UseTor,
+ x => x.TorSocks5EndPoint)
.ObserveOn(RxApp.TaskpoolScheduler)
.Subscribe(_ => RequestSave());
}

Add save request to string props