1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

Fix some systray issues on windows

Fix qTox not hiding when clicking on systray icon due to losing focus when clicking on the system tray

Fix the icon not being properly hidden on exit

Thanks to @toweI for reporting those issues
This commit is contained in:
Tux3 / Mlkj / !Lev.uXFMLA 2015-01-30 00:40:20 +01:00 committed by Dubslow
parent c32eb98e6c
commit 7574569b3d
No known key found for this signature in database
GPG Key ID: 3DB8E05315C220AA

View File

@ -319,6 +319,7 @@ Widget::~Widget()
core->saveConfiguration(); core->saveConfiguration();
AutoUpdater::abortUpdates(); AutoUpdater::abortUpdates();
delete core; delete core;
icon->hide();
hideMainForms(); hideMainForms();
delete settingsWidget; delete settingsWidget;
delete addFriendForm; delete addFriendForm;
@ -609,10 +610,14 @@ void Widget::onIconClick(QSystemTrayIcon::ActivationReason reason)
show(); show();
activateWindow(); activateWindow();
} }
else if (isMinimized() || !isActiveWindow()) else if (isMinimized())
{
forceShow(); forceShow();
}
else else
{
hide(); hide();
}
break; break;
} }