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

Side by Side Diff: chrome/browser/prerender/prerender_contents.cc

Issue 10553029: Handle interface to prerenders. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: lose two friends Created 8 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/prerender/prerender_contents.h" 5 #include "chrome/browser/prerender/prerender_contents.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <functional>
8 #include <utility> 9 #include <utility>
9 10
10 #include "base/process_util.h" 11 #include "base/process_util.h"
11 #include "base/utf_string_conversions.h" 12 #include "base/utf_string_conversions.h"
12 #include "chrome/browser/history/history_tab_helper.h" 13 #include "chrome/browser/history/history_tab_helper.h"
13 #include "chrome/browser/history/history_types.h" 14 #include "chrome/browser/history/history_types.h"
14 #include "chrome/browser/prerender/prerender_final_status.h" 15 #include "chrome/browser/prerender/prerender_final_status.h"
16 #include "chrome/browser/prerender/prerender_handle.h"
15 #include "chrome/browser/prerender/prerender_manager.h" 17 #include "chrome/browser/prerender/prerender_manager.h"
16 #include "chrome/browser/prerender/prerender_render_view_host_observer.h" 18 #include "chrome/browser/prerender/prerender_render_view_host_observer.h"
17 #include "chrome/browser/prerender/prerender_tracker.h" 19 #include "chrome/browser/prerender/prerender_tracker.h"
18 #include "chrome/browser/profiles/profile.h" 20 #include "chrome/browser/profiles/profile.h"
19 #include "chrome/browser/ui/tab_contents/tab_contents.h" 21 #include "chrome/browser/ui/tab_contents/tab_contents.h"
20 #include "chrome/common/chrome_notification_types.h" 22 #include "chrome/common/chrome_notification_types.h"
21 #include "chrome/common/icon_messages.h" 23 #include "chrome/common/icon_messages.h"
22 #include "chrome/common/prerender_messages.h" 24 #include "chrome/common/prerender_messages.h"
23 #include "chrome/common/url_constants.h" 25 #include "chrome/common/url_constants.h"
24 #include "content/public/browser/resource_request_details.h" 26 #include "content/public/browser/resource_request_details.h"
25 #include "content/public/browser/browser_child_process_host.h" 27 #include "content/public/browser/browser_child_process_host.h"
26 #include "content/public/browser/notification_service.h" 28 #include "content/public/browser/notification_service.h"
27 #include "content/public/browser/render_process_host.h" 29 #include "content/public/browser/render_process_host.h"
28 #include "content/public/browser/render_view_host.h" 30 #include "content/public/browser/render_view_host.h"
29 #include "content/public/browser/web_contents.h" 31 #include "content/public/browser/web_contents.h"
30 #include "content/public/browser/web_contents_delegate.h" 32 #include "content/public/browser/web_contents_delegate.h"
31 #include "content/public/browser/web_contents_view.h" 33 #include "content/public/browser/web_contents_view.h"
32 #include "ui/gfx/rect.h" 34 #include "ui/gfx/rect.h"
33 35
34 using content::DownloadItem; 36 using content::DownloadItem;
35 using content::OpenURLParams; 37 using content::OpenURLParams;
36 using content::RenderViewHost; 38 using content::RenderViewHost;
37 using content::ResourceRedirectDetails; 39 using content::ResourceRedirectDetails;
40 using content::SessionStorageNamespace;
38 using content::WebContents; 41 using content::WebContents;
39 42
40 namespace prerender { 43 namespace prerender {
41 44
42 namespace { 45 namespace {
43 46
44 // Compares URLs ignoring any ref for the purposes of matching URLs when
45 // prerendering.
46 struct PrerenderURLPredicate {
47 explicit PrerenderURLPredicate(const GURL& url)
48 : url_(url) {
49 }
50
51 bool operator()(const GURL& url) const {
52 return url.scheme() == url_.scheme() &&
53 url.host() == url_.host() &&
54 url.port() == url_.port() &&
55 url.path() == url_.path() &&
56 url.query() == url_.query();
57 }
58 GURL url_;
59 };
60
61 // Tells the render process at |child_id| whether |url| is a new prerendered 47 // Tells the render process at |child_id| whether |url| is a new prerendered
62 // page, or whether |url| is being removed as a prerendered page. Currently 48 // page, or whether |url| is being removed as a prerendered page. Currently
63 // this will only inform the render process that created the prerendered page 49 // this will only inform the render process that created the prerendered page
64 // with <link rel="prerender"> tags about it. This means that if the user 50 // with <link rel="prerender"> tags about it. This means that if the user
65 // clicks on a link for a prerendered URL in a different page, the prerender 51 // clicks on a link for a prerendered URL in a different page, the prerender
66 // will not be swapped in. 52 // will not be swapped in.
67 void InformRenderProcessAboutPrerender(const GURL& url, 53 void InformRenderProcessAboutPrerender(const GURL& url,
68 bool is_add, 54 bool is_add,
69 int child_id) { 55 int child_id) {
70 if (child_id < 0) 56 if (child_id < 0)
(...skipping 16 matching lines...) Expand all
87 public: 73 public:
88 virtual PrerenderContents* CreatePrerenderContents( 74 virtual PrerenderContents* CreatePrerenderContents(
89 PrerenderManager* prerender_manager, PrerenderTracker* prerender_tracker, 75 PrerenderManager* prerender_manager, PrerenderTracker* prerender_tracker,
90 Profile* profile, const GURL& url, const content::Referrer& referrer, 76 Profile* profile, const GURL& url, const content::Referrer& referrer,
91 Origin origin, uint8 experiment_id) OVERRIDE { 77 Origin origin, uint8 experiment_id) OVERRIDE {
92 return new PrerenderContents(prerender_manager, prerender_tracker, profile, 78 return new PrerenderContents(prerender_manager, prerender_tracker, profile,
93 url, referrer, origin, experiment_id); 79 url, referrer, origin, experiment_id);
94 } 80 }
95 }; 81 };
96 82
97 struct PrerenderContents::PendingPrerenderInfo {
98 PendingPrerenderInfo(const GURL& url,
99 const content::Referrer& referrer,
100 const gfx::Size& size);
101 const GURL url;
102 const content::Referrer referrer;
103 const gfx::Size size;
104 };
105
106 PrerenderContents::PendingPrerenderInfo::PendingPrerenderInfo(
107 const GURL& url,
108 const content::Referrer& referrer,
109 const gfx::Size& size)
110 : url(url),
111 referrer(referrer),
112 size(size) {
113 }
114
115 // TabContentsDelegateImpl ----------------------------------------------------- 83 // TabContentsDelegateImpl -----------------------------------------------------
116 84
117 class PrerenderContents::TabContentsDelegateImpl 85 class PrerenderContents::TabContentsDelegateImpl
118 : public content::WebContentsDelegate { 86 : public content::WebContentsDelegate {
119 public: 87 public:
120 explicit TabContentsDelegateImpl(PrerenderContents* prerender_contents) : 88 explicit TabContentsDelegateImpl(PrerenderContents* prerender_contents) :
121 prerender_contents_(prerender_contents) { 89 prerender_contents_(prerender_contents) {
122 } 90 }
123 91
124 // content::WebContentsDelegate implementation: 92 // content::WebContentsDelegate implementation:
125 virtual WebContents* OpenURLFromTab(WebContents* source, 93 virtual WebContents* OpenURLFromTab(WebContents* source,
126 const OpenURLParams& params) OVERRIDE { 94 const OpenURLParams& params) OVERRIDE {
127 // |OpenURLFromTab| is typically called when a frame performs a navigation 95 // |OpenURLFromTab| is typically called when a frame performs a navigation
128 // that requires the browser to perform the transition instead of WebKit. 96 // that requires the browser to perform the transition instead of WebKit.
129 // Examples include prerendering a site that redirects to an app URL, 97 // Examples include prerendering a site that redirects to an app URL,
130 // or if --enable-strict-site-isolation is specified and the prerendered 98 // or if --enable-strict-site-isolation is specified and the prerendered
131 // frame redirects to a different origin. 99 // frame redirects to a different origin.
132 // TODO(cbentzel): Consider supporting this if it is a common case during 100 // TODO(cbentzel): Consider supporting this if it is a common case during
133 // prerenders. 101 // prerenders.
134 prerender_contents_->Destroy(FINAL_STATUS_OPEN_URL); 102 prerender_contents_->Destroy(FINAL_STATUS_OPEN_URL);
135 return NULL; 103 return NULL;
136 } 104 }
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 private: 180 private:
213 typedef std::vector<scoped_refptr<history::HistoryAddPageArgs> > 181 typedef std::vector<scoped_refptr<history::HistoryAddPageArgs> >
214 AddPageVector; 182 AddPageVector;
215 183
216 // Caches pages to be added to the history. 184 // Caches pages to be added to the history.
217 AddPageVector add_page_vector_; 185 AddPageVector add_page_vector_;
218 186
219 PrerenderContents* prerender_contents_; 187 PrerenderContents* prerender_contents_;
220 }; 188 };
221 189
222 void PrerenderContents::AddPendingPrerender(const GURL& url, 190 void PrerenderContents::AddPendingPrerender(
223 const content::Referrer& referrer, 191 const base::WeakPtr<PrerenderHandle> weak_prerender_handle,
224 const gfx::Size& size) { 192 const GURL& url,
225 pending_prerender_list_.push_back(PendingPrerenderInfo(url, referrer, size)); 193 const content::Referrer& referrer,
194 const gfx::Size& size) {
195 pending_prerenders_.push_back(
196 PendingPrerenderInfo(weak_prerender_handle, url, referrer, size));
226 } 197 }
227 198
228 bool PrerenderContents::IsPendingEntry(const GURL& url) const { 199 bool PrerenderContents::IsPendingEntry(
229 for (PendingPrerenderList::const_iterator it = 200 const PrerenderHandle& prerender_handle) const {
230 pending_prerender_list_.begin(); 201 for (std::vector<PendingPrerenderInfo>::const_iterator it =
231 it != pending_prerender_list_.end(); 202 pending_prerenders_.begin();
203 it != pending_prerenders_.end();
232 ++it) { 204 ++it) {
233 if (it->url == url) 205 if (it->weak_prerender_handle.get() == &prerender_handle)
234 return true; 206 return true;
235 } 207 }
236 return false; 208 return false;
237 } 209 }
238 210
239 void PrerenderContents::StartPendingPrerenders() { 211 void PrerenderContents::StartPendingPrerenders() {
240 PendingPrerenderList pending_prerender_list; 212 SessionStorageNamespace* session_storage_namespace = NULL;
241 pending_prerender_list.swap(pending_prerender_list_); 213 if (RenderViewHost* render_view_host = GetRenderViewHostMutable())
242 for (PendingPrerenderList::iterator it = pending_prerender_list.begin(); 214 session_storage_namespace = render_view_host->GetSessionStorageNamespace();
215 DCHECK(child_id_ == -1 || session_storage_namespace);
216
217 std::vector<PendingPrerenderInfo> pending_prerender_list;
218 pending_prerender_list.swap(pending_prerenders_);
219 for (std::vector<PendingPrerenderInfo>::iterator it =
220 pending_prerender_list.begin();
243 it != pending_prerender_list.end(); 221 it != pending_prerender_list.end();
244 ++it) { 222 ++it) {
245 prerender_manager_->AddPrerenderFromLinkRelPrerender( 223 if (it->weak_prerender_handle && it->weak_prerender_handle->IsValid()) {
246 child_id_, route_id_, it->url, it->referrer, it->size); 224 prerender_manager_->StartPendingPrerender(
225 it->weak_prerender_handle.get(), ORIGIN_LINK_REL_PRERENDER, child_id_,
226 it->url, it->referrer, it->size, session_storage_namespace);
227 }
247 } 228 }
248 } 229 }
249 230
231 PrerenderContents::PendingPrerenderInfo::PendingPrerenderInfo(
232 const base::WeakPtr<PrerenderHandle> weak_prerender_handle,
233 const GURL& url,
234 const content::Referrer& referrer,
235 const gfx::Size& size)
236 : weak_prerender_handle(weak_prerender_handle),
237 url(url),
238 referrer(referrer),
239 size(size) {
240 }
241
242 PrerenderContents::PendingPrerenderInfo::~PendingPrerenderInfo() {
243 }
244
250 PrerenderContents::PrerenderContents( 245 PrerenderContents::PrerenderContents(
251 PrerenderManager* prerender_manager, 246 PrerenderManager* prerender_manager,
252 PrerenderTracker* prerender_tracker, 247 PrerenderTracker* prerender_tracker,
253 Profile* profile, 248 Profile* profile,
254 const GURL& url, 249 const GURL& url,
255 const content::Referrer& referrer, 250 const content::Referrer& referrer,
256 Origin origin, 251 Origin origin,
257 uint8 experiment_id) 252 uint8 experiment_id)
258 : prerendering_has_started_(false), 253 : prerendering_has_started_(false),
259 prerender_manager_(prerender_manager), 254 prerender_manager_(prerender_manager),
260 prerender_tracker_(prerender_tracker), 255 prerender_tracker_(prerender_tracker),
261 prerender_url_(url), 256 prerender_url_(url),
262 referrer_(referrer), 257 referrer_(referrer),
263 profile_(profile), 258 profile_(profile),
264 page_id_(0), 259 page_id_(0),
260 session_storage_namespace_(NULL),
265 has_stopped_loading_(false), 261 has_stopped_loading_(false),
266 has_finished_loading_(false), 262 has_finished_loading_(false),
267 final_status_(FINAL_STATUS_MAX), 263 final_status_(FINAL_STATUS_MAX),
268 match_complete_status_(MATCH_COMPLETE_DEFAULT), 264 match_complete_status_(MATCH_COMPLETE_DEFAULT),
269 prerendering_has_been_cancelled_(false), 265 prerendering_has_been_cancelled_(false),
270 child_id_(-1), 266 child_id_(-1),
271 route_id_(-1), 267 route_id_(-1),
272 origin_(origin), 268 origin_(origin),
273 experiment_id_(experiment_id), 269 experiment_id_(experiment_id),
274 creator_child_id_(-1) { 270 creator_child_id_(-1) {
275 DCHECK(prerender_manager != NULL); 271 DCHECK(prerender_manager != NULL);
276 } 272 }
277 273
274 void PrerenderContents::MakeIntoDummyReplacementOf(
275 const PrerenderContents* original_prerender_contents) {
276 load_start_time_ = original_prerender_contents->load_start_time_;
277 session_storage_namespace_ =
278 original_prerender_contents->session_storage_namespace_;
279 }
280
278 bool PrerenderContents::Init() { 281 bool PrerenderContents::Init() {
279 return AddAliasURL(prerender_url_); 282 return AddAliasURL(prerender_url_);
280 } 283 }
281 284
282 // static 285 // static
283 PrerenderContents::Factory* PrerenderContents::CreateFactory() { 286 PrerenderContents::Factory* PrerenderContents::CreateFactory() {
284 return new PrerenderContentsFactoryImpl(); 287 return new PrerenderContentsFactoryImpl();
285 } 288 }
286 289
287 void PrerenderContents::StartPrerendering( 290 void PrerenderContents::StartPrerendering(
288 int creator_child_id, 291 int creator_child_id,
289 const gfx::Size& size, 292 const gfx::Size& size,
290 content::SessionStorageNamespace* session_storage_namespace, 293 SessionStorageNamespace* session_storage_namespace,
291 bool is_control_group) { 294 bool is_control_group) {
292 DCHECK(profile_ != NULL); 295 DCHECK(profile_ != NULL);
293 DCHECK(!size.IsEmpty()); 296 DCHECK(!size.IsEmpty());
294 DCHECK(!prerendering_has_started_); 297 DCHECK(!prerendering_has_started_);
295 DCHECK(prerender_contents_.get() == NULL); 298 DCHECK(prerender_contents_.get() == NULL);
296 DCHECK_EQ(-1, creator_child_id_); 299 DCHECK_EQ(-1, creator_child_id_);
297 DCHECK(size_.IsEmpty()); 300 DCHECK(size_.IsEmpty());
298 DCHECK_EQ(1U, alias_urls_.size()); 301 DCHECK_EQ(1U, alias_urls_.size());
299 302
300 creator_child_id_ = creator_child_id; 303 creator_child_id_ = creator_child_id;
304 session_storage_namespace_ = session_storage_namespace;
mmenke 2012/07/11 18:40:05 I'm still concerned about this, since it makes the
gavinp 2012/07/11 21:19:30 Done. This was one of your most important comments
301 size_ = size; 305 size_ = size;
302 306
303 InformRenderProcessAboutPrerender(prerender_url_, true, 307 InformRenderProcessAboutPrerender(prerender_url_, true,
304 creator_child_id_); 308 creator_child_id_);
305 309
310 DCHECK(load_start_time_.is_null());
311 load_start_time_ = base::TimeTicks::Now();
312
306 // Everything after this point sets up the WebContents object and associated 313 // Everything after this point sets up the WebContents object and associated
307 // RenderView for the prerender page. Don't do this for members of the 314 // RenderView for the prerender page. Don't do this for members of the
308 // control group. 315 // control group.
309 if (is_control_group) 316 if (is_control_group)
310 return; 317 return;
311 318
312 prerendering_has_started_ = true; 319 prerendering_has_started_ = true;
313 320
314 WebContents* new_contents = CreateWebContents(session_storage_namespace); 321 WebContents* new_contents = CreateWebContents(session_storage_namespace);
315 prerender_contents_.reset(new TabContents(new_contents)); 322 prerender_contents_.reset(new TabContents(new_contents));
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
351 // Register to inform new RenderViews that we're prerendering. 358 // Register to inform new RenderViews that we're prerendering.
352 notification_registrar_.Add( 359 notification_registrar_.Add(
353 this, content::NOTIFICATION_RENDER_VIEW_HOST_CREATED_FOR_TAB, 360 this, content::NOTIFICATION_RENDER_VIEW_HOST_CREATED_FOR_TAB,
354 content::Source<WebContents>(new_contents)); 361 content::Source<WebContents>(new_contents));
355 362
356 // Register for redirect notifications sourced from |this|. 363 // Register for redirect notifications sourced from |this|.
357 notification_registrar_.Add( 364 notification_registrar_.Add(
358 this, content::NOTIFICATION_RESOURCE_RECEIVED_REDIRECT, 365 this, content::NOTIFICATION_RESOURCE_RECEIVED_REDIRECT,
359 content::Source<WebContents>(GetWebContents())); 366 content::Source<WebContents>(GetWebContents()));
360 367
361 DCHECK(load_start_time_.is_null());
362 load_start_time_ = base::TimeTicks::Now();
363
364 // Transfer over the user agent override. 368 // Transfer over the user agent override.
365 new_contents->SetUserAgentOverride( 369 new_contents->SetUserAgentOverride(
366 prerender_manager_->config().user_agent_override); 370 prerender_manager_->config().user_agent_override);
367 371
368 new_contents->GetController().LoadURLWithUserAgentOverride( 372 new_contents->GetController().LoadURLWithUserAgentOverride(
369 prerender_url_, 373 prerender_url_,
370 referrer_, 374 referrer_,
371 (origin_ == ORIGIN_OMNIBOX ? content::PAGE_TRANSITION_TYPED : 375 (origin_ == ORIGIN_OMNIBOX ? content::PAGE_TRANSITION_TYPED :
372 content::PAGE_TRANSITION_LINK), 376 content::PAGE_TRANSITION_LINK),
373 false, 377 false,
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
487 NOTREACHED() << "Unexpected notification sent."; 491 NOTREACHED() << "Unexpected notification sent.";
488 break; 492 break;
489 } 493 }
490 } 494 }
491 495
492 void PrerenderContents::OnRenderViewHostCreated( 496 void PrerenderContents::OnRenderViewHostCreated(
493 RenderViewHost* new_render_view_host) { 497 RenderViewHost* new_render_view_host) {
494 } 498 }
495 499
496 WebContents* PrerenderContents::CreateWebContents( 500 WebContents* PrerenderContents::CreateWebContents(
497 content::SessionStorageNamespace* session_storage_namespace) { 501 SessionStorageNamespace* session_storage_namespace) {
498 return WebContents::Create(profile_, NULL, MSG_ROUTING_NONE, NULL, 502 return WebContents::Create(profile_, NULL, MSG_ROUTING_NONE, NULL,
499 session_storage_namespace); 503 session_storage_namespace);
500 } 504 }
501 505
502 void PrerenderContents::OnUpdateFaviconURL( 506 void PrerenderContents::OnUpdateFaviconURL(
503 int32 page_id, 507 int32 page_id,
504 const std::vector<FaviconURL>& urls) { 508 const std::vector<FaviconURL>& urls) {
505 VLOG(1) << "PrerenderContents::OnUpdateFaviconURL" << icon_url_; 509 VLOG(1) << "PrerenderContents::OnUpdateFaviconURL" << icon_url_;
506 for (std::vector<FaviconURL>::const_iterator it = urls.begin(); 510 for (std::vector<FaviconURL>::const_iterator it = urls.begin();
507 it != urls.end(); ++it) { 511 it != urls.end(); ++it) {
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
539 543
540 void PrerenderContents::AddAliasURLsFromOtherPrerenderContents( 544 void PrerenderContents::AddAliasURLsFromOtherPrerenderContents(
541 PrerenderContents* other_pc) { 545 PrerenderContents* other_pc) {
542 for (std::vector<GURL>::const_iterator it = other_pc->alias_urls_.begin(); 546 for (std::vector<GURL>::const_iterator it = other_pc->alias_urls_.begin();
543 it != other_pc->alias_urls_.end(); 547 it != other_pc->alias_urls_.end();
544 ++it) { 548 ++it) {
545 alias_urls_.push_back(*it); 549 alias_urls_.push_back(*it);
546 } 550 }
547 } 551 }
548 552
549 bool PrerenderContents::MatchesURL(const GURL& url, GURL* matching_url) const { 553 bool PrerenderContents::Matches(
550 std::vector<GURL>::const_iterator matching_url_iterator = 554 const GURL& url,
551 std::find_if(alias_urls_.begin(), 555 const SessionStorageNamespace* session_storage_namespace) {
552 alias_urls_.end(), 556 if (session_storage_namespace_ != session_storage_namespace)
553 PrerenderURLPredicate(url)); 557 return false;
554 if (matching_url_iterator != alias_urls_.end()) { 558 return std::count_if(alias_urls_.begin(), alias_urls_.end(),
555 if (matching_url) 559 std::bind2nd(std::equal_to<GURL>(), url)) != 0;
556 *matching_url = *matching_url_iterator;
557 return true;
558 }
559 return false;
560 } 560 }
561 561
562 void PrerenderContents::RenderViewGone(base::TerminationStatus status) { 562 void PrerenderContents::RenderViewGone(base::TerminationStatus status) {
563 Destroy(FINAL_STATUS_RENDERER_CRASHED); 563 Destroy(FINAL_STATUS_RENDERER_CRASHED);
564 } 564 }
565 565
566 void PrerenderContents::DidStopLoading() { 566 void PrerenderContents::DidStopLoading() {
567 has_stopped_loading_ = true; 567 has_stopped_loading_ = true;
568 } 568 }
569 569
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
702 bool PrerenderContents::IsCrossSiteNavigationPending() const { 702 bool PrerenderContents::IsCrossSiteNavigationPending() const {
703 if (!prerender_contents_.get() || !prerender_contents_->web_contents()) 703 if (!prerender_contents_.get() || !prerender_contents_->web_contents())
704 return false; 704 return false;
705 const WebContents* web_contents = prerender_contents_->web_contents(); 705 const WebContents* web_contents = prerender_contents_->web_contents();
706 return (web_contents->GetSiteInstance() != 706 return (web_contents->GetSiteInstance() !=
707 web_contents->GetPendingSiteInstance()); 707 web_contents->GetPendingSiteInstance());
708 } 708 }
709 709
710 710
711 } // namespace prerender 711 } // namespace prerender
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698