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

Side by Side Diff: content/shell/browser/shell_web_contents_view_delegate_win.cc

Issue 405123002: clang/win: Fix a Wenum-compare warning and a few Wwritable-strings warnings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « base/time/time_win_unittest.cc ('k') | rlz/win/lib/process_info.h » ('j') | 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 "content/shell/browser/shell_web_contents_view_delegate.h" 5 #include "content/shell/browser/shell_web_contents_view_delegate.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "content/public/browser/render_frame_host.h" 8 #include "content/public/browser/render_frame_host.h"
9 #include "content/public/browser/render_process_host.h" 9 #include "content/public/browser/render_process_host.h"
10 #include "content/public/browser/render_view_host.h" 10 #include "content/public/browser/render_view_host.h"
(...skipping 20 matching lines...) Expand all
31 ShellContextMenuItemDeleteId, 31 ShellContextMenuItemDeleteId,
32 ShellContextMenuItemOpenLinkId, 32 ShellContextMenuItemOpenLinkId,
33 ShellContextMenuItemBackId, 33 ShellContextMenuItemBackId,
34 ShellContextMenuItemForwardId, 34 ShellContextMenuItemForwardId,
35 ShellContextMenuItemReloadId, 35 ShellContextMenuItemReloadId,
36 ShellContextMenuItemInspectId 36 ShellContextMenuItemInspectId
37 }; 37 };
38 38
39 void MakeContextMenuItem(HMENU menu, 39 void MakeContextMenuItem(HMENU menu,
40 int menu_index, 40 int menu_index,
41 LPTSTR text, 41 LPCTSTR text,
42 UINT id, 42 UINT id,
43 bool enabled) { 43 bool enabled) {
44 MENUITEMINFO mii = {0}; 44 MENUITEMINFO mii = {0};
45 mii.cbSize = sizeof(mii); 45 mii.cbSize = sizeof(mii);
46 mii.fMask = MIIM_FTYPE | MIIM_ID | MIIM_DATA | MIIM_STRING | MIIM_STATE; 46 mii.fMask = MIIM_FTYPE | MIIM_ID | MIIM_DATA | MIIM_STRING | MIIM_STATE;
47 mii.fState = enabled ? MFS_ENABLED : (MF_DISABLED | MFS_GRAYED); 47 mii.fState = enabled ? MFS_ENABLED : (MF_DISABLED | MFS_GRAYED);
48 mii.fType = MFT_STRING; 48 mii.fType = MFT_STRING;
49 mii.wID = id; 49 mii.wID = id;
50 mii.dwTypeData = text; 50 mii.dwTypeData = const_cast<LPTSTR>(text);
51 51
52 InsertMenuItem(menu, menu_index, TRUE, &mii); 52 InsertMenuItem(menu, menu_index, TRUE, &mii);
53 } 53 }
54 54
55 } // namespace 55 } // namespace
56 56
57 namespace content { 57 namespace content {
58 58
59 WebContentsViewDelegate* CreateShellWebContentsViewDelegate( 59 WebContentsViewDelegate* CreateShellWebContentsViewDelegate(
60 WebContents* web_contents) { 60 WebContents* web_contents) {
(...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after
246 return false; 246 return false;
247 } 247 }
248 248
249 void ShellWebContentsViewDelegate::TakeFocus(bool reverse) { 249 void ShellWebContentsViewDelegate::TakeFocus(bool reverse) {
250 } 250 }
251 251
252 void ShellWebContentsViewDelegate::SizeChanged(const gfx::Size& size) { 252 void ShellWebContentsViewDelegate::SizeChanged(const gfx::Size& size) {
253 } 253 }
254 254
255 } // namespace content 255 } // namespace content
OLDNEW
« no previous file with comments | « base/time/time_win_unittest.cc ('k') | rlz/win/lib/process_info.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698