| 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 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 } | 240 } |
| 241 | 241 |
| 242 AutocompleteClassifier* OffTheRecordProfileImpl::GetAutocompleteClassifier() { | 242 AutocompleteClassifier* OffTheRecordProfileImpl::GetAutocompleteClassifier() { |
| 243 return profile_->GetAutocompleteClassifier(); | 243 return profile_->GetAutocompleteClassifier(); |
| 244 } | 244 } |
| 245 | 245 |
| 246 history::ShortcutsBackend* OffTheRecordProfileImpl::GetShortcutsBackend() { | 246 history::ShortcutsBackend* OffTheRecordProfileImpl::GetShortcutsBackend() { |
| 247 return NULL; | 247 return NULL; |
| 248 } | 248 } |
| 249 | 249 |
| 250 WebDataService* OffTheRecordProfileImpl::GetWebDataService( | |
| 251 ServiceAccessType sat) { | |
| 252 if (sat == EXPLICIT_ACCESS) | |
| 253 return profile_->GetWebDataService(sat); | |
| 254 | |
| 255 NOTREACHED() << "This profile is OffTheRecord"; | |
| 256 return NULL; | |
| 257 } | |
| 258 | |
| 259 WebDataService* OffTheRecordProfileImpl::GetWebDataServiceWithoutCreating() { | |
| 260 return profile_->GetWebDataServiceWithoutCreating(); | |
| 261 } | |
| 262 | |
| 263 PrefService* OffTheRecordProfileImpl::GetPrefs() { | 250 PrefService* OffTheRecordProfileImpl::GetPrefs() { |
| 264 return prefs_; | 251 return prefs_; |
| 265 } | 252 } |
| 266 | 253 |
| 267 PrefService* OffTheRecordProfileImpl::GetOffTheRecordPrefs() { | 254 PrefService* OffTheRecordProfileImpl::GetOffTheRecordPrefs() { |
| 268 return prefs_; | 255 return prefs_; |
| 269 } | 256 } |
| 270 | 257 |
| 271 DownloadManager* OffTheRecordProfileImpl::GetDownloadManager() { | 258 DownloadManager* OffTheRecordProfileImpl::GetDownloadManager() { |
| 272 return DownloadServiceFactory::GetForProfile(this)->GetDownloadManager(); | 259 return DownloadServiceFactory::GetForProfile(this)->GetDownloadManager(); |
| (...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 485 if (!profile) | 472 if (!profile) |
| 486 profile = new OffTheRecordProfileImpl(this); | 473 profile = new OffTheRecordProfileImpl(this); |
| 487 profile->Init(); | 474 profile->Init(); |
| 488 return profile; | 475 return profile; |
| 489 } | 476 } |
| 490 | 477 |
| 491 base::Callback<ChromeURLDataManagerBackend*(void)> | 478 base::Callback<ChromeURLDataManagerBackend*(void)> |
| 492 OffTheRecordProfileImpl::GetChromeURLDataManagerBackendGetter() const { | 479 OffTheRecordProfileImpl::GetChromeURLDataManagerBackendGetter() const { |
| 493 return io_data_.GetChromeURLDataManagerBackendGetter(); | 480 return io_data_.GetChromeURLDataManagerBackendGetter(); |
| 494 } | 481 } |
| OLD | NEW |