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

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

Issue 11788015: When starting a provisional load, indicate whether the provisional URL is about:srcdoc (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 11 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 <functional>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 540 matching lines...) Expand 10 before | Expand all | Expand 10 after
551 has_stopped_loading_ = true; 551 has_stopped_loading_ = true;
552 NotifyPrerenderStopLoading(); 552 NotifyPrerenderStopLoading();
553 } 553 }
554 554
555 void PrerenderContents::DidStartProvisionalLoadForFrame( 555 void PrerenderContents::DidStartProvisionalLoadForFrame(
556 int64 frame_id, 556 int64 frame_id,
557 int64 parent_frame_id, 557 int64 parent_frame_id,
558 bool is_main_frame, 558 bool is_main_frame,
559 const GURL& validated_url, 559 const GURL& validated_url,
560 bool is_error_page, 560 bool is_error_page,
561 bool is_iframe_srcdoc,
561 RenderViewHost* render_view_host) { 562 RenderViewHost* render_view_host) {
562 if (is_main_frame) { 563 if (is_main_frame) {
563 if (!AddAliasURL(validated_url)) 564 if (!AddAliasURL(validated_url))
564 return; 565 return;
565 566
566 // Usually, this event fires if the user clicks or enters a new URL. 567 // Usually, this event fires if the user clicks or enters a new URL.
567 // Neither of these can happen in the case of an invisible prerender. 568 // Neither of these can happen in the case of an invisible prerender.
568 // So the cause is: Some JavaScript caused a new URL to be loaded. In that 569 // So the cause is: Some JavaScript caused a new URL to be loaded. In that
569 // case, the spinner would start again in the browser, so we must reset 570 // case, the spinner would start again in the browser, so we must reset
570 // has_stopped_loading_ so that the spinner won't be stopped. 571 // has_stopped_loading_ so that the spinner won't be stopped.
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
695 696
696 bool PrerenderContents::IsCrossSiteNavigationPending() const { 697 bool PrerenderContents::IsCrossSiteNavigationPending() const {
697 if (!prerender_contents_) 698 if (!prerender_contents_)
698 return false; 699 return false;
699 return (prerender_contents_->GetSiteInstance() != 700 return (prerender_contents_->GetSiteInstance() !=
700 prerender_contents_->GetPendingSiteInstance()); 701 prerender_contents_->GetPendingSiteInstance());
701 } 702 }
702 703
703 704
704 } // namespace prerender 705 } // namespace prerender
OLDNEW
« no previous file with comments | « chrome/browser/prerender/prerender_contents.h ('k') | chrome/browser/prerender/prerender_tab_helper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698