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_ENTRY_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_NAVIGATION_ENTRY_H_ |
6 #define CONTENT_PUBLIC_BROWSER_NAVIGATION_ENTRY_H_ | 6 #define CONTENT_PUBLIC_BROWSER_NAVIGATION_ENTRY_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
80 // | 80 // |
81 // GetVirtualURL() will return the URL to display to the user in all cases, so | 81 // GetVirtualURL() will return the URL to display to the user in all cases, so |
82 // if there is no overridden display URL, it will return the actual one. | 82 // if there is no overridden display URL, it will return the actual one. |
83 virtual void SetVirtualURL(const GURL& url) = 0; | 83 virtual void SetVirtualURL(const GURL& url) = 0; |
84 virtual const GURL& GetVirtualURL() const = 0; | 84 virtual const GURL& GetVirtualURL() const = 0; |
85 | 85 |
86 // The title as set by the page. This will be empty if there is no title set. | 86 // The title as set by the page. This will be empty if there is no title set. |
87 // The caller is responsible for detecting when there is no title and | 87 // The caller is responsible for detecting when there is no title and |
88 // displaying the appropriate "Untitled" label if this is being displayed to | 88 // displaying the appropriate "Untitled" label if this is being displayed to |
89 // the user. | 89 // the user. |
90 // Use WebContents::UpdateTitleForEntry() in most cases. Only call the below | |
Charlie Reis
2016/07/13 22:21:47
Let's elaborate a bit:
Use WebContents::UpdateTit
afakhry
2016/07/13 22:52:50
Done.
| |
91 // NavigationEntry::SetTitle() when it's known to be a non-visible entry. | |
90 virtual void SetTitle(const base::string16& title) = 0; | 92 virtual void SetTitle(const base::string16& title) = 0; |
91 virtual const base::string16& GetTitle() const = 0; | 93 virtual const base::string16& GetTitle() const = 0; |
92 | 94 |
93 // Page state is an opaque blob created by Blink that represents the state of | 95 // Page state is an opaque blob created by Blink that represents the state of |
94 // the page. This includes form entries and scroll position for each frame. | 96 // the page. This includes form entries and scroll position for each frame. |
95 // We store it so that we can supply it back to Blink to restore form state | 97 // We store it so that we can supply it back to Blink to restore form state |
96 // properly when the user goes back and forward. | 98 // properly when the user goes back and forward. |
97 // | 99 // |
98 // NOTE: This state is saved to disk and used to restore previous states. If | 100 // NOTE: This state is saved to disk and used to restore previous states. If |
99 // the format is modified in the future, we should still be able to deal with | 101 // the format is modified in the future, we should still be able to deal with |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
219 virtual void SetRedirectChain(const std::vector<GURL>& redirects) = 0; | 221 virtual void SetRedirectChain(const std::vector<GURL>& redirects) = 0; |
220 virtual const std::vector<GURL>& GetRedirectChain() const = 0; | 222 virtual const std::vector<GURL>& GetRedirectChain() const = 0; |
221 | 223 |
222 // True if this entry is restored and hasn't been loaded. | 224 // True if this entry is restored and hasn't been loaded. |
223 virtual bool IsRestored() const = 0; | 225 virtual bool IsRestored() const = 0; |
224 }; | 226 }; |
225 | 227 |
226 } // namespace content | 228 } // namespace content |
227 | 229 |
228 #endif // CONTENT_PUBLIC_BROWSER_NAVIGATION_ENTRY_H_ | 230 #endif // CONTENT_PUBLIC_BROWSER_NAVIGATION_ENTRY_H_ |
OLD | NEW |