mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-05 02:36:19 +02:00
[FancyZones] Window switch shortcut fix (#21426)
* rename Layout -> LayoutData * simplify zone * split ZoneSet: Layout * refactoring * split ZoneSet: LayoutWindows * update trace * split ZoneSet: remove ZoneSet * fix initialization * split unit tests * remove unused * warning * nullptr check * use current rect * update work area tests * use current rect * simplify * more meaningful name * dismiss * safety checks * resolve conflicts * reassign windows after switching vd * avoid double-processing for window on switching vd * extend windows fix * check if window is on current desktop before cycling * separated extend * not reinit layout windows
This commit is contained in:
@@ -418,7 +418,7 @@ namespace FancyZonesUnitTests
|
||||
};
|
||||
|
||||
// test
|
||||
Layout expectedLayout {
|
||||
LayoutData expectedLayout {
|
||||
.uuid = FancyZonesUtils::GuidFromString(L"{33A2B101-06E0-437B-A61E-CDBECF502906}").value(),
|
||||
.type = FancyZonesDataTypes::ZoneSetLayoutType::Focus,
|
||||
.showSpacing = true,
|
||||
@@ -470,7 +470,7 @@ namespace FancyZonesUnitTests
|
||||
AppliedLayouts::instance().LoadData();
|
||||
|
||||
// test
|
||||
Layout expectedLayout{
|
||||
LayoutData expectedLayout{
|
||||
.uuid = FancyZonesUtils::GuidFromString(L"{33A2B101-06E0-437B-A61E-CDBECF502906}").value(),
|
||||
.type = FancyZonesDataTypes::ZoneSetLayoutType::Focus,
|
||||
.showSpacing = true,
|
||||
@@ -530,7 +530,7 @@ namespace FancyZonesUnitTests
|
||||
.monitorId = { .deviceId = { .id = L"device", .instanceId = L"instance-id" }, .serialNumber = L"serial-number" },
|
||||
.virtualDesktopId = FancyZonesUtils::GuidFromString(L"{E21F6F29-76FD-4FC1-8970-17AB8AD64847}").value()
|
||||
};
|
||||
AppliedLayouts::instance().ApplyLayout(id, Layout{});
|
||||
AppliedLayouts::instance().ApplyLayout(id, LayoutData{});
|
||||
|
||||
// test
|
||||
Assert::IsTrue(AppliedLayouts::instance().IsLayoutApplied(id));
|
||||
@@ -543,7 +543,7 @@ namespace FancyZonesUnitTests
|
||||
.monitorId = { .deviceId = { .id = L"device-1", .instanceId = L"instance-id-1" }, .serialNumber = L"serial-number-1" },
|
||||
.virtualDesktopId = FancyZonesUtils::GuidFromString(L"{E21F6F29-76FD-4FC1-8970-17AB8AD64847}").value()
|
||||
};
|
||||
AppliedLayouts::instance().ApplyLayout(id1, Layout{});
|
||||
AppliedLayouts::instance().ApplyLayout(id1, LayoutData{});
|
||||
|
||||
// test
|
||||
FancyZonesDataTypes::WorkAreaId id2{
|
||||
|
||||
Reference in New Issue
Block a user