OLD | NEW |
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 #include "components/sessions/content/content_live_tab.h" | 5 #include "components/sessions/content/content_live_tab.h" |
6 #include "components/sessions/content/content_platform_specific_tab_data.h" | 6 #include "components/sessions/content/content_platform_specific_tab_data.h" |
7 | 7 |
8 namespace { | 8 namespace { |
9 const char kContentLiveTabWebContentsUserDataKey[] = "content_live_tab"; | 9 const char kContentLiveTabWebContentsUserDataKey[] = "content_live_tab"; |
10 } | 10 } |
(...skipping 10 matching lines...) Expand all Loading... |
21 | 21 |
22 return static_cast<ContentLiveTab*>(contents->GetUserData( | 22 return static_cast<ContentLiveTab*>(contents->GetUserData( |
23 kContentLiveTabWebContentsUserDataKey)); | 23 kContentLiveTabWebContentsUserDataKey)); |
24 } | 24 } |
25 | 25 |
26 ContentLiveTab::ContentLiveTab(content::WebContents* contents) | 26 ContentLiveTab::ContentLiveTab(content::WebContents* contents) |
27 : web_contents_(contents) {} | 27 : web_contents_(contents) {} |
28 | 28 |
29 ContentLiveTab::~ContentLiveTab() {} | 29 ContentLiveTab::~ContentLiveTab() {} |
30 | 30 |
31 bool ContentLiveTab::IsInitialNavigation() { | 31 bool ContentLiveTab::IsInitialBlankNavigation() { |
32 return navigation_controller().IsInitialNavigation(); | 32 return navigation_controller().IsInitialBlankNavigation(); |
33 } | 33 } |
34 | 34 |
35 int ContentLiveTab::GetCurrentEntryIndex() { | 35 int ContentLiveTab::GetCurrentEntryIndex() { |
36 return navigation_controller().GetCurrentEntryIndex(); | 36 return navigation_controller().GetCurrentEntryIndex(); |
37 } | 37 } |
38 | 38 |
39 int ContentLiveTab::GetPendingEntryIndex() { | 39 int ContentLiveTab::GetPendingEntryIndex() { |
40 return navigation_controller().GetPendingEntryIndex(); | 40 return navigation_controller().GetPendingEntryIndex(); |
41 } | 41 } |
42 | 42 |
(...skipping 19 matching lines...) Expand all Loading... |
62 | 62 |
63 void ContentLiveTab::LoadIfNecessary() { | 63 void ContentLiveTab::LoadIfNecessary() { |
64 navigation_controller().LoadIfNecessary(); | 64 navigation_controller().LoadIfNecessary(); |
65 } | 65 } |
66 | 66 |
67 const std::string& ContentLiveTab::GetUserAgentOverride() const { | 67 const std::string& ContentLiveTab::GetUserAgentOverride() const { |
68 return web_contents()->GetUserAgentOverride(); | 68 return web_contents()->GetUserAgentOverride(); |
69 } | 69 } |
70 | 70 |
71 } // namespace sessions | 71 } // namespace sessions |
OLD | NEW |