desktop
desktop copied to clipboard
Left mouse click on tray icon on Linux shows context menu instead of showing the window
I confirm (by marking "x" in the [ ] below: [x]):
- [x] This is not a troubleshooting question. Troubleshooting questions go here: http://www.mattermost.org/troubleshoot/.
- [x] This doesn't reproduce on web browsers (such as in Chrome). If it does, issue reports go to the Mattermost Server repository.
- [x] I have read contributing guidelines.
Summary In Mattermost Desktop 4.1.2 and previous versions left mouse click on the tray icon showed a main window, and starting from version 4.2.0 left and right mouse clicks have the same behavior and shows context menu, which is inconvenient in case I have to make two clicks now instead of one to open the window. Furthermore, when I had a message and clicked on the tray icon, it showed the main window and opened a dialog with a new message.
Environment
- Operating System: Linux (4.12.14-lp150.12.48-default x64) openSUSE Leap 15.1 with KDE 5.12.5
- Mattermost Desktop App version: 4.2.0
- Mattermost Server version: 5.8.0
Steps to reproduce
- Run application with "Show icon in the notification area" and "Leave app running in notification area when application window is closed" setting on KDE.
- Close a main window
- Left mouse click on the tray icon.
Expected behavior Left mouse click on tray icon should show the main windows with opened dialog where new massage is arrived.
Observed behavior Left mouse click shows context menu as well as right mouse click on the tray icon.
Ticket for tracking: https://mattermost.atlassian.net/browse/MM-14674
I experience it too and think it odd, that user have to complain about such a bug, instead of fixing it right away. Basically any application providing a systray entry works the way expected by the OP -- why won't mm?
This seems to be due to a limitation of electron between versions 3 and 8. The click event is not handled on Linux for these versions.
I opened a PR for the same problem for Rambox here. In their case, the fix consists in simply bumping the electron version to 8 and properly handling the click event.
Please consider doing the same when you will reach that version of electron 😊
This is working correctly for me on Kubuntu 20.04 using KDE Plasma and Desktop App v5.0.2. Closing unless this issue is still relevant.
Debian/Sid, MM Desktop 5.0.2 and the original issue still persists. Please reopen.
Same here on Kubuntu 20.04 with Plasma (fully up to date as of today, Dec. 10th) and 5.0.2. The issue still persists. Already deleted ~/.config/Mattermost
.
@2019-05-10 @marcoesposito1988 How did you install Mattermost on your machines? I used the .deb and had no trouble.
Thanks for reopening the issue @devinbinnie! I also used the deb. I already tried deleting the config, but if I can try something else (deleting some cache) or you need some logs or more information about my system, just please let me know.
In the weekend I may manage to test it in a fresh VM with a live Kubuntu
@marcoesposito1988 That's what I used, a fresh Kubuntu VM and it works fine for me. Let me know what your findings are :)
The issue doesn't appear indeed in a fresh instance. I will try to find the root cause of the issue.
Why has this been closed? Unless the issue is solved for existing installations, it certainly cannot be considered solved. The MS Windows way ("reinstall everything") is definitely not a solution.
Why has this been closed? Unless the issue is solved for existing installations, it certainly cannot be considered solved. The MS Windows way ("reinstall everything") is definitely not a solution.
This issue is not closed, we are awaiting investigation. @marcoesposito1988 Did you ever end up finding anything with your investigation?
Uh, I apologize. I got confused by the "Closed" label on the reference to #1937
Found another case for this problem.
If you close main window before actually configuring any server, then there's no way you can bring main window back again.
Steps to reproduce
from master
branch
- clean all settings
-
npm ci
-
npm run watch
- don't configure servers
- go to settings
- enable Show icon in the notification area
- enable Leave app running in notification area when application window is closed
- close window without terminating app
Result
In tray there are no options to bring main window back again.
Workaround
- make app restart
I did not have this issue until I installed the libappindicator-gtk3 package from the Arch Linux repositories. After installing this, clicking on the system tray did not even register in the mattermost-desktop log in any way. Uninstalling it again fixed the problem.
EDIT: This problem was identified a long time ago, but never really fixed. Maybe one can opt-out of using the appindicator in all/most cases?
EDIT2: Did not read till the end, should be fixed in newer versions of electron: https://github.com/electron/electron/pull/36333
This has been fixed in this PR: https://github.com/mattermost/desktop/pull/2708 (actually probably earlier since it's an Electron issue).
Note for users still using libappindicator, this is not fixed and sounds like it won't be fixed upstream. But it should be working for most users.
Closing.