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

Unified Diff: chrome/browser/extensions/api/messaging/message_service.cc

Issue 2529213002: Delete TODO-comment about guest process/frame IDs in MessageService::OpenChannelImpl (Closed)
Patch Set: Created 4 years, 1 month 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/api/messaging/message_service.cc
diff --git a/chrome/browser/extensions/api/messaging/message_service.cc b/chrome/browser/extensions/api/messaging/message_service.cc
index 5b4c3829bff7839f33c2214405d12a301177a635..768cb40acd4f590a0ed79a3c94d959b29cffab65 100644
--- a/chrome/browser/extensions/api/messaging/message_service.cc
+++ b/chrome/browser/extensions/api/messaging/message_service.cc
@@ -594,26 +594,12 @@ void MessageService::OpenChannelImpl(BrowserContext* browser_context,
channel->receiver.reset(params->receiver.release());
AddChannel(std::move(channel_ptr), params->receiver_port_id);
- // TODO(robwu): Could |guest_process_id| and |guest_render_frame_routing_id|
- // be removed? In the past extension message routing was process-based, but
- // now that extensions are routed from a specific RFH, the special casing for
- // guest views seems no longer necessary, because the ExtensionMessagePort can
- // simply obtain the source process & frame ID directly from the RFH.
- int guest_process_id = content::ChildProcessHost::kInvalidUniqueID;
- int guest_render_frame_routing_id = MSG_ROUTING_NONE;
- if (params->include_guest_process_info) {
- guest_process_id = params->source_process_id;
- guest_render_frame_routing_id = params->source_routing_id;
-
- DCHECK(WebViewGuest::FromWebContents(
- WebContents::FromRenderFrameHost(source)));
- }
-
// Send the connect event to the receiver. Give it the opener's port ID (the
// opener has the opposite port ID).
channel->receiver->DispatchOnConnect(
params->channel_name, std::move(params->source_tab),
- params->source_frame_id, guest_process_id, guest_render_frame_routing_id,
+ params->source_frame_id, params->include_guest_process_info,
+ params->source_process_id, params->source_routing_id,
params->source_extension_id, params->target_extension_id,
params->source_url, params->tls_channel_id);

Powered by Google App Engine
This is Rietveld 408576698