Skip to content

feat(systray): toggle activities window on tray icon middle click - #11183

Open
v3DJG6GL wants to merge 1 commit into
nextcloud:masterfrom
v3DJG6GL:feat/middle-click-activities
Open

v3DJG6GL wants to merge 1 commit into
nextcloud:masterfrom
v3DJG6GL:feat/middle-click-activities

Conversation

@v3DJG6GL

@v3DJG6GL v3DJG6GL commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

Summary

This PR adds the option to open the Activities Window with just one mouse click instead of several clicks:

A middle click on the tray icon (StatusNotifierItem SecondaryActivate on Linux, mapped by Qt to QSystemTrayIcon::MiddleClick) opens the Activities Window now directly. A middle click on the tray icon while the window is open hides it again. A minimized window is handled as not shown, a middle click therefore shows the window again.
Other mouse actions are left unchanged.

This would likely be a sufficient compromise for users who were quite unhappy with the removal of the flyout/activity list.

While I also preferred the flyout Nextcloud Desktop had before the v34 release, I think this is a reasonable compromise. Maybe somewhere in the future might be a more UX-friendly implementation added to the codebase... :)

LoC Changes

Type Code Comments Blank Total
Production 20 1 3 24
Tests 110 8 23 141
Total 130 9 26 165

I can ofc remove some tests if you think that's too much for such a small feature...

Resolves (partially)

Some reports I've found which would be partially resolved by this PR:
#10475
#10515
#10688

Summary

TODO

  • Unit tests for the click mapping (TrayActivationPolicyTest) and the show/hide toggle (SystrayActivitiesWindowTest)
  • CI tests pass
  • Manual test on Linux (Kubuntu v26.04/KDE Plasma)
  • Manual test on Windows
  • Manual test on macOS (<-- I don't have apple devices and therefore cannot test this plattform!)
  • GNOME (+AppIndicator extension)

Checklist

AI (if applicable)

LLM Disclosure

Developed with assistance from Claude Code (Opus 5.5). The LLM helped me identify the related files, code parts and proposed possible code modifications and fixes.
I've reviewed, cleaned, refactored and hardened the code the best I could.

The activities window is otherwise only reachable through several
clicks in the tray popup. Middle click on the tray icon (delivered as
StatusNotifierItem SecondaryActivate on Linux, mapped by Qt to
QSystemTrayIcon::MiddleClick) now opens it directly, and hides it again
if an activities window is already shown. A minimized window counts as
not shown, so middle click brings it back instead.

Left click (primary popup), double click (open local folder) and the
right-click context menu are unchanged.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Assisted-by: ClaudeCode:claude-fable-5
Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: v3DJG6GL <72495210+v3DJG6GL@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant