summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorMichael Weghorn <m.weghorn@posteo.de>2023-03-01 10:54:13 +0100
committerMichael Weghorn <m.weghorn@posteo.de>2023-03-01 13:24:21 +0000
commit00a602ca8e75ab5cf050e092289ef7165b343165 (patch)
tree0c8955d11081d2272154a83ebe8af547a07e39e4 /vcl
parent4def1399b17792e14882152c58b7f1f8d46aedfd (diff)
tdf#153869 qt: Unminimize window when requested
Remove the `Qt::WindowMinimized` state from the widget's window states if the `SalFrameToTop::RestoreWhenMin` flag is set to request restoring the minimized window. Change-Id: I0cb67f28c1e9c3f48a9a234702a4aaa7e3ffec8d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148036 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/qt5/QtFrame.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/vcl/qt5/QtFrame.cxx b/vcl/qt5/QtFrame.cxx
index 1b9f8ae88175..554485a6b83c 100644
--- a/vcl/qt5/QtFrame.cxx
+++ b/vcl/qt5/QtFrame.cxx
@@ -768,7 +768,11 @@ void QtFrame::ToTop(SalFrameToTop nFlags)
if (isWindow() && !(nFlags & SalFrameToTop::GrabFocusOnly))
pWidget->raise();
if ((nFlags & SalFrameToTop::RestoreWhenMin) || (nFlags & SalFrameToTop::ForegroundTask))
+ {
+ if (nFlags & SalFrameToTop::RestoreWhenMin)
+ pWidget->setWindowState(pWidget->windowState() & ~Qt::WindowMinimized);
pWidget->activateWindow();
+ }
else if ((nFlags & SalFrameToTop::GrabFocus) || (nFlags & SalFrameToTop::GrabFocusOnly))
{
if (!(nFlags & SalFrameToTop::GrabFocusOnly))