[FancyZones] Fix crashing on win + arrows usage (#23757)

This commit is contained in:
Seraphima Zykova 2023-02-02 19:25:04 +03:00 committed by GitHub
parent f38c838050
commit b09ce1bb57
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -896,7 +896,7 @@ bool FancyZones::OnSnapHotkeyBasedOnPosition(HWND window, DWORD vkCode) noexcept
// If that didn't work, extract zones from all other monitors and target one of them // If that didn't work, extract zones from all other monitors and target one of them
std::vector<RECT> zoneRects; std::vector<RECT> zoneRects;
std::vector<std::pair<ZoneIndex, std::shared_ptr<WorkArea>>> zoneRectsInfo; std::vector<std::pair<ZoneIndex, WorkArea*>> zoneRectsInfo;
RECT currentMonitorRect{ .top = 0, .bottom = -1 }; RECT currentMonitorRect{ .top = 0, .bottom = -1 };
for (const auto& [monitor, monitorRect] : allMonitors) for (const auto& [monitor, monitorRect] : allMonitors)