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

Unified Diff: content/browser/tab_contents/tab_contents.cc

Issue 6794035: Move dispatching and sending of the last extension specific messages out of TabContents and Rende... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 9 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: content/browser/tab_contents/tab_contents.cc
===================================================================
--- content/browser/tab_contents/tab_contents.cc (revision 80315)
+++ content/browser/tab_contents/tab_contents.cc (working copy)
@@ -416,10 +416,6 @@
IPC_MESSAGE_HANDLER(ViewHostMsg_PDFHasUnsupportedFeature,
OnPDFHasUnsupportedFeature)
IPC_MESSAGE_HANDLER(ViewHostMsg_GoToEntryAtOffset, OnGoToEntryAtOffset)
- IPC_MESSAGE_HANDLER(ExtensionHostMsg_DidGetApplicationInfo,
- OnDidGetApplicationInfo)
- IPC_MESSAGE_HANDLER(ExtensionHostMsg_InstallApplication,
- OnInstallApplication)
IPC_MESSAGE_HANDLER(ViewHostMsg_PageContents, OnPageContents)
IPC_MESSAGE_HANDLER(ViewHostMsg_PageTranslated, OnPageTranslated)
IPC_MESSAGE_UNHANDLED(handled = false)
@@ -846,22 +842,6 @@
PopupNotificationVisibilityChanged(blocked_contents_ != NULL);
}
-bool TabContents::ExecuteCode(int request_id, const std::string& extension_id,
- bool is_js_code, const std::string& code_string,
- bool all_frames) {
- RenderViewHost* host = render_view_host();
- if (!host)
- return false;
-
- ExtensionMsg_ExecuteCode_Params params;
- params.request_id = request_id;
- params.extension_id = extension_id;
- params.is_javascript = is_js_code;
- params.code = code_string;
- params.all_frames = all_frames;
- return host->Send(new ExtensionMsg_ExecuteCode(host->routing_id(), params));
-}
-
void TabContents::PopupNotificationVisibilityChanged(bool visible) {
if (is_being_destroyed_)
return;
@@ -1800,19 +1780,6 @@
}
}
-void TabContents::OnDidGetApplicationInfo(int32 page_id,
- const WebApplicationInfo& info) {
- web_app_info_ = info;
-
- if (delegate())
- delegate()->OnDidGetApplicationInfo(this, page_id);
-}
-
-void TabContents::OnInstallApplication(const WebApplicationInfo& info) {
- if (delegate())
- delegate()->OnInstallApplication(this, info);
-}
-
void TabContents::OnPageContents(const GURL& url,
int32 page_id,
const string16& contents,
@@ -2256,7 +2223,9 @@
if (!render_manager_.web_ui()) {
// This can happen if someone uses window.open() to open an extension URL
// from a non-extension context.
- render_view_host()->BlockExtensionRequest(params.request_id);
+ render_view_host()->Send(new ExtensionMsg_Response(
+ render_view_host()->routing_id(), params.request_id, false, "",
+ "Access to extension API denied."));
return;
}
render_manager_.web_ui()->ProcessWebUIMessage(params);

Powered by Google App Engine
This is Rietveld 408576698