| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chrome/browser/profiles/off_the_record_profile_impl.h" | 5 #include "chrome/browser/profiles/off_the_record_profile_impl.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
| (...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 270 return profile_->GetWebDataService(sat); | 270 return profile_->GetWebDataService(sat); |
| 271 | 271 |
| 272 NOTREACHED() << "This profile is OffTheRecord"; | 272 NOTREACHED() << "This profile is OffTheRecord"; |
| 273 return NULL; | 273 return NULL; |
| 274 } | 274 } |
| 275 | 275 |
| 276 WebDataService* OffTheRecordProfileImpl::GetWebDataServiceWithoutCreating() { | 276 WebDataService* OffTheRecordProfileImpl::GetWebDataServiceWithoutCreating() { |
| 277 return profile_->GetWebDataServiceWithoutCreating(); | 277 return profile_->GetWebDataServiceWithoutCreating(); |
| 278 } | 278 } |
| 279 | 279 |
| 280 PasswordStore* OffTheRecordProfileImpl::GetPasswordStore( | |
| 281 ServiceAccessType sat) { | |
| 282 if (sat == EXPLICIT_ACCESS) | |
| 283 return profile_->GetPasswordStore(sat); | |
| 284 | |
| 285 NOTREACHED() << "This profile is OffTheRecord"; | |
| 286 return NULL; | |
| 287 } | |
| 288 | |
| 289 PrefService* OffTheRecordProfileImpl::GetPrefs() { | 280 PrefService* OffTheRecordProfileImpl::GetPrefs() { |
| 290 return prefs_; | 281 return prefs_; |
| 291 } | 282 } |
| 292 | 283 |
| 293 PrefService* OffTheRecordProfileImpl::GetOffTheRecordPrefs() { | 284 PrefService* OffTheRecordProfileImpl::GetOffTheRecordPrefs() { |
| 294 return prefs_; | 285 return prefs_; |
| 295 } | 286 } |
| 296 | 287 |
| 297 TemplateURLFetcher* OffTheRecordProfileImpl::GetTemplateURLFetcher() { | 288 TemplateURLFetcher* OffTheRecordProfileImpl::GetTemplateURLFetcher() { |
| 298 return profile_->GetTemplateURLFetcher(); | 289 return profile_->GetTemplateURLFetcher(); |
| (...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 536 OffTheRecordProfileImpl* profile = NULL; | 527 OffTheRecordProfileImpl* profile = NULL; |
| 537 #if defined(OS_CHROMEOS) | 528 #if defined(OS_CHROMEOS) |
| 538 if (Profile::IsGuestSession()) | 529 if (Profile::IsGuestSession()) |
| 539 profile = new GuestSessionProfile(this); | 530 profile = new GuestSessionProfile(this); |
| 540 #endif | 531 #endif |
| 541 if (!profile) | 532 if (!profile) |
| 542 profile = new OffTheRecordProfileImpl(this); | 533 profile = new OffTheRecordProfileImpl(this); |
| 543 profile->Init(); | 534 profile->Init(); |
| 544 return profile; | 535 return profile; |
| 545 } | 536 } |
| OLD | NEW |