1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 // Manages an app's system indicator icon, an image displayed in the system's
6 // menubar, system tray, or other visible area provided by the OS.
7 // This is modelled after the other extension action APIs, such as
8 // chrome.browserAction and chrome.pageAction.
9 namespace systemIndicator
{
10 dictionary SetIconDetails
{
15 callback DoneCallback
= void ();
18 // Set the image to be used as an indicator icon, using a set of ImageData
19 // objects. These objects should have multiple resolutions so that an
20 // appropriate size can be selected for the given icon size and DPI scaling
21 // settings. Only square ImageData objects are accepted.
22 static
void setIcon
(SetIconDetails details
, optional DoneCallback
callback);
24 // Show the icon in the status tray.
27 // Hide the icon from the status tray.
28 static
void disable
();
32 // Fired only when a click on the icon does not result in a menu being
34 static
void onClicked
();