| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_ | 6 #define CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 struct Referrer; | 24 struct Referrer; |
| 25 | 25 |
| 26 // A NavigationController maintains the back-forward list for a WebContents and | 26 // A NavigationController maintains the back-forward list for a WebContents and |
| 27 // manages all navigation within that list. | 27 // manages all navigation within that list. |
| 28 // | 28 // |
| 29 // Each NavigationController belongs to one WebContents; each WebContents has | 29 // Each NavigationController belongs to one WebContents; each WebContents has |
| 30 // exactly one NavigationController. | 30 // exactly one NavigationController. |
| 31 class NavigationController { | 31 class NavigationController { |
| 32 public: | 32 public: |
| 33 enum ReloadType { | 33 enum ReloadType { |
| 34 NO_RELOAD, // Normal load. | 34 NO_RELOAD, // Normal load. |
| 35 RELOAD, // Normal (cache-validating) reload. | 35 RELOAD, // Normal (cache-validating) reload. |
| 36 RELOAD_IGNORING_CACHE // Reload bypassing the cache, aka shift-reload. | 36 RELOAD_IGNORING_CACHE, // Reload bypassing the cache (shift-reload). |
| 37 RELOAD_ORIGINAL_REQUEST_URL // Reload using the original request URL. |
| 37 }; | 38 }; |
| 38 | 39 |
| 39 // Creates a navigation entry and translates the virtual url to a real one. | 40 // Creates a navigation entry and translates the virtual url to a real one. |
| 40 // This is a general call; prefer LoadURL[FromRenderer]/TransferURL below. | 41 // This is a general call; prefer LoadURL[FromRenderer]/TransferURL below. |
| 41 // Extra headers are separated by \n. | 42 // Extra headers are separated by \n. |
| 42 CONTENT_EXPORT static NavigationEntry* CreateNavigationEntry( | 43 CONTENT_EXPORT static NavigationEntry* CreateNavigationEntry( |
| 43 const GURL& url, | 44 const GURL& url, |
| 44 const Referrer& referrer, | 45 const Referrer& referrer, |
| 45 PageTransition transition, | 46 PageTransition transition, |
| 46 bool is_renderer_initiated, | 47 bool is_renderer_initiated, |
| (...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 270 virtual void CopyStateFromAndPrune(NavigationController* source) = 0; | 271 virtual void CopyStateFromAndPrune(NavigationController* source) = 0; |
| 271 | 272 |
| 272 // Removes all the entries except the active entry. If there is a new pending | 273 // Removes all the entries except the active entry. If there is a new pending |
| 273 // navigation it is preserved. | 274 // navigation it is preserved. |
| 274 virtual void PruneAllButActive() = 0; | 275 virtual void PruneAllButActive() = 0; |
| 275 }; | 276 }; |
| 276 | 277 |
| 277 } // namespace content | 278 } // namespace content |
| 278 | 279 |
| 279 #endif // CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_ | 280 #endif // CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_ |
| OLD | NEW |