diff options
author | nsylvain@chromium.org <nsylvain@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-18 03:48:01 +0000 |
---|---|---|
committer | nsylvain@chromium.org <nsylvain@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-18 03:48:01 +0000 |
commit | 276ae6d3b89a1b521f54277669e73ed8e548fdb1 (patch) | |
tree | 2e81baca1aed143c3781409e2cd00aaab6608625 /chrome/browser/session_restore.cc | |
parent | 4c561633e8eab426db0f94f3f03543e94c57ff77 (diff) | |
download | chromium_src-276ae6d3b89a1b521f54277669e73ed8e548fdb1.zip chromium_src-276ae6d3b89a1b521f54277669e73ed8e548fdb1.tar.gz chromium_src-276ae6d3b89a1b521f54277669e73ed8e548fdb1.tar.bz2 |
Revert change 5596 because it broke the build
Review URL: http://codereview.chromium.org/11439
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5598 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/session_restore.cc')
-rw-r--r-- | chrome/browser/session_restore.cc | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/chrome/browser/session_restore.cc b/chrome/browser/session_restore.cc index 258ed7c..b8ec569 100644 --- a/chrome/browser/session_restore.cc +++ b/chrome/browser/session_restore.cc @@ -12,7 +12,6 @@ #include "chrome/browser/browser_process.h" #include "chrome/browser/navigation_controller.h" #include "chrome/browser/profile.h" -#include "chrome/browser/session_service.h" #include "chrome/browser/tab_contents.h" #include "chrome/common/notification_registrar.h" #include "chrome/common/notification_service.h" @@ -287,14 +286,14 @@ class SessionRestoreImpl : public NotificationObserver { for (std::vector<SessionWindow*>::iterator i = windows->begin(); i != windows->end(); ++i) { Browser* browser = NULL; - if (!has_tabbed_browser && (*i)->type == Browser::TYPE_NORMAL) + if (!has_tabbed_browser && (*i)->type == BrowserType::TABBED_BROWSER) has_tabbed_browser = true; - if (i == windows->begin() && (*i)->type == Browser::TYPE_NORMAL && + if (i == windows->begin() && (*i)->type == BrowserType::TABBED_BROWSER && !clobber_existing_window_) { // If there is an open tabbed browser window, use it. Otherwise fall // through and create a new one. browser = current_browser; - if (browser && (browser->type() != Browser::TYPE_NORMAL || + if (browser && (browser->type() != BrowserType::TABBED_BROWSER || browser->profile()->IsOffTheRecord())) { browser = NULL; } @@ -305,7 +304,7 @@ class SessionRestoreImpl : public NotificationObserver { browser->set_override_maximized((*i)->is_maximized); browser->CreateBrowserWindow(); } - if ((*i)->type == Browser::TYPE_NORMAL) + if ((*i)->type == BrowserType::TABBED_BROWSER) last_browser = browser; const int initial_tab_count = browser->tab_count(); RestoreTabsToBrowser(*(*i), browser); @@ -317,7 +316,7 @@ class SessionRestoreImpl : public NotificationObserver { // included at least one tabbed browser, then close the browser window // that was opened when the user clicked to restore the session. if (clobber_existing_window_ && current_browser && has_tabbed_browser && - current_browser->type() == Browser::TYPE_NORMAL) { + current_browser->type() == BrowserType::TABBED_BROWSER) { current_browser->CloseAllTabs(); } if (last_browser && !urls_to_open_.empty()) |