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

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

Issue 1163303003: PlzNavigate: Create the speculative renderer earlier. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Minor changes from nako@'s review comments. Created 5 years, 6 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/frame_tree_node.h" 5 #include "content/browser/frame_host/frame_tree_node.h"
6 6
7 #include <queue> 7 #include <queue>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/profiler/scoped_tracker.h" 10 #include "base/profiler/scoped_tracker.h"
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
259 // the UI. Blink doesn't send throb notifications for JavaScript URLs, so it 259 // the UI. Blink doesn't send throb notifications for JavaScript URLs, so it
260 // is not done here either. 260 // is not done here either.
261 if (!navigation_request->common_params().url.SchemeIs( 261 if (!navigation_request->common_params().url.SchemeIs(
262 url::kJavaScriptScheme)) { 262 url::kJavaScriptScheme)) {
263 // TODO(fdegans): Check if this is a same-document navigation and set the 263 // TODO(fdegans): Check if this is a same-document navigation and set the
264 // proper argument. 264 // proper argument.
265 DidStartLoading(true); 265 DidStartLoading(true);
266 } 266 }
267 267
268 navigation_request_ = navigation_request.Pass(); 268 navigation_request_ = navigation_request.Pass();
269
270 render_manager()->DidCreateNavigationRequest(*navigation_request_);
269 } 271 }
270 272
271 void FrameTreeNode::ResetNavigationRequest(bool is_commit) { 273 void FrameTreeNode::ResetNavigationRequest(bool is_commit) {
272 CHECK(base::CommandLine::ForCurrentProcess()->HasSwitch( 274 CHECK(base::CommandLine::ForCurrentProcess()->HasSwitch(
273 switches::kEnableBrowserSideNavigation)); 275 switches::kEnableBrowserSideNavigation));
274 if (!navigation_request_) 276 if (!navigation_request_)
275 return; 277 return;
276 navigation_request_.reset(); 278 navigation_request_.reset();
277 279
278 // During commit, the clean up of a speculative RenderFrameHost is done in 280 // During commit, the clean up of a speculative RenderFrameHost is done in
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
347 FROM_HERE_WITH_EXPLICIT_FUNCTION( 349 FROM_HERE_WITH_EXPLICIT_FUNCTION(
348 "465796 FrameTreeNode::DidStopLoading::End")); 350 "465796 FrameTreeNode::DidStopLoading::End"));
349 } 351 }
350 352
351 void FrameTreeNode::DidChangeLoadProgress(double load_progress) { 353 void FrameTreeNode::DidChangeLoadProgress(double load_progress) {
352 loading_progress_ = load_progress; 354 loading_progress_ = load_progress;
353 frame_tree_->UpdateLoadProgress(); 355 frame_tree_->UpdateLoadProgress();
354 } 356 }
355 357
356 } // namespace content 358 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/frame_host/navigation_request.h » ('j') | content/browser/frame_host/navigation_request.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698