Summary: | Request for help to get some handle to a system tray icon created with libayatana-appindicator | ||
---|---|---|---|
Product: | [Plasma] plasmashell | Reporter: | Jorg K <mozilla> |
Component: | System Tray | Assignee: | Plasma Bugs List <plasma-bugs> |
Status: | RESOLVED NOT A BUG | ||
Severity: | wishlist | CC: | fella, materka, nate, qydwhotmail |
Priority: | NOR | ||
Version: | 5.26.0 | ||
Target Milestone: | 1.0 | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Jorg K
2023-02-07 18:24:49 UTC
Thank you for the bug report! However Plasma 5.18.0 is no longer supported by KDE; supported versions are 5.24, and 5.26 or newer. Your distribution is responsible for providing support for older versions of KDE software. Please do one of the following: - Upgrade to a supported version and see if the issue is still relevant - Report the issue to your distribution If I understand the D-Bus protocol correctly, what you want is to do something (i.e. raise window) in the activate function [0] of the org.kde.StatusNotifierItem protocol, which looks like what you're doing in the comment you linked. For some reason this function seems missing from ayatana's version of the dbus XML [1] - I don't know how their dbus code works, maybe that could be the problem? [0] https://invent.kde.org/frameworks/knotifications/-/blob/master/src/org.kde.StatusNotifierItem.xml#L63 [1] https://github.com/AyatanaIndicators/libayatana-appindicator/blob/master/src/notification-item.xml Thanks for the comment. I'm really a Thunderbird/Betterbird/Mozilla programmer (mostly on Windows), so please excuse the ignorance. We've integrated libayatana-appindicator and one of their PRs into Betterbird, then patched it even further thanks to the advice received in bug 464264 comment #9. Yes, we want to "unhide" a window when a click on the indicator is received. So if I understand your comment correctly, KDE already provides a notification for that event, only that it's not hooked up in the libayatana-appindicator implementation. That's totally possible. Are you aware of other applications which successfully listen to such notifications? We could learn from them. Feel free to keep chatting, but I'm closing the bug so it doesn't appear in new bug lists, because technically Bugzilla is not the place for development assistance. If the conversation trails off here, I would recommend continuing it at kde-devel@kde.org. Thanks and apologies for the misuse of your bug tracker! Will use the mailing list in the future. IIRC this is a limitation in appindicator lib. This "Activate" operation was never implemented, probably because it was not needed in Unity/Gnome desktop. It was long time I used it last time, but I think status notifiers are implemented differently there - they are integrated into task manager. So task manager handles left click (to show/minimize app) and "Activate" part of SNI is never used. Yes, "activate" was never implemented, see https://github.com/AyatanaIndicators/libayatana-appindicator/issues/4, but how would we go about implementing it. Just to close the circle here, https://github.com/AyatanaIndicators/libayatana-appindicator/pull/71 implements "activation" satisfying https://github.com/AyatanaIndicators/libayatana-appindicator/issues/4. That initially worked for KDE and Gnome, then the Xfce developer showed up on the PR and posted some code to make it work for Xfce as well. Some user suggested a setting to make it work for Mate, but that doesn't work for us. In summary, Betterbird shows a system tray icon via libayatana-appindicator and clicking it, activates the application in KDE, Gnome and Xfce. Activation is a little patchy, on KDE sometimes the window is raised, sometimes the taskbar (panel?) button is highlighted. We might file another ticket for that. We're tracking this in https://github.com/Betterbird/thunderbird-patches/issues/202. |