Chromium Code Reviews| 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..08e4465da5bd3634d71b08ea84150327a1401f7a 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; | 
| + // Set icon to the actual menu items controlled by the toolkit. | 
| 
 
lazyboy
2015/02/13 08:10:39
Sets icon to ...
 
pals
2015/02/13 09:30:40
Done.
 
 | 
| + virtual void SetIcon(int command_id, const gfx::Image& 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::Image& icon) override; | 
| content::RenderViewHost* GetRenderViewHost() const override; | 
| content::WebContents* GetWebContents() const override; | 
| content::BrowserContext* GetBrowserContext() const override; | 
| @@ -181,11 +184,23 @@ class RenderViewContextMenuBase : public ui::SimpleMenuModel::Delegate, | 
| private: | 
| bool AppendCustomItems(); | 
| + void AddCustomItemsToMenu(const std::vector<content::MenuItem>& items, | 
| + size_t depth, | 
| + size_t* total_items, | 
| + ui::SimpleMenuModel::Delegate* delegate, | 
| + ui::SimpleMenuModel* menu_model); | 
| + void OnIconDownloaded(int command_id, | 
| + int id, | 
| + int http_status_code, | 
| + const GURL& image_url, | 
| + const std::vector<SkBitmap>& bitmaps, | 
| + const std::vector<gfx::Size>& original_bitmap_sizes); | 
| // The RenderFrameHost's IDs. | 
| int render_process_id_; | 
| scoped_ptr<ToolkitDelegate> toolkit_delegate_; | 
| + base::WeakPtrFactory<RenderViewContextMenuBase> weak_ptr_factory_; | 
| DISALLOW_COPY_AND_ASSIGN(RenderViewContextMenuBase); | 
| }; |