| Index: chrome/browser/views/status_icons/status_icon_win.h
|
| diff --git a/chrome/browser/views/status_icons/status_icon_win.h b/chrome/browser/views/status_icons/status_icon_win.h
|
| index e3f88f4295c6d3a8ad4b6a7abf68c45e5021ab40..f698fc4f309d3dadb1ecd978fa388deb396318a2 100644
|
| --- a/chrome/browser/views/status_icons/status_icon_win.h
|
| +++ b/chrome/browser/views/status_icons/status_icon_win.h
|
| @@ -10,8 +10,13 @@
|
| #include <shellapi.h>
|
|
|
| #include "base/scoped_handle_win.h"
|
| +#include "base/scoped_ptr.h"
|
| #include "chrome/browser/status_icons/status_icon.h"
|
|
|
| +namespace views {
|
| +class Menu2;
|
| +}
|
| +
|
| class StatusIconWin : public StatusIcon {
|
| public:
|
| // Constructor which provides this icon's unique ID and messaging window.
|
| @@ -27,6 +32,14 @@ class StatusIconWin : public StatusIcon {
|
|
|
| UINT message_id() const { return message_id_; }
|
|
|
| + // Handles a click event from the user - if |left_button_click| is true and
|
| + // there is a registered observer, passes the click event to the observer,
|
| + // otherwise displays the context menu if there is one.
|
| + void HandleClickEvent(int x, int y, bool left_button_click);
|
| +
|
| + protected:
|
| + virtual void ResetContextMenu(menus::MenuModel* menu);
|
| +
|
| private:
|
| void InitIconData(NOTIFYICONDATA* icon_data);
|
|
|
| @@ -42,6 +55,9 @@ class StatusIconWin : public StatusIcon {
|
| // The currently-displayed icon for the window.
|
| ScopedHICON icon_;
|
|
|
| + // Context menu associated with this icon (if any).
|
| + scoped_ptr<views::Menu2> context_menu_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(StatusIconWin);
|
| };
|
|
|
|
|