mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-06-07 01:08:18 +08:00
[FancyZones] Fix stuck chrome tab when merging into existing window (#6931)
* Fix stuck Chrome tab when merging with existing window * Rename struct fields
This commit is contained in:
parent
8f81b9c662
commit
85f56f4ed8
@ -67,8 +67,8 @@ void WindowMoveHandler::MoveSizeStart(HWND window, HMONITOR monitor, POINT const
|
||||
return;
|
||||
}
|
||||
|
||||
m_moveSizeWindowInfo.noVisibleOwner = FancyZonesUtils::HasNoVisibleOwner(window);
|
||||
m_moveSizeWindowInfo.standardWindow = FancyZonesUtils::IsStandardWindow(window);
|
||||
m_moveSizeWindowInfo.hasNoVisibleOwner = FancyZonesUtils::HasNoVisibleOwner(window);
|
||||
m_moveSizeWindowInfo.isStandardWindow = FancyZonesUtils::IsStandardWindow(window);
|
||||
m_inMoveSize = true;
|
||||
|
||||
auto iter = zoneWindowMap.find(monitor);
|
||||
@ -209,11 +209,11 @@ void WindowMoveHandler::MoveSizeEnd(HWND window, POINT const& ptScreen, const st
|
||||
auto zoneWindow = std::move(m_zoneWindowMoveSize);
|
||||
ResetWindowTransparency();
|
||||
|
||||
bool hasNoVisibleOwnoer = FancyZonesUtils::HasNoVisibleOwner(window);
|
||||
bool hasNoVisibleOwner = FancyZonesUtils::HasNoVisibleOwner(window);
|
||||
bool isStandardWindow = FancyZonesUtils::IsStandardWindow(window);
|
||||
|
||||
if ((isStandardWindow == false && hasNoVisibleOwnoer == false &&
|
||||
m_moveSizeWindowInfo.standardWindow == true && m_moveSizeWindowInfo.noVisibleOwner == true) ||
|
||||
if ((isStandardWindow == false && hasNoVisibleOwner == true &&
|
||||
m_moveSizeWindowInfo.isStandardWindow == true && m_moveSizeWindowInfo.hasNoVisibleOwner == true) ||
|
||||
FancyZonesUtils::IsWindowMaximized(window))
|
||||
{
|
||||
// Abort the zoning, this is a Chromium based tab that is merged back with an existing window
|
||||
|
@ -52,9 +52,9 @@ private:
|
||||
struct MoveSizeWindowInfo
|
||||
{
|
||||
// True if from the styles the window looks like a standard window
|
||||
bool standardWindow = false;
|
||||
bool isStandardWindow = false;
|
||||
// True if the window is a top-level window that does not have a visible owner
|
||||
bool noVisibleOwner = false;
|
||||
bool hasNoVisibleOwner = false;
|
||||
};
|
||||
|
||||
void WarnIfElevationIsRequired(HWND window) noexcept;
|
||||
|
Loading…
Reference in New Issue
Block a user