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

Side by Side Diff: chrome/browser/tab_contents/render_view_context_menu.cc

Issue 21018003: [Chromium] Context menu option to print when right clicked on an image (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/tab_contents/render_view_context_menu.h" 5 #include "chrome/browser/tab_contents/render_view_context_menu.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <set> 8 #include <set>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 824 matching lines...) Expand 10 before | Expand all | Expand 10 after
835 835
836 void RenderViewContextMenu::AppendImageItems() { 836 void RenderViewContextMenu::AppendImageItems() {
837 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_SAVEIMAGEAS, 837 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_SAVEIMAGEAS,
838 IDS_CONTENT_CONTEXT_SAVEIMAGEAS); 838 IDS_CONTENT_CONTEXT_SAVEIMAGEAS);
839 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_COPYIMAGELOCATION, 839 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_COPYIMAGELOCATION,
840 IDS_CONTENT_CONTEXT_COPYIMAGELOCATION); 840 IDS_CONTENT_CONTEXT_COPYIMAGELOCATION);
841 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_COPYIMAGE, 841 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_COPYIMAGE,
842 IDS_CONTENT_CONTEXT_COPYIMAGE); 842 IDS_CONTENT_CONTEXT_COPYIMAGE);
843 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_OPENIMAGENEWTAB, 843 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_OPENIMAGENEWTAB,
844 IDS_CONTENT_CONTEXT_OPENIMAGENEWTAB); 844 IDS_CONTENT_CONTEXT_OPENIMAGENEWTAB);
845 AppendPrintItem();
845 } 846 }
846 847
847 void RenderViewContextMenu::AppendAudioItems() { 848 void RenderViewContextMenu::AppendAudioItems() {
848 AppendMediaItems(); 849 AppendMediaItems();
849 menu_model_.AddSeparator(ui::NORMAL_SEPARATOR); 850 menu_model_.AddSeparator(ui::NORMAL_SEPARATOR);
850 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_SAVEAVAS, 851 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_SAVEAVAS,
851 IDS_CONTENT_CONTEXT_SAVEAUDIOAS); 852 IDS_CONTENT_CONTEXT_SAVEAUDIOAS);
852 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_COPYAVLOCATION, 853 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_COPYAVLOCATION,
853 IDS_CONTENT_CONTEXT_COPYAUDIOLOCATION); 854 IDS_CONTENT_CONTEXT_COPYAUDIOLOCATION);
854 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_OPENAVNEWTAB, 855 menu_model_.AddItemWithStringId(IDC_CONTENT_CONTEXT_OPENAVNEWTAB,
(...skipping 1197 matching lines...) Expand 10 before | Expand all | Expand 10 after
2052 source_web_contents_->GetRenderViewHost()-> 2053 source_web_contents_->GetRenderViewHost()->
2053 ExecuteMediaPlayerActionAtLocation(location, action); 2054 ExecuteMediaPlayerActionAtLocation(location, action);
2054 } 2055 }
2055 2056
2056 void RenderViewContextMenu::PluginActionAt( 2057 void RenderViewContextMenu::PluginActionAt(
2057 const gfx::Point& location, 2058 const gfx::Point& location,
2058 const WebPluginAction& action) { 2059 const WebPluginAction& action) {
2059 source_web_contents_->GetRenderViewHost()-> 2060 source_web_contents_->GetRenderViewHost()->
2060 ExecutePluginActionAtLocation(location, action); 2061 ExecutePluginActionAtLocation(location, action);
2061 } 2062 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698