Windows QPA: Accept foreign windows when checking for wheel receivers
After changebb1014efcaa392, foreign windows no longer have a corresponding QWindowsWindow. This should not block wheel events when checking for blocking modal windows. Amends change14efcaa392. Task-number: QTBUG-54430 Change-Id: I1ac87445844946bafc214024e27da08c4f884d79 Reviewed-by: Tim Blechmann <tim@klingt.org> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
parent
5dc739ba9b
commit
145d8462e3
|
|
@ -393,6 +393,8 @@ static bool isValidWheelReceiver(QWindow *candidate)
|
|||
{
|
||||
if (candidate) {
|
||||
const QWindow *toplevel = QWindowsWindow::topLevelOf(candidate);
|
||||
if (toplevel->type() == Qt::ForeignWindow)
|
||||
return true;
|
||||
if (const QWindowsWindow *ww = QWindowsWindow::windowsWindowOf(toplevel))
|
||||
return !ww->testFlag(QWindowsWindow::BlockedByModal);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue