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/files/file_path.h" | 10 #include "base/files/file_path.h" |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
86 : profile_(real_profile), | 86 : profile_(real_profile), |
87 prefs_(PrefServiceSyncable::IncognitoFromProfile(real_profile)), | 87 prefs_(PrefServiceSyncable::IncognitoFromProfile(real_profile)), |
88 io_data_(this), | 88 io_data_(this), |
89 start_time_(Time::Now()), | 89 start_time_(Time::Now()), |
90 zoom_callback_(base::Bind(&OffTheRecordProfileImpl::OnZoomLevelChanged, | 90 zoom_callback_(base::Bind(&OffTheRecordProfileImpl::OnZoomLevelChanged, |
91 base::Unretained(this))) { | 91 base::Unretained(this))) { |
92 // Register on BrowserContext. | 92 // Register on BrowserContext. |
93 components::UserPrefs::Set(this, prefs_); | 93 components::UserPrefs::Set(this, prefs_); |
94 } | 94 } |
95 | 95 |
| 96 void OffTheRecordProfileImpl::VisitDependencyManager( |
| 97 scoped_ptr<content::BrowserContextDependencyVisitor> visitor) { |
| 98 // TODO(erikwright): Implement. |
| 99 visitor->Visit(NULL); |
| 100 } |
| 101 |
| 102 graph::DependencyManagerInstance* |
| 103 OffTheRecordProfileImpl::GetDependencyManager() { |
| 104 // TODO(caitkp): Implement. |
| 105 return NULL; |
| 106 } |
| 107 |
96 void OffTheRecordProfileImpl::Init() { | 108 void OffTheRecordProfileImpl::Init() { |
97 BrowserContextDependencyManager::GetInstance()->CreateBrowserContextServices( | 109 BrowserContextDependencyManager::GetInstance()->CreateBrowserContextServices( |
98 this, false); | 110 this, false); |
99 | 111 |
100 extensions::ExtensionSystem::Get(this)->InitForOTRProfile(); | 112 extensions::ExtensionSystem::Get(this)->InitForOTRProfile(); |
101 | 113 |
102 DCHECK_NE(IncognitoModePrefs::DISABLED, | 114 DCHECK_NE(IncognitoModePrefs::DISABLED, |
103 IncognitoModePrefs::GetAvailability(profile_->GetPrefs())); | 115 IncognitoModePrefs::GetAvailability(profile_->GetPrefs())); |
104 | 116 |
105 #if defined(OS_ANDROID) || defined(OS_IOS) | 117 #if defined(OS_ANDROID) || defined(OS_IOS) |
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
463 case HostZoomMap::ZOOM_CHANGED_FOR_HOST: | 475 case HostZoomMap::ZOOM_CHANGED_FOR_HOST: |
464 host_zoom_map->SetZoomLevelForHost(change.host, change.zoom_level); | 476 host_zoom_map->SetZoomLevelForHost(change.host, change.zoom_level); |
465 return; | 477 return; |
466 case HostZoomMap::ZOOM_CHANGED_FOR_SCHEME_AND_HOST: | 478 case HostZoomMap::ZOOM_CHANGED_FOR_SCHEME_AND_HOST: |
467 host_zoom_map->SetZoomLevelForHostAndScheme(change.scheme, | 479 host_zoom_map->SetZoomLevelForHostAndScheme(change.scheme, |
468 change.host, | 480 change.host, |
469 change.zoom_level); | 481 change.zoom_level); |
470 return; | 482 return; |
471 } | 483 } |
472 } | 484 } |
OLD | NEW |