OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 /* | 5 /* |
6 * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. | 6 * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. |
7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. | 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. |
8 * (http://www.torchmobile.com/) | 8 * (http://www.torchmobile.com/) |
9 * | 9 * |
10 * Redistribution and use in source and binary forms, with or without | 10 * Redistribution and use in source and binary forms, with or without |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 | 111 |
112 void GoToEntry(scoped_ptr<HistoryEntry> entry, | 112 void GoToEntry(scoped_ptr<HistoryEntry> entry, |
113 blink::WebURLRequest::CachePolicy cache_policy); | 113 blink::WebURLRequest::CachePolicy cache_policy); |
114 | 114 |
115 void UpdateForCommit(RenderFrameImpl* frame, | 115 void UpdateForCommit(RenderFrameImpl* frame, |
116 const blink::WebHistoryItem& item, | 116 const blink::WebHistoryItem& item, |
117 blink::WebHistoryCommitType commit_type, | 117 blink::WebHistoryCommitType commit_type, |
118 bool navigation_within_page); | 118 bool navigation_within_page); |
119 | 119 |
120 HistoryEntry* GetCurrentEntry(); | 120 HistoryEntry* GetCurrentEntry(); |
121 HistoryEntry* GetPreviousEntry(); | |
122 blink::WebHistoryItem GetItemForNewChildFrame(RenderFrameImpl* frame) const; | 121 blink::WebHistoryItem GetItemForNewChildFrame(RenderFrameImpl* frame) const; |
123 void RemoveChildrenForRedirect(RenderFrameImpl* frame); | 122 void RemoveChildrenForRedirect(RenderFrameImpl* frame); |
124 | 123 |
125 private: | 124 private: |
126 typedef std::vector<std::pair<blink::WebFrame*, blink::WebHistoryItem> > | 125 typedef std::vector<std::pair<blink::WebFrame*, blink::WebHistoryItem> > |
127 HistoryFrameLoadVector; | 126 HistoryFrameLoadVector; |
128 void RecursiveGoToEntry(blink::WebFrame* frame, | 127 void RecursiveGoToEntry(blink::WebFrame* frame, |
129 HistoryFrameLoadVector& sameDocumentLoads, | 128 HistoryFrameLoadVector& sameDocumentLoads, |
130 HistoryFrameLoadVector& differentDocumentLoads); | 129 HistoryFrameLoadVector& differentDocumentLoads); |
131 | 130 |
132 void UpdateForInitialLoadInChildFrame(RenderFrameImpl* frame, | 131 void UpdateForInitialLoadInChildFrame(RenderFrameImpl* frame, |
133 const blink::WebHistoryItem& item); | 132 const blink::WebHistoryItem& item); |
134 void CreateNewBackForwardItem(RenderFrameImpl* frame, | 133 void CreateNewBackForwardItem(RenderFrameImpl* frame, |
135 const blink::WebHistoryItem& item, | 134 const blink::WebHistoryItem& item, |
136 bool clone_children_of_target); | 135 bool clone_children_of_target); |
137 | 136 |
138 RenderViewImpl* render_view_; | 137 RenderViewImpl* render_view_; |
139 | 138 |
140 scoped_ptr<HistoryEntry> current_entry_; | 139 scoped_ptr<HistoryEntry> current_entry_; |
141 scoped_ptr<HistoryEntry> previous_entry_; | |
142 scoped_ptr<HistoryEntry> provisional_entry_; | 140 scoped_ptr<HistoryEntry> provisional_entry_; |
143 | 141 |
144 DISALLOW_COPY_AND_ASSIGN(HistoryController); | 142 DISALLOW_COPY_AND_ASSIGN(HistoryController); |
145 }; | 143 }; |
146 | 144 |
147 } // namespace content | 145 } // namespace content |
148 | 146 |
149 #endif // CONTENT_RENDERER_HISTORY_CONTROLLER_H_ | 147 #endif // CONTENT_RENDERER_HISTORY_CONTROLLER_H_ |
OLD | NEW |