Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1871)

Unified Diff: components/renderer_context_menu/render_view_context_menu_base.h

Issue 892953002: Show icons for custom menuitems in contextmenu. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/renderer_context_menu/render_view_context_menu_base.h
diff --git a/components/renderer_context_menu/render_view_context_menu_base.h b/components/renderer_context_menu/render_view_context_menu_base.h
index 779e8bbd9297aa178665649f6a32371860e6573d..59258f536ec5cf5fca7b4d69eea29e9f830769b4 100644
--- a/components/renderer_context_menu/render_view_context_menu_base.h
+++ b/components/renderer_context_menu/render_view_context_menu_base.h
@@ -51,6 +51,8 @@ class RenderViewContextMenuBase : public ui::SimpleMenuModel::Delegate,
bool enabled,
bool hidden,
const base::string16& title) = 0;
+ // Sets icon to the actual menu items controlled by the toolkit.
+ virtual void SetIcon(int command_id, const gfx::ImageSkia& icon) = 0;
};
static const size_t kMaxSelectionTextLength;
@@ -104,6 +106,7 @@ class RenderViewContextMenuBase : public ui::SimpleMenuModel::Delegate,
bool enabled,
bool hidden,
const base::string16& title) override;
+ void SetIcon(int command_id, const gfx::ImageSkia& icon) override;
content::RenderViewHost* GetRenderViewHost() const override;
content::WebContents* GetWebContents() const override;
content::BrowserContext* GetBrowserContext() const override;

Powered by Google App Engine
This is Rietveld 408576698