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 518 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
529 if (result != NavigationThrottle::DEFER) | 529 if (result != NavigationThrottle::DEFER) |
530 RunCompleteCallback(result); | 530 RunCompleteCallback(result); |
531 } | 531 } |
532 | 532 |
533 void NavigationHandleImpl::ReadyToCommitNavigation( | 533 void NavigationHandleImpl::ReadyToCommitNavigation( |
534 RenderFrameHostImpl* render_frame_host) { | 534 RenderFrameHostImpl* render_frame_host) { |
535 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); | 535 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); |
536 render_frame_host_ = render_frame_host; | 536 render_frame_host_ = render_frame_host; |
537 state_ = READY_TO_COMMIT; | 537 state_ = READY_TO_COMMIT; |
538 | 538 |
539 if (!IsRendererDebugURL(url_)) | 539 if (!IsRendererDebugURL(url_) && !IsSamePage()) |
540 GetDelegate()->ReadyToCommitNavigation(this); | 540 GetDelegate()->ReadyToCommitNavigation(this); |
541 } | 541 } |
542 | 542 |
543 void NavigationHandleImpl::DidCommitNavigation( | 543 void NavigationHandleImpl::DidCommitNavigation( |
544 const FrameHostMsg_DidCommitProvisionalLoad_Params& params, | 544 const FrameHostMsg_DidCommitProvisionalLoad_Params& params, |
545 bool same_page, | 545 bool same_page, |
546 RenderFrameHostImpl* render_frame_host) { | 546 RenderFrameHostImpl* render_frame_host) { |
547 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); | 547 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); |
548 DCHECK_EQ(frame_tree_node_, render_frame_host->frame_tree_node()); | 548 DCHECK_EQ(frame_tree_node_, render_frame_host->frame_tree_node()); |
549 CHECK_EQ(url_, params.url); | 549 CHECK_EQ(url_, params.url); |
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
806 content::AncestorThrottle::MaybeCreateThrottleFor(this); | 806 content::AncestorThrottle::MaybeCreateThrottleFor(this); |
807 if (ancestor_throttle) | 807 if (ancestor_throttle) |
808 throttles_.push_back(std::move(ancestor_throttle)); | 808 throttles_.push_back(std::move(ancestor_throttle)); |
809 | 809 |
810 throttles_.insert(throttles_.begin(), | 810 throttles_.insert(throttles_.begin(), |
811 std::make_move_iterator(throttles_to_register.begin()), | 811 std::make_move_iterator(throttles_to_register.begin()), |
812 std::make_move_iterator(throttles_to_register.end())); | 812 std::make_move_iterator(throttles_to_register.end())); |
813 } | 813 } |
814 | 814 |
815 } // namespace content | 815 } // namespace content |
OLD | NEW |