Revert "Cocoa plugin - showMaximized/showMinimized and Qt::FramelessWindowHint"
This reverts commit d024f0a922.
Qt::FramelessWindowHint actually DO require 'non-resizable' window.
Let's assume, non-resizable means 'resize by mouse dragging'.
There is a better fix that will follow this patch (temporary
setting/resetting resizable mask).
Change-Id: I61cefcade437d3e54719e2e1ff0e8d070c577df0
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
parent
f25d6ad2aa
commit
9f34943245
|
|
@ -787,7 +787,7 @@ NSUInteger QCocoaWindow::windowStyleMask(Qt::WindowFlags flags)
|
|||
Qt::WindowType type = static_cast<Qt::WindowType>(int(flags & Qt::WindowType_Mask));
|
||||
NSInteger styleMask = NSBorderlessWindowMask;
|
||||
if (flags & Qt::FramelessWindowHint)
|
||||
return styleMask | NSResizableWindowMask;
|
||||
return styleMask;
|
||||
if ((type & Qt::Popup) == Qt::Popup) {
|
||||
if (!windowIsPopupType(type))
|
||||
styleMask = (NSUtilityWindowMask | NSResizableWindowMask | NSClosableWindowMask |
|
||||
|
|
@ -1491,10 +1491,7 @@ void QCocoaWindow::syncWindowState(Qt::WindowState newState)
|
|||
|
||||
if ((m_synchedWindowState & Qt::WindowMinimized) != (newState & Qt::WindowMinimized)) {
|
||||
if (newState & Qt::WindowMinimized) {
|
||||
if (m_nsWindow.styleMask & NSMiniaturizableWindowMask)
|
||||
[m_nsWindow performMiniaturize : m_nsWindow];
|
||||
else
|
||||
[m_nsWindow miniaturize : m_nsWindow];
|
||||
[m_nsWindow performMiniaturize : m_nsWindow];
|
||||
} else {
|
||||
[m_nsWindow deminiaturize : m_nsWindow];
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue