@@ -35,9 +35,11 @@ public SettingWindowViewModel(Updater updater, IPortable portable)
3535 Settings = _storage . Load ( ) ;
3636 Settings . PropertyChanged += ( s , e ) =>
3737 {
38- if ( e . PropertyName == nameof ( Settings . ActivateTimes ) )
38+ switch ( e . PropertyName )
3939 {
40- OnPropertyChanged ( nameof ( ActivatedTimes ) ) ;
40+ case nameof ( Settings . ActivateTimes ) :
41+ OnPropertyChanged ( nameof ( ActivatedTimes ) ) ;
42+ break ;
4143 }
4244 } ;
4345 }
@@ -51,7 +53,7 @@ public async void UpdateApp()
5153
5254 public bool AutoUpdates
5355 {
54- get { return Settings . AutoUpdates ; }
56+ get => Settings . AutoUpdates ;
5557 set
5658 {
5759 Settings . AutoUpdates = value ;
@@ -71,7 +73,7 @@ public bool AutoHideScrollBar
7173 private bool _portableMode = DataLocation . PortableDataLocationInUse ( ) ;
7274 public bool PortableMode
7375 {
74- get { return _portableMode ; }
76+ get => _portableMode ;
7577 set
7678 {
7779 if ( ! _portable . CanUpdatePortability ( ) )
@@ -306,18 +308,14 @@ public bool DropShadowEffect
306308
307309 public double WindowWidthSize
308310 {
309- get { return Settings . WindowSize ; }
310- set
311- {
312- Settings . WindowSize = value ;
313- ThemeManager . Instance . ChangeTheme ( Settings . Theme ) ;
314- }
311+ get => Settings . WindowSize ;
312+ set => Settings . WindowSize = value ;
315313 }
316314
317315 public bool UseGlyphIcons
318316 {
319- get { return Settings . UseGlyphIcons ; }
320- set { Settings . UseGlyphIcons = value ; }
317+ get => Settings . UseGlyphIcons ;
318+ set => Settings . UseGlyphIcons = value ;
321319 }
322320
323321 public Brush PreviewBackground
0 commit comments