Index: chrome/common/extensions/api/system_indicator.idl |
diff --git a/chrome/common/extensions/api/system_indicator.idl b/chrome/common/extensions/api/system_indicator.idl |
new file mode 100644 |
index 0000000000000000000000000000000000000000..d7398a052b30ae2e9576744caba3a746b52ccf80 |
--- /dev/null |
+++ b/chrome/common/extensions/api/system_indicator.idl |
@@ -0,0 +1,34 @@ |
+// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+// Manages an app's system indicator icon, an image displayed in the system's |
+// menubar, system tray, or other visible area provided by the OS. |
+namespace systemIndicator { |
+ dictionary SetIconDetails { |
+ any? path; |
+ any? imageData; |
+ }; |
+ |
+ callback DoneCallback = void (); |
+ |
+ interface Functions { |
+ // Set the image to be used as an indicator icon, using a set of ImageData |
+ // objects. These objects should have multiple resolutions so that an |
+ // appropriate size can be selected for the given icon size and DPI scaling |
+ // settings. Only square ImageData objects are accepted. |
+ static void setIcon(SetIconDetails details, optional DoneCallback callback); |
+ |
+ // Show the icon in the status tray. |
+ static void enable(optional DoneCallback callback); |
+ |
+ // Hide the icon from the status tray. |
+ static void disable(optional DoneCallback callback); |
+ }; |
+ |
+ interface Events { |
+ // Fired only when a click on the icon does not result in a menu being |
+ // shown. |
+ static void onClicked(); |
+ }; |
+}; |