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

Unified Diff: chrome/test/data/webui/net_internals/prerender_view.js

Issue 16194008: about:net-internals#prerender: Add information about load state of prerender (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Fix comment Created 7 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/test/data/webui/net_internals/prerender_view.js
===================================================================
--- chrome/test/data/webui/net_internals/prerender_view.js (revision 201078)
+++ chrome/test/data/webui/net_internals/prerender_view.js (working copy)
@@ -98,6 +98,10 @@
if (this.state_ == STATE.START_PRERENDERING) {
this.startPrerendering_(prerenderInfo);
} else if (this.state_ == STATE.NEED_NAVIGATE) {
+ // Can't safely swap in a prerender until the main frame has committed.
+ // Waiting until the load has completed isn't necessary, but it's simpler.
+ if (!prerenderInfo.active[0].is_loaded)
eroman 2013/05/29 16:45:38 is it a given that active[0] exists?
mmenke 2013/05/29 17:11:28 Yes. The first call to this function is when ther
+ return;
this.navigate_(prerenderInfo);
} else if (this.state_ == STATE.HISTORY_WAIT) {
this.checkDone_(prerenderInfo);

Powered by Google App Engine
This is Rietveld 408576698