macOS: Allow maximizing utility windows
They have a native maximize/zoom button in their titlebar, so there's no reason for us to prevent the same action via the API. The only states that are prevented are minimized and fullscreen. Change-Id: I84fa48b31b243fa838c90ecdeee92a2f3448ee14 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
This commit is contained in:
parent
b619a9eada
commit
01d5aaa0f6
@ -1302,9 +1302,9 @@ void QCocoaWindow::applyWindowState(Qt::WindowStates requestedState)
|
|||||||
|
|
||||||
const NSWindow *nsWindow = m_view.window;
|
const NSWindow *nsWindow = m_view.window;
|
||||||
|
|
||||||
if (nsWindow.styleMask & NSUtilityWindowMask) {
|
if (nsWindow.styleMask & NSUtilityWindowMask
|
||||||
// Utility panels cannot be fullscreen
|
&& newState & (Qt::WindowMinimized | Qt::WindowFullScreen)) {
|
||||||
qWarning() << window()->type() << "windows can not be made full screen";
|
qWarning() << window()->type() << "windows can not be made" << newState;
|
||||||
reportCurrentWindowState(true);
|
reportCurrentWindowState(true);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user