| 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 585 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 596 if (result != NavigationThrottle::DEFER) | 596 if (result != NavigationThrottle::DEFER) |
| 597 RunCompleteCallback(result); | 597 RunCompleteCallback(result); |
| 598 } | 598 } |
| 599 | 599 |
| 600 void NavigationHandleImpl::ReadyToCommitNavigation( | 600 void NavigationHandleImpl::ReadyToCommitNavigation( |
| 601 RenderFrameHostImpl* render_frame_host) { | 601 RenderFrameHostImpl* render_frame_host) { |
| 602 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); | 602 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); |
| 603 render_frame_host_ = render_frame_host; | 603 render_frame_host_ = render_frame_host; |
| 604 state_ = READY_TO_COMMIT; | 604 state_ = READY_TO_COMMIT; |
| 605 | 605 |
| 606 if (!IsRendererDebugURL(url_)) | 606 if (!IsRendererDebugURL(url_) && !IsSamePage()) |
| 607 GetDelegate()->ReadyToCommitNavigation(this); | 607 GetDelegate()->ReadyToCommitNavigation(this); |
| 608 } | 608 } |
| 609 | 609 |
| 610 void NavigationHandleImpl::DidCommitNavigation( | 610 void NavigationHandleImpl::DidCommitNavigation( |
| 611 const FrameHostMsg_DidCommitProvisionalLoad_Params& params, | 611 const FrameHostMsg_DidCommitProvisionalLoad_Params& params, |
| 612 bool did_replace_entry, | 612 bool did_replace_entry, |
| 613 const GURL& previous_url, | 613 const GURL& previous_url, |
| 614 RenderFrameHostImpl* render_frame_host) { | 614 RenderFrameHostImpl* render_frame_host) { |
| 615 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); | 615 DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host); |
| 616 DCHECK_EQ(frame_tree_node_, render_frame_host->frame_tree_node()); | 616 DCHECK_EQ(frame_tree_node_, render_frame_host->frame_tree_node()); |
| (...skipping 262 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 879 content::AncestorThrottle::MaybeCreateThrottleFor(this); | 879 content::AncestorThrottle::MaybeCreateThrottleFor(this); |
| 880 if (ancestor_throttle) | 880 if (ancestor_throttle) |
| 881 throttles_.push_back(std::move(ancestor_throttle)); | 881 throttles_.push_back(std::move(ancestor_throttle)); |
| 882 | 882 |
| 883 throttles_.insert(throttles_.begin(), | 883 throttles_.insert(throttles_.begin(), |
| 884 std::make_move_iterator(throttles_to_register.begin()), | 884 std::make_move_iterator(throttles_to_register.begin()), |
| 885 std::make_move_iterator(throttles_to_register.end())); | 885 std::make_move_iterator(throttles_to_register.end())); |
| 886 } | 886 } |
| 887 | 887 |
| 888 } // namespace content | 888 } // namespace content |
| OLD | NEW |