File tree Expand file tree Collapse file tree 1 file changed +18
-6
lines changed Expand file tree Collapse file tree 1 file changed +18
-6
lines changed Original file line number Diff line number Diff line change @@ -363,18 +363,30 @@ public double Left
363
363
[ RelayCommand ]
364
364
private void IncreaseWidth ( )
365
365
{
366
- if ( _settings . WindowSize > 1920 ) return ;
367
- _settings . WindowSize += 100 ;
368
- Left -= 50 ;
366
+ if ( MainWindowWidth + 100 > 1920 || _settings . WindowSize == 1920 )
367
+ {
368
+ _settings . WindowSize = 1920 ;
369
+ }
370
+ else
371
+ {
372
+ _settings . WindowSize += 100 ;
373
+ Left -= 50 ;
374
+ }
369
375
OnPropertyChanged ( ) ;
370
376
}
371
377
372
378
[ RelayCommand ]
373
379
private void DecreaseWidth ( )
374
380
{
375
- if ( _settings . WindowSize < 400 ) return ;
376
- Left += 50 ;
377
- _settings . WindowSize -= 100 ;
381
+ if ( MainWindowWidth - 100 < 400 || _settings . WindowSize == 400 )
382
+ {
383
+ _settings . WindowSize = 400 ;
384
+ }
385
+ else
386
+ {
387
+ Left += 50 ;
388
+ _settings . WindowSize -= 100 ;
389
+ }
378
390
OnPropertyChanged ( ) ;
379
391
}
380
392
You can’t perform that action at this time.
0 commit comments