| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 189 bool external_; | 189 bool external_; |
| 190 | 190 |
| 191 private: | 191 private: |
| 192 friend class RenderViewContextMenuTest; | 192 friend class RenderViewContextMenuTest; |
| 193 | 193 |
| 194 static bool IsDevToolsURL(const GURL& url); | 194 static bool IsDevToolsURL(const GURL& url); |
| 195 static bool IsInternalResourcesURL(const GURL& url); | 195 static bool IsInternalResourcesURL(const GURL& url); |
| 196 static bool ExtensionContextAndPatternMatch( | 196 static bool ExtensionContextAndPatternMatch( |
| 197 const content::ContextMenuParams& params, | 197 const content::ContextMenuParams& params, |
| 198 extensions::MenuItem::ContextList contexts, | 198 extensions::MenuItem::ContextList contexts, |
| 199 const URLPatternSet& target_url_patterns); | 199 const extensions::URLPatternSet& target_url_patterns); |
| 200 static bool MenuItemMatchesParams( | 200 static bool MenuItemMatchesParams( |
| 201 const content::ContextMenuParams& params, | 201 const content::ContextMenuParams& params, |
| 202 const extensions::MenuItem* item); | 202 const extensions::MenuItem* item); |
| 203 | 203 |
| 204 // Gets the extension (if any) associated with the WebContents that we're in. | 204 // Gets the extension (if any) associated with the WebContents that we're in. |
| 205 const extensions::Extension* GetExtension() const; | 205 const extensions::Extension* GetExtension() const; |
| 206 void AppendPlatformAppItems(); | 206 void AppendPlatformAppItems(); |
| 207 void AppendPopupExtensionItems(); | 207 void AppendPopupExtensionItems(); |
| 208 void AppendPanelItems(); | 208 void AppendPanelItems(); |
| 209 bool AppendCustomItems(); | 209 bool AppendCustomItems(); |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 274 // An observer that disables menu items when print preview is active. | 274 // An observer that disables menu items when print preview is active. |
| 275 scoped_ptr<PrintPreviewContextMenuObserver> print_preview_menu_observer_; | 275 scoped_ptr<PrintPreviewContextMenuObserver> print_preview_menu_observer_; |
| 276 | 276 |
| 277 // Our observers. | 277 // Our observers. |
| 278 mutable ObserverList<RenderViewContextMenuObserver> observers_; | 278 mutable ObserverList<RenderViewContextMenuObserver> observers_; |
| 279 | 279 |
| 280 DISALLOW_COPY_AND_ASSIGN(RenderViewContextMenu); | 280 DISALLOW_COPY_AND_ASSIGN(RenderViewContextMenu); |
| 281 }; | 281 }; |
| 282 | 282 |
| 283 #endif // CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ | 283 #endif // CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ |
| OLD | NEW |