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

Side by Side Diff: content/browser/web_contents/web_contents_impl.cc

Issue 317703004: Simplify AreURLsInPageNavigation (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 | Annotate | Revision Log
« no previous file with comments | « content/browser/web_contents/web_contents_impl.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "content/browser/web_contents/web_contents_impl.h" 5 #include "content/browser/web_contents/web_contents_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/debug/trace_event.h" 10 #include "base/debug/trace_event.h"
(...skipping 2420 matching lines...) Expand 10 before | Expand all | Expand 10 after
2431 observers_, 2431 observers_,
2432 DidCommitProvisionalLoadForFrame(render_frame_id, 2432 DidCommitProvisionalLoadForFrame(render_frame_id,
2433 frame_unique_name, 2433 frame_unique_name,
2434 is_main_frame, 2434 is_main_frame,
2435 url, 2435 url,
2436 transition_type, 2436 transition_type,
2437 render_view_host)); 2437 render_view_host));
2438 } 2438 }
2439 2439
2440 void WebContentsImpl::DidNavigateMainFramePreCommit( 2440 void WebContentsImpl::DidNavigateMainFramePreCommit(
2441 const FrameHostMsg_DidCommitProvisionalLoad_Params& params) { 2441 bool navigation_is_within_page) {
2442 // Ensure fullscreen mode is exited before committing the navigation to a 2442 // Ensure fullscreen mode is exited before committing the navigation to a
2443 // different page. The next page will not start out assuming it is in 2443 // different page. The next page will not start out assuming it is in
2444 // fullscreen mode. 2444 // fullscreen mode.
2445 if (controller_.IsURLInPageNavigation(params.url, 2445 if (navigation_is_within_page) {
2446 params.was_within_same_page,
2447 NAVIGATION_TYPE_UNKNOWN)) {
2448 // No page change? Then, the renderer and browser can remain in fullscreen. 2446 // No page change? Then, the renderer and browser can remain in fullscreen.
2449 return; 2447 return;
2450 } 2448 }
2451 if (IsFullscreenForCurrentTab()) 2449 if (IsFullscreenForCurrentTab())
2452 GetRenderViewHost()->ExitFullscreen(); 2450 GetRenderViewHost()->ExitFullscreen();
2453 DCHECK(!IsFullscreenForCurrentTab()); 2451 DCHECK(!IsFullscreenForCurrentTab());
2454 } 2452 }
2455 2453
2456 void WebContentsImpl::DidNavigateMainFramePostCommit( 2454 void WebContentsImpl::DidNavigateMainFramePostCommit(
2457 const LoadCommittedDetails& details, 2455 const LoadCommittedDetails& details,
(...skipping 1642 matching lines...) Expand 10 before | Expand all | Expand 10 after
4100 if (new_size != old_size) 4098 if (new_size != old_size)
4101 delegate_->UpdatePreferredSize(this, new_size); 4099 delegate_->UpdatePreferredSize(this, new_size);
4102 } 4100 }
4103 4101
4104 void WebContentsImpl::ResumeResponseDeferredAtStart() { 4102 void WebContentsImpl::ResumeResponseDeferredAtStart() {
4105 FrameTreeNode* node = frame_tree_.root(); 4103 FrameTreeNode* node = frame_tree_.root();
4106 node->render_manager()->ResumeResponseDeferredAtStart(); 4104 node->render_manager()->ResumeResponseDeferredAtStart();
4107 } 4105 }
4108 4106
4109 } // namespace content 4107 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/web_contents/web_contents_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698