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 #ifndef IOS_WEB_NAVIGATION_NAVIGATION_MANAGER_IMPL_H_ | 5 #ifndef IOS_WEB_NAVIGATION_NAVIGATION_MANAGER_IMPL_H_ |
6 #define IOS_WEB_NAVIGATION_NAVIGATION_MANAGER_IMPL_H_ | 6 #define IOS_WEB_NAVIGATION_NAVIGATION_MANAGER_IMPL_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
59 // Sets the CRWSessionController that backs this object. | 59 // Sets the CRWSessionController that backs this object. |
60 // Keeps a strong reference to |session_controller|. | 60 // Keeps a strong reference to |session_controller|. |
61 // This method should only be called when deserializing |session_controller| | 61 // This method should only be called when deserializing |session_controller| |
62 // and joining it with its NavigationManager. Other cases should call | 62 // and joining it with its NavigationManager. Other cases should call |
63 // InitializeSession() or ReplaceSessionHistory(). | 63 // InitializeSession() or ReplaceSessionHistory(). |
64 // TODO(stuartmorgan): Also move deserialization of CRWSessionControllers | 64 // TODO(stuartmorgan): Also move deserialization of CRWSessionControllers |
65 // under the control of this class, and move the bulk of CRWSessionController | 65 // under the control of this class, and move the bulk of CRWSessionController |
66 // logic into it. | 66 // logic into it. |
67 void SetSessionController(CRWSessionController* session_controller); | 67 void SetSessionController(CRWSessionController* session_controller); |
68 | 68 |
69 // Initializes a new session history, supplying a unique |window_name| for the | 69 // Initializes a new session history. |opened_by_dom| is YES if the page was |
70 // window (or nil). |opened_by_dom| is YES if the page was opened by DOM. | 70 // opened by DOM. |
71 void InitializeSession(NSString* window_name, BOOL opened_by_dom); | 71 void InitializeSession(BOOL opened_by_dom); |
72 | 72 |
73 // Replace the session history with a new one, where |items| is the | 73 // Replace the session history with a new one, where |items| is the |
74 // complete set of navigation items in the new history, and |current_index| | 74 // complete set of navigation items in the new history, and |current_index| |
75 // is the index of the currently active item. | 75 // is the index of the currently active item. |
76 void ReplaceSessionHistory(std::vector<std::unique_ptr<NavigationItem>> items, | 76 void ReplaceSessionHistory(std::vector<std::unique_ptr<NavigationItem>> items, |
77 int current_index); | 77 int current_index); |
78 | 78 |
79 // Sets the delegate used to drive the navigation controller facade. | 79 // Sets the delegate used to drive the navigation controller facade. |
80 void SetFacadeDelegate(NavigationManagerFacadeDelegate* facade_delegate); | 80 void SetFacadeDelegate(NavigationManagerFacadeDelegate* facade_delegate); |
81 NavigationManagerFacadeDelegate* GetFacadeDelegate() const; | 81 NavigationManagerFacadeDelegate* GetFacadeDelegate() const; |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
196 // List of transient url rewriters added by |AddTransientURLRewriter()|. | 196 // List of transient url rewriters added by |AddTransientURLRewriter()|. |
197 std::unique_ptr<std::vector<BrowserURLRewriter::URLRewriter>> | 197 std::unique_ptr<std::vector<BrowserURLRewriter::URLRewriter>> |
198 transient_url_rewriters_; | 198 transient_url_rewriters_; |
199 | 199 |
200 DISALLOW_COPY_AND_ASSIGN(NavigationManagerImpl); | 200 DISALLOW_COPY_AND_ASSIGN(NavigationManagerImpl); |
201 }; | 201 }; |
202 | 202 |
203 } // namespace web | 203 } // namespace web |
204 | 204 |
205 #endif // IOS_WEB_NAVIGATION_NAVIGATION_MANAGER_IMPL_H_ | 205 #endif // IOS_WEB_NAVIGATION_NAVIGATION_MANAGER_IMPL_H_ |
OLD | NEW |