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

Unified Diff: chrome/browser/extensions/menu_manager.h

Issue 1181263007: WebView context menu cleanup. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comments. Rebased. Created 5 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/menu_manager.h
diff --git a/chrome/browser/extensions/menu_manager.h b/chrome/browser/extensions/menu_manager.h
index ab5471e21e60fd825622c6779379a7ba96412cf4..c2e2faa8d346b2b20ffa29ec4283ed68174c1a43 100644
--- a/chrome/browser/extensions/menu_manager.h
+++ b/chrome/browser/extensions/menu_manager.h
@@ -44,17 +44,20 @@ class MenuItem {
// A list of MenuItems.
typedef std::vector<MenuItem*> List;
- // Key used to identify which extension a menu item belongs to.
- // A menu item can also belong to a <webview> inside an extension,
- // only in that case |webview_instance_id| would be
- // non-zero (i.e. != guestview::kInstanceIDNone).
+ // EnstensionKey is used to identify a menu item. If the menu item belongs to
+ // an extension, than |extension_id| will be non-zero. Alternatively, if the
Devlin 2015/06/19 18:05:48 nit: s/than/then
paulmeyer 2015/06/19 18:18:10 Good catch! Done.
+ // menu item belongs to a WebView, then |webview_embedder_process_id| and
+ // |webview_instance_id| will be non-zero.
+ // TODO(paulmeyer): This should be called something else, since it is not just
+ // associated with extensions.
struct ExtensionKey {
std::string extension_id;
+ int webview_embedder_process_id;
int webview_instance_id;
ExtensionKey();
- ExtensionKey(const std::string& extension_id, int webview_instance_id);
explicit ExtensionKey(const std::string& extension_id);
+ ExtensionKey(int webview_embedder_process_id, int webview_instance_id);
bool operator==(const ExtensionKey& other) const;
bool operator!=(const ExtensionKey& other) const;

Powered by Google App Engine
This is Rietveld 408576698