[FancyZones] Open window on active monitor (#4361)

* Initial design for opening window on active monitor

* Perform entire handling in DPI unaware thread

* Codestyle improvement

* Improve resizing mechanism and optimise code a bit

* Remove unneeded code, make simple helper functions inline

* Make this feature configurable

* Code optimization, improve positioning for some applications

* Retry positioning for certain applications

* Improve readability

* Address PR comments: Minor code style improvements

* Remove retries in custom positioning

* Position new toggle in settings menu
This commit is contained in:
vldmr11080
2020-07-08 10:37:42 +02:00
committed by GitHub
parent 94f66b812a
commit db229cf1bf
12 changed files with 170 additions and 19 deletions

View File

@@ -17,6 +17,7 @@ namespace Microsoft.PowerToys.Settings.UI.Lib
this.FancyzonesDisplayChangeMoveWindows = new BoolProperty();
this.FancyzonesZoneSetChangeMoveWindows = new BoolProperty();
this.FancyzonesAppLastZoneMoveWindows = new BoolProperty();
this.FancyzonesOpenWindowOnActiveMonitor = new BoolProperty();
this.FancyzonesRestoreSize = new BoolProperty();
this.UseCursorposEditorStartupscreen = new BoolProperty(ConfigDefaults.DefaultUseCursorposEditorStartupscreen);
this.FancyzonesShowOnAllMonitors = new BoolProperty();
@@ -59,6 +60,9 @@ namespace Microsoft.PowerToys.Settings.UI.Lib
[JsonPropertyName("fancyzones_appLastZone_moveWindows")]
public BoolProperty FancyzonesAppLastZoneMoveWindows { get; set; }
[JsonPropertyName("fancyzones_openWindowOnActiveMonitor")]
public BoolProperty FancyzonesOpenWindowOnActiveMonitor { get; set; }
[JsonPropertyName("fancyzones_restoreSize")]
public BoolProperty FancyzonesRestoreSize { get; set; }