OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "base/bind.h" | 5 #include "base/bind.h" |
6 #include "base/command_line.h" | 6 #include "base/command_line.h" |
7 #include "base/memory/ref_counted.h" | 7 #include "base/memory/ref_counted.h" |
8 #include "chrome/browser/browser_shutdown.h" | 8 #include "chrome/browser/browser_shutdown.h" |
9 #include "chrome/browser/prefs/session_startup_pref.h" | 9 #include "chrome/browser/prefs/session_startup_pref.h" |
10 #include "chrome/browser/profiles/profile_io_data.h" | 10 #include "chrome/browser/profiles/profile_io_data.h" |
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
147 return; | 147 return; |
148 | 148 |
149 // TODO: Remove Athena special casing once the AthenaSessionRestore is in | 149 // TODO: Remove Athena special casing once the AthenaSessionRestore is in |
150 // place. | 150 // place. |
151 #if defined(OS_ANDROID) || defined(USE_ATHENA) | 151 #if defined(OS_ANDROID) || defined(USE_ATHENA) |
152 SessionStartupPref::Type startup_pref_type = | 152 SessionStartupPref::Type startup_pref_type = |
153 SessionStartupPref::GetDefaultStartupType(); | 153 SessionStartupPref::GetDefaultStartupType(); |
154 #else | 154 #else |
155 SessionStartupPref::Type startup_pref_type = | 155 SessionStartupPref::Type startup_pref_type = |
156 StartupBrowserCreator::GetSessionStartupPref( | 156 StartupBrowserCreator::GetSessionStartupPref( |
157 *CommandLine::ForCurrentProcess(), profile).type; | 157 *base::CommandLine::ForCurrentProcess(), profile).type; |
158 #endif | 158 #endif |
159 | 159 |
160 scoped_refptr<SessionDataDeleter> deleter( | 160 scoped_refptr<SessionDataDeleter> deleter( |
161 new SessionDataDeleter(profile->GetSpecialStoragePolicy(), | 161 new SessionDataDeleter(profile->GetSpecialStoragePolicy(), |
162 startup_pref_type == SessionStartupPref::LAST)); | 162 startup_pref_type == SessionStartupPref::LAST)); |
163 deleter->Run( | 163 deleter->Run( |
164 Profile::GetDefaultStoragePartition(profile), | 164 Profile::GetDefaultStoragePartition(profile), |
165 ProfileIOData::FromResourceContext(profile->GetResourceContext())); | 165 ProfileIOData::FromResourceContext(profile->GetResourceContext())); |
166 } | 166 } |
OLD | NEW |