Qt use platform-independent visibility functions

show() isn't just some conveniently renamed setVisible(true), but
presents a window in a platform-dependant way, which - at least
for WASM - means maximized and without a title bar. This is not
really expected and WASM can also use multiple windows.

Change-Id: I3fbaec1dfc2cd32bf3a90a94dcee01ebc88e58c7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128179
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
This commit is contained in:
Jan-Marek Glogowski
2022-01-09 01:01:49 +01:00
parent b6feea0a84
commit f7346dc882

View File

@@ -460,7 +460,7 @@ void QtFrame::Show(bool bVisible, bool bNoActivate)
if (!bVisible) // hide
{
pSalInst->RunInMainThread([this]() {
asChild()->hide();
asChild()->setVisible(false);
if (m_pQWidget->isModal())
modalReparent(false);
});
@@ -474,7 +474,7 @@ void QtFrame::Show(bool bVisible, bool bNoActivate)
QWidget* const pChild = asChild();
if (m_pQWidget->isModal())
modalReparent(true);
pChild->show();
pChild->setVisible(true);
pChild->raise();
if (!bNoActivate && !isPopup())
{