Index: chrome/browser/guest_view/web_view/context_menu_content_type_web_view.cc |
diff --git a/chrome/browser/guest_view/web_view/context_menu_content_type_web_view.cc b/chrome/browser/guest_view/web_view/context_menu_content_type_web_view.cc |
index c8f60cdbb2c5f78ec07027476e7c4785506be4c1..9a3a9d5dee9a2112f6b1f57134532c76412b0125 100644 |
--- a/chrome/browser/guest_view/web_view/context_menu_content_type_web_view.cc |
+++ b/chrome/browser/guest_view/web_view/context_menu_content_type_web_view.cc |
@@ -8,9 +8,13 @@ |
#include "chrome/common/chrome_switches.h" |
#include "chrome/common/chrome_version_info.h" |
#include "extensions/browser/guest_view/web_view/web_view_guest.h" |
+#include "extensions/browser/process_manager.h" |
#include "extensions/common/extension.h" |
#include "extensions/common/manifest.h" |
+using extensions::Extension; |
+using extensions::ProcessManager; |
+ |
ContextMenuContentTypeWebView::ContextMenuContentTypeWebView( |
content::WebContents* web_contents, |
const content::ContextMenuParams& params) |
@@ -20,6 +24,13 @@ ContextMenuContentTypeWebView::ContextMenuContentTypeWebView( |
ContextMenuContentTypeWebView::~ContextMenuContentTypeWebView() { |
} |
+const Extension* ContextMenuContentTypeWebView::GetExtension() const { |
+ ProcessManager* process_manager = |
+ ProcessManager::Get(source_web_contents()->GetBrowserContext()); |
+ return process_manager->GetExtensionForWebContents( |
+ source_web_contents()); |
+} |
+ |
bool ContextMenuContentTypeWebView::SupportsGroup(int group) { |
switch (group) { |
case ITEM_GROUP_PAGE: |