mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-19 06:57:24 -06:00
Fix window hiding issue (closes #589070)
This commit is contained in:
@@ -580,6 +580,7 @@ bool GUI::event(QEvent * e) {
|
||||
qDebug("minimisation");
|
||||
QSettings settings(QString::fromUtf8("qBittorrent"), QString::fromUtf8("qBittorrent"));
|
||||
if(systrayIcon && settings.value(QString::fromUtf8("Preferences/General/MinimizeToTray"), false).toBool()) {
|
||||
if(!qApp->activeWindow() || !qApp->activeWindow()->isModal()) {
|
||||
qDebug("Minimize to Tray enabled, hiding!");
|
||||
e->accept();
|
||||
QTimer::singleShot(0, this, SLOT(hide()));
|
||||
@@ -587,6 +588,7 @@ bool GUI::event(QEvent * e) {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return QMainWindow::event(e);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user