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

Side by Side Diff: content/browser/frame_host/render_frame_host_impl.cc

Issue 519533002: Initial PlzNavigate RDH-side logic. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix tests Created 6 years, 2 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/browser/frame_host/render_frame_host_impl.h" 5 #include "content/browser/frame_host/render_frame_host_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/containers/hash_tables.h" 9 #include "base/containers/hash_tables.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 #include "content/common/swapped_out_messages.h" 43 #include "content/common/swapped_out_messages.h"
44 #include "content/public/browser/ax_event_notification_details.h" 44 #include "content/public/browser/ax_event_notification_details.h"
45 #include "content/public/browser/browser_accessibility_state.h" 45 #include "content/public/browser/browser_accessibility_state.h"
46 #include "content/public/browser/browser_context.h" 46 #include "content/public/browser/browser_context.h"
47 #include "content/public/browser/browser_plugin_guest_manager.h" 47 #include "content/public/browser/browser_plugin_guest_manager.h"
48 #include "content/public/browser/browser_thread.h" 48 #include "content/public/browser/browser_thread.h"
49 #include "content/public/browser/content_browser_client.h" 49 #include "content/public/browser/content_browser_client.h"
50 #include "content/public/browser/desktop_notification_delegate.h" 50 #include "content/public/browser/desktop_notification_delegate.h"
51 #include "content/public/browser/render_process_host.h" 51 #include "content/public/browser/render_process_host.h"
52 #include "content/public/browser/render_widget_host_view.h" 52 #include "content/public/browser/render_widget_host_view.h"
53 #include "content/public/browser/stream_handle.h"
53 #include "content/public/browser/user_metrics.h" 54 #include "content/public/browser/user_metrics.h"
54 #include "content/public/common/content_constants.h" 55 #include "content/public/common/content_constants.h"
55 #include "content/public/common/content_switches.h" 56 #include "content/public/common/content_switches.h"
56 #include "content/public/common/url_constants.h" 57 #include "content/public/common/url_constants.h"
57 #include "content/public/common/url_utils.h" 58 #include "content/public/common/url_utils.h"
58 #include "ui/accessibility/ax_tree.h" 59 #include "ui/accessibility/ax_tree.h"
59 #include "url/gurl.h" 60 #include "url/gurl.h"
60 61
61 #if defined(OS_MACOSX) 62 #if defined(OS_MACOSX)
62 #include "content/browser/frame_host/popup_menu_helper_mac.h" 63 #include "content/browser/frame_host/popup_menu_helper_mac.h"
(...skipping 1309 matching lines...) Expand 10 before | Expand all | Expand 10 after
1372 if (is_waiting && dialog_was_suppressed) 1373 if (is_waiting && dialog_was_suppressed)
1373 render_view_host_->delegate_->RendererUnresponsive(render_view_host_); 1374 render_view_host_->delegate_->RendererUnresponsive(render_view_host_);
1374 } 1375 }
1375 1376
1376 void RenderFrameHostImpl::NotificationClosed(int notification_id) { 1377 void RenderFrameHostImpl::NotificationClosed(int notification_id) {
1377 cancel_notification_callbacks_.erase(notification_id); 1378 cancel_notification_callbacks_.erase(notification_id);
1378 } 1379 }
1379 1380
1380 // PlzNavigate 1381 // PlzNavigate
1381 void RenderFrameHostImpl::CommitNavigation( 1382 void RenderFrameHostImpl::CommitNavigation(
1382 const GURL& stream_url, 1383 ResourceResponse* response,
1384 scoped_ptr<StreamHandle> body,
1383 const CommonNavigationParams& common_params, 1385 const CommonNavigationParams& common_params,
1384 const CommitNavigationParams& commit_params) { 1386 const CommitNavigationParams& commit_params) {
1385 // TODO(clamy): Check if we have to add security checks for the browser plugin 1387 // TODO(clamy): Check if we have to add security checks for the browser plugin
1386 // guests. 1388 // guests.
1387 1389
1388 Send(new FrameMsg_CommitNavigation( 1390 Send(new FrameMsg_CommitNavigation(
1389 routing_id_, stream_url, common_params, commit_params)); 1391 routing_id_, response->head, body->GetURL(),
1392 common_params, commit_params));
1390 // TODO(clamy): Check if we should start the throbber for non javascript urls 1393 // TODO(clamy): Check if we should start the throbber for non javascript urls
1391 // here. 1394 // here.
1395
1396 // TODO(davidben): Retain |body| on behalf of the renderer, until the renderer
1397 // is done with it.
1392 } 1398 }
1393 1399
1394 void RenderFrameHostImpl::PlatformNotificationPermissionRequestDone( 1400 void RenderFrameHostImpl::PlatformNotificationPermissionRequestDone(
1395 int request_id, blink::WebNotificationPermission permission) { 1401 int request_id, blink::WebNotificationPermission permission) {
1396 Send(new PlatformNotificationMsg_PermissionRequestComplete( 1402 Send(new PlatformNotificationMsg_PermissionRequestComplete(
1397 routing_id_, request_id, permission)); 1403 routing_id_, request_id, permission));
1398 } 1404 }
1399 1405
1400 void RenderFrameHostImpl::UpdateCrossProcessIframeAccessibility( 1406 void RenderFrameHostImpl::UpdateCrossProcessIframeAccessibility(
1401 const std::map<int32, int> node_to_frame_routing_id_map) { 1407 const std::map<int32, int> node_to_frame_routing_id_map) {
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
1541 // Clear any state if a pending navigation is canceled or preempted. 1547 // Clear any state if a pending navigation is canceled or preempted.
1542 if (suspended_nav_params_) 1548 if (suspended_nav_params_)
1543 suspended_nav_params_.reset(); 1549 suspended_nav_params_.reset();
1544 1550
1545 TRACE_EVENT_ASYNC_END0("navigation", 1551 TRACE_EVENT_ASYNC_END0("navigation",
1546 "RenderFrameHostImpl navigation suspended", this); 1552 "RenderFrameHostImpl navigation suspended", this);
1547 navigations_suspended_ = false; 1553 navigations_suspended_ = false;
1548 } 1554 }
1549 1555
1550 } // namespace content 1556 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/frame_host/render_frame_host_impl.h ('k') | content/browser/frame_host/render_frame_host_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698