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

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

Issue 483773002: PlzNavigate: implement CommitNavigation on the browser side (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added a unit test for the reload case Created 6 years, 3 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 1179 matching lines...) Expand 10 before | Expand all | Expand 10 after
1190 render_view_host_->delegate_->RendererUnresponsive( 1190 render_view_host_->delegate_->RendererUnresponsive(
1191 render_view_host_, 1191 render_view_host_,
1192 render_view_host_->is_waiting_for_beforeunload_ack(), 1192 render_view_host_->is_waiting_for_beforeunload_ack(),
1193 render_view_host_->IsWaitingForUnloadACK()); 1193 render_view_host_->IsWaitingForUnloadACK());
1194 } 1194 }
1195 1195
1196 void RenderFrameHostImpl::NotificationClosed(int notification_id) { 1196 void RenderFrameHostImpl::NotificationClosed(int notification_id) {
1197 cancel_notification_callbacks_.erase(notification_id); 1197 cancel_notification_callbacks_.erase(notification_id);
1198 } 1198 }
1199 1199
1200 // PlzNavigate
1201 void RenderFrameHostImpl::CommitNavigation(
1202 const FrameMsg_CommitNavigation_Params& params) {
1203 // TODO(clamy): Check if we have to add security checks for the browser plugin
1204 // guests.
1205
1206 // Get back to a clean state, in case we start a new navigation without
1207 // completing a RVH swap or unload handler.
1208 render_view_host_->SetState(RenderViewHostImpl::STATE_DEFAULT);
(Do not use) nasko 2014/08/28 16:39:08 Setting this unconditionally can be problematic. W
clamy 2014/09/02 18:25:19 Done.
1209 Send(new FrameMsg_CommitNavigation(routing_id_, params));
1210 // TODO(clamy): Check if we have to be concerned about throbbing javascript
1211 // urls.
1212 }
1213
1200 void RenderFrameHostImpl::PlatformNotificationPermissionRequestDone( 1214 void RenderFrameHostImpl::PlatformNotificationPermissionRequestDone(
1201 int request_id, blink::WebNotificationPermission permission) { 1215 int request_id, blink::WebNotificationPermission permission) {
1202 Send(new PlatformNotificationMsg_PermissionRequestComplete( 1216 Send(new PlatformNotificationMsg_PermissionRequestComplete(
1203 routing_id_, request_id, permission)); 1217 routing_id_, request_id, permission));
1204 } 1218 }
1205 1219
1206 void RenderFrameHostImpl::SetAccessibilityMode(AccessibilityMode mode) { 1220 void RenderFrameHostImpl::SetAccessibilityMode(AccessibilityMode mode) {
1207 Send(new FrameMsg_SetAccessibilityMode(routing_id_, mode)); 1221 Send(new FrameMsg_SetAccessibilityMode(routing_id_, mode));
1208 } 1222 }
1209 1223
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
1299 } 1313 }
1300 1314
1301 void RenderFrameHostImpl::CancelSuspendedNavigations() { 1315 void RenderFrameHostImpl::CancelSuspendedNavigations() {
1302 // Clear any state if a pending navigation is canceled or preempted. 1316 // Clear any state if a pending navigation is canceled or preempted.
1303 if (suspended_nav_params_) 1317 if (suspended_nav_params_)
1304 suspended_nav_params_.reset(); 1318 suspended_nav_params_.reset();
1305 navigations_suspended_ = false; 1319 navigations_suspended_ = false;
1306 } 1320 }
1307 1321
1308 } // namespace content 1322 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698