## Systray.SystrayManager

Systray.SystrayManager — Utility class for registering tray icon replacements

## Functions

| registerTrayIconReplacement ()
| unregisterTrayIconReplacement ()
| getRoles ()

## Object Hierarchy

        Object
        ╰── Systray.SystrayManager

## Description

This allows applets or other extensions to replace an app's legacy tray icon. For instance, the default network applet registers itself to replace network- manager's tray icon.

Tray icons typically show up in .xsession-errors as: ... Adding systray: evolution-alarm-notify (48x48px) ... If you wrote an applet to replace the alarm tray icon, you would register here with the name 'evolution-alarm-notify' and the uuid of your applet. As a result, if your applet is loaded, the tray icon would be removed.

Accessible at runtime as Main.systrayManager.

## Functions

### registerTrayIconReplacement ()

    registerTrayIconReplacement (string   role,
                                 string   uuid);

Registers the uuid to replace a tray icon identified by the role

#### Parameters

role | The systray icon name as reported in the logs. |
uuid | The uuid of the applet, desklet, or extension. |

### unregisterTrayIconReplacement ()

    unregisterTrayIconReplacement (string   uuid);

Unregisters the any roles claimed by uuid.

#### Parameters

uuid | The uuid of the applet, desklet, or extension. |

### getRoles ()

    getRoles ();

Returns an array of registered roles.