1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2024-11-28 13:41:16 +01:00

Made the popup disappear logic work on Windows

This commit is contained in:
Martin Tůma 2019-10-16 22:58:22 +02:00
parent 0c1a123cd9
commit 5f79326601

View File

@ -98,10 +98,18 @@ bool Label::eventFilter(QObject *o, QEvent *ev)
} }
break; break;
} }
#ifdef Q_OS_WIN32
case QEvent::FocusOut:
case QEvent::WindowDeactivate:
if (o == this)
deleteLater();
break;
#else // Q_OS_WIN32
case QEvent::FocusIn: case QEvent::FocusIn:
case QEvent::FocusOut: case QEvent::FocusOut:
case QEvent::WindowActivate: case QEvent::WindowActivate:
case QEvent::WindowDeactivate: case QEvent::WindowDeactivate:
#endif // Q_OS_WIN32
case QEvent::Close: case QEvent::Close:
deleteLater(); deleteLater();
break; break;