Handle windows Z order of the ui::Manager regardless of whether multiple windows are on/off

In this way we keep the internal Z order of windows correctly in both
cases to deliver mouse messages.
This commit is contained in:
David Capello 2021-05-10 16:14:23 -03:00
parent 05b89eb83b
commit 0059739a24

View File

@ -705,8 +705,6 @@ void Manager::handleWindowZOrder()
if ((window) &&
// We cannot change Z-order of desktop windows
(!window->isDesktop()) &&
// We cannot change window order of native windows (they are handled by the OS)
(!window->ownDisplay()) &&
// We cannot change Z order of foreground windows because a
// foreground window can launch other background windows
// which should be kept on top of the foreground one.
@ -736,7 +734,8 @@ void Manager::handleWindowZOrder()
win_manager->insertChild(pos, window);
}
window->invalidate();
if (!window->ownDisplay())
window->invalidate();
}
// Put the focus