Skip to content

Use dbus to query for org.kde.StatusNotifierWatcher #14635

Closed

Description

@ckerr

Inspired by #12743

Right now Electron is hardcoding the desktop environments that are known to support app indicators. It would be less hacky to just check and see if StatusNotifierWatcher is owned on the bus.

Activity

  1. self-assigned this
    on Sep 20, 2018
  2. ckerr commented on Sep 21, 2018

    @ckerr
    MemberAuthor

    Some notes on this:

    • The bus monitoring would likely be better done in our C++ code. Chromium has a dbus API that could be used for this.
    • For the first deliverable I think it would be enough to say "hasAppIndicator is true iff org.kde.StatusNotifierWatcher is owned by someone on the Session bus."
    • Chromium's Bus::GetServiceOwner() is probably the right API call for this
    • Note a possible point of confusion when you try this with the Chromium dbus API: Their owned_service_names_ is a list of names we own, which is not a good match for this test of "is it owned by anyone", ie "is there a service on the session bus that owns o.k.SNW?"
    • We should research the original motivation behind setting process.env.XDG_CURRENT_DESKTOP = 'Unity' since Unity has been canceled and it's no longer Ubuntu's default desktop environment. Is there some legacy code out there still hardwired to sniff for the name 'Unity' or can we change/remove this?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions