[FancyZones] Enable to manually zone child windows (#6182)

* Enable to manually zone child windows

* Refactor IsInterestingWindow in 2 separate functions

* Remove enum
This commit is contained in:
stefansjfw
2020-08-28 15:00:21 +02:00
committed by GitHub
parent d51640c2f0
commit 0a603449ad
5 changed files with 86 additions and 56 deletions

View File

@@ -307,7 +307,11 @@ IFACEMETHODIMP ZoneWindow::MoveSizeEnd(HWND window, POINT const& ptScreen) noexc
MapWindowPoints(nullptr, m_window.get(), &ptClient, 1);
m_activeZoneSet->MoveWindowIntoZoneByIndexSet(window, m_window.get(), m_highlightZone);
SaveWindowProcessToZoneIndex(window);
auto windowInfo = FancyZonesUtils::GetFancyZonesWindowInfo(window);
if (windowInfo.noVisibleOwner)
{
SaveWindowProcessToZoneIndex(window);
}
}
Trace::ZoneWindow::MoveSizeEnd(m_activeZoneSet);
@@ -338,7 +342,11 @@ ZoneWindow::MoveWindowIntoZoneByDirectionAndIndex(HWND window, DWORD vkCode, boo
{
if (m_activeZoneSet->MoveWindowIntoZoneByDirectionAndIndex(window, m_window.get(), vkCode, cycle))
{
SaveWindowProcessToZoneIndex(window);
auto windowInfo = FancyZonesUtils::GetFancyZonesWindowInfo(window);
if (windowInfo.noVisibleOwner)
{
SaveWindowProcessToZoneIndex(window);
}
return true;
}
}