OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #ifndef CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ | 5 #ifndef CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ |
6 #define CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ | 6 #define CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <map> | 9 #include <map> |
10 #include <string> | 10 #include <string> |
(...skipping 14 matching lines...) Expand all Loading... |
25 namespace gfx { | 25 namespace gfx { |
26 class Point; | 26 class Point; |
27 } | 27 } |
28 | 28 |
29 namespace WebKit { | 29 namespace WebKit { |
30 struct WebMediaPlayerAction; | 30 struct WebMediaPlayerAction; |
31 } | 31 } |
32 | 32 |
33 class RenderViewContextMenu : public menus::SimpleMenuModel::Delegate { | 33 class RenderViewContextMenu : public menus::SimpleMenuModel::Delegate { |
34 public: | 34 public: |
| 35 static const size_t kMaxExtensionItemTitleLength; |
| 36 static const size_t kMaxSelectionTextLength; |
| 37 |
35 RenderViewContextMenu(TabContents* tab_contents, | 38 RenderViewContextMenu(TabContents* tab_contents, |
36 const ContextMenuParams& params); | 39 const ContextMenuParams& params); |
37 | 40 |
38 virtual ~RenderViewContextMenu(); | 41 virtual ~RenderViewContextMenu(); |
39 | 42 |
40 // Initializes the context menu. | 43 // Initializes the context menu. |
41 void Init(); | 44 void Init(); |
42 | 45 |
43 // SimpleMenuModel::Delegate implementation. | 46 // SimpleMenuModel::Delegate implementation. |
44 virtual bool IsCommandIdChecked(int command_id) const; | 47 virtual bool IsCommandIdChecked(int command_id) const; |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 GURL selection_navigation_url_; | 136 GURL selection_navigation_url_; |
134 | 137 |
135 menus::SimpleMenuModel spellcheck_submenu_model_; | 138 menus::SimpleMenuModel spellcheck_submenu_model_; |
136 menus::SimpleMenuModel bidi_submenu_model_; | 139 menus::SimpleMenuModel bidi_submenu_model_; |
137 ScopedVector<menus::SimpleMenuModel> extension_menu_models_; | 140 ScopedVector<menus::SimpleMenuModel> extension_menu_models_; |
138 | 141 |
139 DISALLOW_COPY_AND_ASSIGN(RenderViewContextMenu); | 142 DISALLOW_COPY_AND_ASSIGN(RenderViewContextMenu); |
140 }; | 143 }; |
141 | 144 |
142 #endif // CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ | 145 #endif // CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ |
OLD | NEW |