OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/navigation_handle_impl.h" | 5 #include "content/browser/frame_host/navigation_handle_impl.h" |
6 | 6 |
7 #include <iterator> | 7 #include <iterator> |
8 | 8 |
9 #include "base/debug/dump_without_crashing.h" | 9 #include "base/debug/dump_without_crashing.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
553 if (result != NavigationThrottle::DEFER) | 553 if (result != NavigationThrottle::DEFER) |
554 RunCompleteCallback(result); | 554 RunCompleteCallback(result); |
555 } | 555 } |
556 | 556 |
557 void NavigationHandleImpl::ReadyToCommitNavigation( | 557 void NavigationHandleImpl::ReadyToCommitNavigation( |
558 RenderFrameHostImpl* render_frame_host) { | 558 RenderFrameHostImpl* render_frame_host) { |
559 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); | 559 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); |
560 render_frame_host_ = render_frame_host; | 560 render_frame_host_ = render_frame_host; |
561 state_ = READY_TO_COMMIT; | 561 state_ = READY_TO_COMMIT; |
562 | 562 |
563 if (!IsRendererDebugURL(url_)) | 563 if (!IsRendererDebugURL(url_) && !IsSamePage()) |
564 GetDelegate()->ReadyToCommitNavigation(this); | 564 GetDelegate()->ReadyToCommitNavigation(this); |
565 } | 565 } |
566 | 566 |
567 void NavigationHandleImpl::DidCommitNavigation( | 567 void NavigationHandleImpl::DidCommitNavigation( |
568 const FrameHostMsg_DidCommitProvisionalLoad_Params& params, | 568 const FrameHostMsg_DidCommitProvisionalLoad_Params& params, |
569 bool same_page, | 569 bool same_page, |
570 RenderFrameHostImpl* render_frame_host) { | 570 RenderFrameHostImpl* render_frame_host) { |
571 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); | 571 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); |
572 DCHECK_EQ(frame_tree_node_, render_frame_host->frame_tree_node()); | 572 DCHECK_EQ(frame_tree_node_, render_frame_host->frame_tree_node()); |
573 CHECK_EQ(url_, params.url); | 573 CHECK_EQ(url_, params.url); |
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
830 content::AncestorThrottle::MaybeCreateThrottleFor(this); | 830 content::AncestorThrottle::MaybeCreateThrottleFor(this); |
831 if (ancestor_throttle) | 831 if (ancestor_throttle) |
832 throttles_.push_back(std::move(ancestor_throttle)); | 832 throttles_.push_back(std::move(ancestor_throttle)); |
833 | 833 |
834 throttles_.insert(throttles_.begin(), | 834 throttles_.insert(throttles_.begin(), |
835 std::make_move_iterator(throttles_to_register.begin()), | 835 std::make_move_iterator(throttles_to_register.begin()), |
836 std::make_move_iterator(throttles_to_register.end())); | 836 std::make_move_iterator(throttles_to_register.end())); |
837 } | 837 } |
838 | 838 |
839 } // namespace content | 839 } // namespace content |
OLD | NEW |