Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(879)

Side by Side Diff: content/public/browser/navigation_handle.h

Issue 2657323003: Convert HistoryTabHelper to use the new navigation callbacks. (Closed)
Patch Set: better fix to send this data from the renderer initially Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_HANDLE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_NAVIGATION_HANDLE_H_
6 #define CONTENT_PUBLIC_BROWSER_NAVIGATION_HANDLE_H_ 6 #define CONTENT_PUBLIC_BROWSER_NAVIGATION_HANDLE_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 10
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 // successful commits or error pages that replace the previous page 169 // successful commits or error pages that replace the previous page
170 // (distinguished by |IsErrorPage|), and false for errors that leave the user 170 // (distinguished by |IsErrorPage|), and false for errors that leave the user
171 // on the previous page. 171 // on the previous page.
172 virtual bool HasCommitted() = 0; 172 virtual bool HasCommitted() = 0;
173 173
174 // Whether the navigation resulted in an error page. 174 // Whether the navigation resulted in an error page.
175 // Note that if an error page reloads, this will return true even though 175 // Note that if an error page reloads, this will return true even though
176 // GetNetErrorCode will be net::OK. 176 // GetNetErrorCode will be net::OK.
177 virtual bool IsErrorPage() = 0; 177 virtual bool IsErrorPage() = 0;
178 178
179 // True if the committed entry has replaced the existing one. A non-user
180 // initiated redirect causes such replacement.
181 virtual bool DidReplaceEntry() = 0;
182
183 // Returns true if the browser history should be updated. Otherwise only
184 // the session history will be updated. E.g., on unreachable urls.
185 virtual bool ShouldUpdateHistory() = 0;
186
179 // Returns the response headers for the request, or nullptr if there aren't 187 // Returns the response headers for the request, or nullptr if there aren't
180 // any response headers or they have not been received yet. The response 188 // any response headers or they have not been received yet. The response
181 // headers may change during the navigation (e.g. after encountering a server 189 // headers may change during the navigation (e.g. after encountering a server
182 // redirect). The headers returned should not be modified, as modifications 190 // redirect). The headers returned should not be modified, as modifications
183 // will not be reflected in the network stack. 191 // will not be reflected in the network stack.
184 virtual const net::HttpResponseHeaders* GetResponseHeaders() = 0; 192 virtual const net::HttpResponseHeaders* GetResponseHeaders() = 0;
185 193
186 // Returns the connection info for the request, the default value is 194 // Returns the connection info for the request, the default value is
187 // CONNECTION_INFO_UNKNOWN if there hasn't been a response (or redirect) 195 // CONNECTION_INFO_UNKNOWN if there hasn't been a response (or redirect)
188 // yet. The connection info may change during the navigation (e.g. after 196 // yet. The connection info may change during the navigation (e.g. after
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 264
257 // The NavigationData that the embedder returned from 265 // The NavigationData that the embedder returned from
258 // ResourceDispatcherHostDelegate::GetNavigationData during commit. This will 266 // ResourceDispatcherHostDelegate::GetNavigationData during commit. This will
259 // be a clone of the NavigationData. 267 // be a clone of the NavigationData.
260 virtual NavigationData* GetNavigationData() = 0; 268 virtual NavigationData* GetNavigationData() = 0;
261 }; 269 };
262 270
263 } // namespace content 271 } // namespace content
264 272
265 #endif // CONTENT_PUBLIC_BROWSER_NAVIGATION_HANDLE_H_ 273 #endif // CONTENT_PUBLIC_BROWSER_NAVIGATION_HANDLE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698