diff options
author | atwilson@chromium.org <atwilson@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-20 04:52:44 +0000 |
---|---|---|
committer | atwilson@chromium.org <atwilson@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-20 04:52:44 +0000 |
commit | 9979f5d4a25cab18fa10885c5c7b64ea9f8d8eeb (patch) | |
tree | 0204e3328959fb902f7fb613d0c99103a0e858c7 /chrome/browser/cocoa/status_icons | |
parent | c78b1e1619d7e700fce78f29533eba5ee78b0c70 (diff) | |
download | chromium_src-9979f5d4a25cab18fa10885c5c7b64ea9f8d8eeb.zip chromium_src-9979f5d4a25cab18fa10885c5c7b64ea9f8d8eeb.tar.gz chromium_src-9979f5d4a25cab18fa10885c5c7b64ea9f8d8eeb.tar.bz2 |
Added support for context menus to status icons.
BUG=37375
TEST=updated StatusIcon unit tests
Review URL: http://codereview.chromium.org/3189003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@56812 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/cocoa/status_icons')
-rw-r--r-- | chrome/browser/cocoa/status_icons/status_icon_mac.h | 3 | ||||
-rw-r--r-- | chrome/browser/cocoa/status_icons/status_icon_mac.mm | 5 |
2 files changed, 8 insertions, 0 deletions
diff --git a/chrome/browser/cocoa/status_icons/status_icon_mac.h b/chrome/browser/cocoa/status_icons/status_icon_mac.h index 3008607..3f4fbe2 100644 --- a/chrome/browser/cocoa/status_icons/status_icon_mac.h +++ b/chrome/browser/cocoa/status_icons/status_icon_mac.h @@ -26,6 +26,9 @@ class StatusIconMac : public StatusIcon { virtual void SetPressedImage(const SkBitmap& image); virtual void SetToolTip(const string16& tool_tip); + protected: + virtual void ResetContextMenu(menus::MenuModel* menu); + private: // Getter for item_ that allows lazy initialization. NSStatusItem* item(); diff --git a/chrome/browser/cocoa/status_icons/status_icon_mac.mm b/chrome/browser/cocoa/status_icons/status_icon_mac.mm index 5e824b8..0d50c76 100644 --- a/chrome/browser/cocoa/status_icons/status_icon_mac.mm +++ b/chrome/browser/cocoa/status_icons/status_icon_mac.mm @@ -75,3 +75,8 @@ void StatusIconMac::SetPressedImage(const SkBitmap& bitmap) { void StatusIconMac::SetToolTip(const string16& tool_tip) { [item() setToolTip:base::SysUTF16ToNSString(tool_tip)]; } + +void StatusIconMac::ResetContextMenu(menus::MenuModel* menu) { + // TODO(atwilson): Add support for context menus for Mac when actually needed + // (not yet used by anything) - http://crbug.com/37375. +} |