| 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> |
| 11 #include <vector> | 11 #include <vector> |
| 12 | 12 |
| 13 #import "base/mac/scoped_nsobject.h" | 13 #import "base/mac/scoped_nsobject.h" |
| 14 #include "base/macros.h" | 14 #include "base/macros.h" |
| 15 #import "ios/web/public/navigation_item_list.h" |
| 15 #import "ios/web/public/navigation_manager.h" | 16 #import "ios/web/public/navigation_manager.h" |
| 16 #include "ui/base/page_transition_types.h" | 17 #include "ui/base/page_transition_types.h" |
| 17 #include "url/gurl.h" | 18 #include "url/gurl.h" |
| 18 | 19 |
| 19 @class CRWSessionController; | 20 @class CRWSessionController; |
| 20 | 21 |
| 21 namespace web { | 22 namespace web { |
| 22 class BrowserState; | 23 class BrowserState; |
| 23 class NavigationItem; | 24 class NavigationItem; |
| 24 struct Referrer; | 25 struct Referrer; |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 // Convenience accessors to get the underlying NavigationItems from the | 86 // Convenience accessors to get the underlying NavigationItems from the |
| 86 // SessionEntries returned from |session_controller_|'s -lastUserEntry and | 87 // SessionEntries returned from |session_controller_|'s -lastUserEntry and |
| 87 // -previousEntry methods. | 88 // -previousEntry methods. |
| 88 // TODO(crbug.com/546365): Remove these methods. | 89 // TODO(crbug.com/546365): Remove these methods. |
| 89 NavigationItem* GetLastUserItem() const; | 90 NavigationItem* GetLastUserItem() const; |
| 90 NavigationItem* GetPreviousItem() const; | 91 NavigationItem* GetPreviousItem() const; |
| 91 | 92 |
| 92 // Temporary method. Returns a vector of NavigationItems corresponding to | 93 // Temporary method. Returns a vector of NavigationItems corresponding to |
| 93 // the SessionEntries of the uderlying CRWSessionController. | 94 // the SessionEntries of the uderlying CRWSessionController. |
| 94 // TODO(crbug.com/546365): Remove this method. | 95 // TODO(crbug.com/546365): Remove this method. |
| 95 std::vector<NavigationItem*> GetItems(); | 96 NavigationItemList GetItems() const; |
| 96 | 97 |
| 97 // NavigationManager: | 98 // NavigationManager: |
| 98 BrowserState* GetBrowserState() const override; | 99 BrowserState* GetBrowserState() const override; |
| 99 WebState* GetWebState() const override; | 100 WebState* GetWebState() const override; |
| 100 NavigationItem* GetVisibleItem() const override; | 101 NavigationItem* GetVisibleItem() const override; |
| 101 NavigationItem* GetLastCommittedItem() const override; | 102 NavigationItem* GetLastCommittedItem() const override; |
| 102 NavigationItem* GetPendingItem() const override; | 103 NavigationItem* GetPendingItem() const override; |
| 103 NavigationItem* GetTransientItem() const override; | 104 NavigationItem* GetTransientItem() const override; |
| 104 void DiscardNonCommittedItems() override; | 105 void DiscardNonCommittedItems() override; |
| 105 void LoadIfNecessary() override; | 106 void LoadIfNecessary() override; |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 166 // List of transient url rewriters added by |AddTransientURLRewriter()|. | 167 // List of transient url rewriters added by |AddTransientURLRewriter()|. |
| 167 std::unique_ptr<std::vector<BrowserURLRewriter::URLRewriter>> | 168 std::unique_ptr<std::vector<BrowserURLRewriter::URLRewriter>> |
| 168 transient_url_rewriters_; | 169 transient_url_rewriters_; |
| 169 | 170 |
| 170 DISALLOW_COPY_AND_ASSIGN(NavigationManagerImpl); | 171 DISALLOW_COPY_AND_ASSIGN(NavigationManagerImpl); |
| 171 }; | 172 }; |
| 172 | 173 |
| 173 } // namespace web | 174 } // namespace web |
| 174 | 175 |
| 175 #endif // IOS_WEB_NAVIGATION_NAVIGATION_MANAGER_IMPL_H_ | 176 #endif // IOS_WEB_NAVIGATION_NAVIGATION_MANAGER_IMPL_H_ |
| OLD | NEW |