OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2010 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. |
| 4 |
| 5 #ifndef CHROME_BROWSER_STATUS_ICONS_STATUS_ICON_H_ |
| 6 #define CHROME_BROWSER_STATUS_ICONS_STATUS_ICON_H_ |
| 7 |
| 8 #include "base/string16.h" |
| 9 |
| 10 class SkBitmap; |
| 11 |
| 12 class StatusIcon { |
| 13 public: |
| 14 // Creates a new StatusIcon. |
| 15 static StatusIcon* Create(); |
| 16 |
| 17 virtual ~StatusIcon() {} |
| 18 |
| 19 // Sets the image associated with this status icon. |
| 20 virtual void SetImage(const SkBitmap& image) = 0; |
| 21 |
| 22 // Sets the hover text for this status icon. |
| 23 virtual void SetToolTip(const string16& tool_tip) = 0; |
| 24 |
| 25 class StatusIconObserver { |
| 26 public: |
| 27 virtual ~StatusIconObserver() {} |
| 28 |
| 29 // Called when the user clicks on the system tray icon. |
| 30 virtual void OnClicked() = 0; |
| 31 }; |
| 32 |
| 33 // Adds/removes a observer for status bar events. |
| 34 virtual void AddObserver(StatusIcon::StatusIconObserver* observer) = 0; |
| 35 virtual void RemoveObserver(StatusIcon::StatusIconObserver* observer) = 0; |
| 36 }; |
| 37 |
| 38 |
| 39 #endif // CHROME_BROWSER_STATUS_ICONS_STATUS_ICON_H_ |
OLD | NEW |