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

Side by Side Diff: content/renderer/render_frame_impl.cc

Issue 972313002: Make <webview> use out-of-process iframe architecture. (Closed) Base URL: ssh://saopaulo.wat/mnt/dev/shared/src@testoopif2z-better-chrome
Patch Set: Revert unused changes from previous attempt + more cleanup. Created 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "content/renderer/render_frame_impl.h" 5 #include "content/renderer/render_frame_impl.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 9
10 #include "base/auto_reset.h" 10 #include "base/auto_reset.h"
(...skipping 992 matching lines...) Expand 10 before | Expand all | Expand 10 after
1003 OnShowTransitionElements) 1003 OnShowTransitionElements)
1004 IPC_MESSAGE_HANDLER(FrameMsg_Reload, OnReload) 1004 IPC_MESSAGE_HANDLER(FrameMsg_Reload, OnReload)
1005 IPC_MESSAGE_HANDLER(FrameMsg_TextSurroundingSelectionRequest, 1005 IPC_MESSAGE_HANDLER(FrameMsg_TextSurroundingSelectionRequest,
1006 OnTextSurroundingSelectionRequest) 1006 OnTextSurroundingSelectionRequest)
1007 IPC_MESSAGE_HANDLER(FrameMsg_AddStyleSheetByURL, 1007 IPC_MESSAGE_HANDLER(FrameMsg_AddStyleSheetByURL,
1008 OnAddStyleSheetByURL) 1008 OnAddStyleSheetByURL)
1009 IPC_MESSAGE_HANDLER(FrameMsg_SetAccessibilityMode, 1009 IPC_MESSAGE_HANDLER(FrameMsg_SetAccessibilityMode,
1010 OnSetAccessibilityMode) 1010 OnSetAccessibilityMode)
1011 IPC_MESSAGE_HANDLER(FrameMsg_DisownOpener, OnDisownOpener) 1011 IPC_MESSAGE_HANDLER(FrameMsg_DisownOpener, OnDisownOpener)
1012 IPC_MESSAGE_HANDLER(FrameMsg_CommitNavigation, OnCommitNavigation) 1012 IPC_MESSAGE_HANDLER(FrameMsg_CommitNavigation, OnCommitNavigation)
1013 IPC_MESSAGE_HANDLER(FrameMsg_ReplaceLocalFrameWithProxy,
1014 OnReplaceLocalFrameWithProxy)
1013 #if defined(OS_ANDROID) 1015 #if defined(OS_ANDROID)
1014 IPC_MESSAGE_HANDLER(FrameMsg_SelectPopupMenuItems, OnSelectPopupMenuItems) 1016 IPC_MESSAGE_HANDLER(FrameMsg_SelectPopupMenuItems, OnSelectPopupMenuItems)
1015 #elif defined(OS_MACOSX) 1017 #elif defined(OS_MACOSX)
1016 IPC_MESSAGE_HANDLER(FrameMsg_SelectPopupMenuItem, OnSelectPopupMenuItem) 1018 IPC_MESSAGE_HANDLER(FrameMsg_SelectPopupMenuItem, OnSelectPopupMenuItem)
1017 IPC_MESSAGE_HANDLER(InputMsg_CopyToFindPboard, OnCopyToFindPboard) 1019 IPC_MESSAGE_HANDLER(InputMsg_CopyToFindPboard, OnCopyToFindPboard)
1018 #endif 1020 #endif
1019 IPC_END_MESSAGE_MAP() 1021 IPC_END_MESSAGE_MAP()
1020 1022
1021 return handled; 1023 return handled;
1022 } 1024 }
(...skipping 2879 matching lines...) Expand 10 before | Expand all | Expand 10 after
3902 3904
3903 // Record this before starting the load. A lower bound of this time is needed 3905 // Record this before starting the load. A lower bound of this time is needed
3904 // to sanitize the navigationStart override set below. 3906 // to sanitize the navigationStart override set below.
3905 base::TimeTicks renderer_navigation_start = base::TimeTicks::Now(); 3907 base::TimeTicks renderer_navigation_start = base::TimeTicks::Now();
3906 frame_->loadRequest(request); 3908 frame_->loadRequest(request);
3907 UpdateFrameNavigationTiming( 3909 UpdateFrameNavigationTiming(
3908 frame_, commit_params.browser_navigation_start, 3910 frame_, commit_params.browser_navigation_start,
3909 renderer_navigation_start); 3911 renderer_navigation_start);
3910 } 3912 }
3911 3913
3914 void RenderFrameImpl::OnReplaceLocalFrameWithProxy(int proxy_routing_id) {
3915 RenderFrameProxy* proxy_to_replace_frame = RenderFrameProxy::FromRoutingID(
3916 proxy_routing_id);
3917 DCHECK(proxy_to_replace_frame);
3918
3919 blink::WebRemoteFrame* web_frame =
3920 blink::WebRemoteFrame::create(proxy_to_replace_frame);
3921 proxy_to_replace_frame->SetWebRemoteFrame(web_frame);
3922 proxy_to_replace_frame->web_frame()->initializeFromFrame(frame_);
3923 frame_->swap(proxy_to_replace_frame->web_frame());
3924 printf("**** done swap() ****\n");
3925 render_view_->RegisterRenderFrameProxy(proxy_to_replace_frame);
3926 }
3927
3912 WebNavigationPolicy RenderFrameImpl::DecidePolicyForNavigation( 3928 WebNavigationPolicy RenderFrameImpl::DecidePolicyForNavigation(
3913 RenderFrame* render_frame, 3929 RenderFrame* render_frame,
3914 const NavigationPolicyInfo& info) { 3930 const NavigationPolicyInfo& info) {
3915 #ifdef OS_ANDROID 3931 #ifdef OS_ANDROID
3916 // The handlenavigation API is deprecated and will be removed once 3932 // The handlenavigation API is deprecated and will be removed once
3917 // crbug.com/325351 is resolved. 3933 // crbug.com/325351 is resolved.
3918 if (info.urlRequest.url() != GURL(kSwappedOutURL) && 3934 if (info.urlRequest.url() != GURL(kSwappedOutURL) &&
3919 GetContentClient()->renderer()->HandleNavigation( 3935 GetContentClient()->renderer()->HandleNavigation(
3920 render_frame, 3936 render_frame,
3921 static_cast<DocumentState*>(info.extraData), 3937 static_cast<DocumentState*>(info.extraData),
(...skipping 519 matching lines...) Expand 10 before | Expand all | Expand 10 after
4441 4457
4442 #if defined(ENABLE_BROWSER_CDMS) 4458 #if defined(ENABLE_BROWSER_CDMS)
4443 RendererCdmManager* RenderFrameImpl::GetCdmManager() { 4459 RendererCdmManager* RenderFrameImpl::GetCdmManager() {
4444 if (!cdm_manager_) 4460 if (!cdm_manager_)
4445 cdm_manager_ = new RendererCdmManager(this); 4461 cdm_manager_ = new RendererCdmManager(this);
4446 return cdm_manager_; 4462 return cdm_manager_;
4447 } 4463 }
4448 #endif // defined(ENABLE_BROWSER_CDMS) 4464 #endif // defined(ENABLE_BROWSER_CDMS)
4449 4465
4450 } // namespace content 4466 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698