| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/renderer/render_frame_impl.h" | 5 #include "content/renderer/render_frame_impl.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 3492 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3503 DCHECK_EQ(frame_, frame); | 3503 DCHECK_EQ(frame_, frame); |
| 3504 // If this was a reference fragment navigation that we initiated, then we | 3504 // If this was a reference fragment navigation that we initiated, then we |
| 3505 // could end up having a non-null pending navigation params. We just need to | 3505 // could end up having a non-null pending navigation params. We just need to |
| 3506 // update the ExtraData on the datasource so that others who read the | 3506 // update the ExtraData on the datasource so that others who read the |
| 3507 // ExtraData will get the new NavigationState. Similarly, if we did not | 3507 // ExtraData will get the new NavigationState. Similarly, if we did not |
| 3508 // initiate this navigation, then we need to take care to reset any pre- | 3508 // initiate this navigation, then we need to take care to reset any pre- |
| 3509 // existing navigation state to a content-initiated navigation state. | 3509 // existing navigation state to a content-initiated navigation state. |
| 3510 // UpdateNavigationState conveniently takes care of this for us. | 3510 // UpdateNavigationState conveniently takes care of this for us. |
| 3511 DocumentState* document_state = | 3511 DocumentState* document_state = |
| 3512 DocumentState::FromDataSource(frame->dataSource()); | 3512 DocumentState::FromDataSource(frame->dataSource()); |
| 3513 UpdateNavigationState(document_state, true /* was_within_same_page */); | 3513 // UpdateNavigationState(document_state, true /* was_within_same_page */); |
| 3514 static_cast<NavigationStateImpl*>(document_state->navigation_state()) | 3514 static_cast<NavigationStateImpl*>(document_state->navigation_state()) |
| 3515 ->set_was_within_same_page(true); | 3515 ->set_was_within_same_page(true); |
| 3516 | 3516 |
| 3517 didCommitProvisionalLoad(frame, item, commit_type); | 3517 didCommitProvisionalLoad(frame, item, commit_type); |
| 3518 } | 3518 } |
| 3519 | 3519 |
| 3520 void RenderFrameImpl::didUpdateCurrentHistoryItem() { | 3520 void RenderFrameImpl::didUpdateCurrentHistoryItem() { |
| 3521 render_view_->StartNavStateSyncTimerIfNecessary(this); | 3521 render_view_->StartNavStateSyncTimerIfNecessary(this); |
| 3522 } | 3522 } |
| 3523 | 3523 |
| (...skipping 2503 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6027 int match_count, | 6027 int match_count, |
| 6028 int ordinal, | 6028 int ordinal, |
| 6029 const WebRect& selection_rect, | 6029 const WebRect& selection_rect, |
| 6030 bool final_status_update) { | 6030 bool final_status_update) { |
| 6031 Send(new FrameHostMsg_Find_Reply(routing_id_, request_id, match_count, | 6031 Send(new FrameHostMsg_Find_Reply(routing_id_, request_id, match_count, |
| 6032 selection_rect, ordinal, | 6032 selection_rect, ordinal, |
| 6033 final_status_update)); | 6033 final_status_update)); |
| 6034 } | 6034 } |
| 6035 | 6035 |
| 6036 } // namespace content | 6036 } // namespace content |
| OLD | NEW |