diff options
author | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-15 03:25:11 +0000 |
---|---|---|
committer | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-15 03:25:11 +0000 |
commit | 7f0005ab19ca4e374029180753c32e4c9813303a (patch) | |
tree | f36e756a90ff4324530789c89aef6a2e2f3573b5 /chrome/browser/sessions | |
parent | b237407befc41c3a19c7519523b102808213b49b (diff) | |
download | chromium_src-7f0005ab19ca4e374029180753c32e4c9813303a.zip chromium_src-7f0005ab19ca4e374029180753c32e4c9813303a.tar.gz chromium_src-7f0005ab19ca4e374029180753c32e4c9813303a.tar.bz2 |
Remove TabContentsType from the NavigationController external interface and in
some related areas. I removed all uses of this in the previous patch.
Review URL: http://codereview.chromium.org/73057
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13730 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/sessions')
-rw-r--r-- | chrome/browser/sessions/session_restore.cc | 4 | ||||
-rw-r--r-- | chrome/browser/sessions/session_service.cc | 8 | ||||
-rw-r--r-- | chrome/browser/sessions/tab_restore_service.cc | 6 | ||||
-rw-r--r-- | chrome/browser/sessions/tab_restore_service_unittest.cc | 4 |
4 files changed, 11 insertions, 11 deletions
diff --git a/chrome/browser/sessions/session_restore.cc b/chrome/browser/sessions/session_restore.cc index d7fb091..47fbad9 100644 --- a/chrome/browser/sessions/session_restore.cc +++ b/chrome/browser/sessions/session_restore.cc @@ -106,7 +106,7 @@ void TabLoader::LoadTabs() { tabs_loading_.insert(tab); tabs_to_load_.pop_front(); tab->LoadIfNecessary(); - if (tab && tab->active_contents()) { + if (tab && tab->tab_contents()) { int tab_index; Browser* browser = Browser::GetBrowserForController(tab, &tab_index); if (browser && browser->selected_index() != tab_index) { @@ -117,7 +117,7 @@ void TabLoader::LoadTabs() { // NOTE: We need to do this here rather than when the tab is added to // the Browser as at that time not everything has been created, so that // the call would do nothing. - tab->active_contents()->WasHidden(); + tab->tab_contents()->WasHidden(); } } } diff --git a/chrome/browser/sessions/session_service.cc b/chrome/browser/sessions/session_service.cc index 5edabd9..ba473c9 100644 --- a/chrome/browser/sessions/session_service.cc +++ b/chrome/browser/sessions/session_service.cc @@ -441,7 +441,7 @@ void SessionService::Observe(NotificationType type, } else { TabNavigationPathPrunedFromBack(controller->window_id(), controller->session_id(), - controller->GetEntryCount()); + controller->entry_count()); } break; } @@ -888,15 +888,15 @@ void SessionService::BuildCommandsForTab( const int min_index = std::max(0, current_index - max_persist_navigation_count); const int max_index = std::min(current_index + max_persist_navigation_count, - controller->GetEntryCount()); - const int pending_index = controller->GetPendingEntryIndex(); + controller->entry_count()); + const int pending_index = controller->pending_entry_index(); if (tab_to_available_range) { (*tab_to_available_range)[controller->session_id().id()] = std::pair<int, int>(min_index, max_index); } for (int i = min_index; i < max_index; ++i) { const NavigationEntry* entry = (i == pending_index) ? - controller->GetPendingEntry() : controller->GetEntryAtIndex(i); + controller->pending_entry() : controller->GetEntryAtIndex(i); DCHECK(entry); if (ShouldTrackEntry(*entry)) { commands->push_back( diff --git a/chrome/browser/sessions/tab_restore_service.cc b/chrome/browser/sessions/tab_restore_service.cc index b49e3f6..340bf34 100644 --- a/chrome/browser/sessions/tab_restore_service.cc +++ b/chrome/browser/sessions/tab_restore_service.cc @@ -310,14 +310,14 @@ void TabRestoreService::Save() { void TabRestoreService::PopulateTabFromController( NavigationController* controller, Tab* tab) { - const int pending_index = controller->GetPendingEntryIndex(); - int entry_count = controller->GetEntryCount(); + const int pending_index = controller->pending_entry_index(); + int entry_count = controller->entry_count(); if (entry_count == 0 && pending_index == 0) entry_count++; tab->navigations.resize(static_cast<int>(entry_count)); for (int i = 0; i < entry_count; ++i) { NavigationEntry* entry = (i == pending_index) ? - controller->GetPendingEntry() : controller->GetEntryAtIndex(i); + controller->pending_entry() : controller->GetEntryAtIndex(i); tab->navigations[i].SetFromNavigationEntry(*entry); } tab->current_navigation_index = controller->GetCurrentEntryIndex(); diff --git a/chrome/browser/sessions/tab_restore_service_unittest.cc b/chrome/browser/sessions/tab_restore_service_unittest.cc index f55bdb1..9be6429 100644 --- a/chrome/browser/sessions/tab_restore_service_unittest.cc +++ b/chrome/browser/sessions/tab_restore_service_unittest.cc @@ -42,8 +42,8 @@ class TabRestoreServiceTest : public RenderViewHostTestHarness { // Navigate back. We have to do this song and dance as NavigationController // isn't happy if you navigate immediately while going back. controller()->GoToIndex(index); - rvh()->SendNavigate(controller()->GetPendingEntry()->page_id(), - controller()->GetPendingEntry()->url()); + rvh()->SendNavigate(controller()->pending_entry()->page_id(), + controller()->pending_entry()->url()); } void RecreateService() { |