Chromium Code Reviews| Index: content/public/renderer/navigation_state.h |
| diff --git a/content/public/renderer/navigation_state.h b/content/public/renderer/navigation_state.h |
| index 15eac2663e6734526f91ddff74edae364481d341..9d8cd142950f14e206166f66a95b0fce49b00a9c 100644 |
| --- a/content/public/renderer/navigation_state.h |
| +++ b/content/public/renderer/navigation_state.h |
| @@ -21,24 +21,32 @@ class CONTENT_EXPORT NavigationState { |
| static NavigationState* CreateBrowserInitiated( |
| int32 pending_page_id, |
| + int pending_nav_entry_id, |
| int pending_history_list_offset, |
| bool history_list_was_cleared, |
| ui::PageTransition transition_type) { |
| return new NavigationState(transition_type, |
| false, |
| pending_page_id, |
| + pending_nav_entry_id, |
| pending_history_list_offset, |
| history_list_was_cleared); |
| } |
| static NavigationState* CreateContentInitiated() { |
| return new NavigationState( |
| - ui::PAGE_TRANSITION_LINK, true, -1, -1, false); |
| + ui::PAGE_TRANSITION_LINK, true, -1, 0, -1, false); |
| } |
| // Contains the page_id for this navigation or -1 if there is none yet. |
| int32 pending_page_id() const { return pending_page_id_; } |
|
Charlie Reis
2015/03/12 18:28:17
Same here.
|
| + // Contains the nav_entry_id for this navigation if it is browser-initiated, |
| + // or 0 if there is none because it was renderer-initiated. |
| + int32 pending_nav_entry_id() const { |
| + return pending_nav_entry_id_; |
| + } |
| + |
| // If pending_page_id() is not -1, then this contains the corresponding |
| // offset of the page in the back/forward history list. |
| int pending_history_list_offset() const { |
| @@ -119,6 +127,7 @@ class CONTENT_EXPORT NavigationState { |
| NavigationState(ui::PageTransition transition_type, |
| bool is_content_initiated, |
| int32 pending_page_id, |
| + int pending_nav_entry_id, |
| int pending_history_list_offset, |
| bool history_list_was_cleared); |
| @@ -126,6 +135,7 @@ class CONTENT_EXPORT NavigationState { |
| bool request_committed_; |
| bool is_content_initiated_; |
| int32 pending_page_id_; |
| + int pending_nav_entry_id_; |
| int pending_history_list_offset_; |
| bool history_list_was_cleared_; |
| bool should_replace_current_entry_; |