Fixed popups getting blocked by modal windows.

In the case of a file dialog with a completer, the completion list view
is a popup that is not a transient child of the file dialog. Thus it
ends up getting its blockedByModal flag set due to the file dialog
window being a modal window.

To prevent this we make sure popups don't get blocked by modal windows,
as they were special cased and processed before modal windows in Qt 4.x.

Change-Id: Id5688cfb1534541cd1678b1e53d75e34a68f9b8e
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
bb10
Samuel Rødal 2012-08-02 15:18:57 +02:00 committed by Qt by Nokia
parent 35215a0f5f
commit e033d59c94
1 changed files with 1 additions and 1 deletions

View File

@ -432,7 +432,7 @@ QWindow *QGuiApplication::modalWindow()
void QGuiApplicationPrivate::updateBlockedStatus(QWindow *window)
{
bool shouldBeBlocked = false;
if (window->windowType() != Qt::Tool && !self->modalWindowList.isEmpty())
if ((window->windowType() & Qt::Popup) != Qt::Popup && !self->modalWindowList.isEmpty())
shouldBeBlocked = self->isWindowBlocked(window);
if (shouldBeBlocked != window->d_func()->blockedByModalWindow) {