Also show the window on right click

Note this won't work on all platforms. KDE Plasma and GNOME Shell (with
systray extension) assume that right click is necessarily for a context
menu exposed via D-Bus, there's not nice way to make the right click
popup the main dialog on those platforms.

Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
This commit is contained in:
Kevin Ottens 2020-06-16 18:32:53 +02:00 committed by Kevin Ottens (Rebase PR Action)
parent afac668d9c
commit a6873f556b

View file

@ -156,9 +156,7 @@ void ownCloudGui::slotOpenSettingsDialog()
void ownCloudGui::slotTrayClicked(QSystemTrayIcon::ActivationReason reason) void ownCloudGui::slotTrayClicked(QSystemTrayIcon::ActivationReason reason)
{ {
if (reason == QSystemTrayIcon::Trigger || reason == QSystemTrayIcon::Context) {
// Left click
if (reason == QSystemTrayIcon::Trigger) {
if (OwncloudSetupWizard::bringWizardToFrontIfVisible()) { if (OwncloudSetupWizard::bringWizardToFrontIfVisible()) {
// brought wizard to front // brought wizard to front
} else if (_shareDialogs.size() > 0) { } else if (_shareDialogs.size() > 0) {