Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(270)

Side by Side Diff: chrome/browser/policy/browser_policy_connector.cc

Issue 22031003: Rename BrowserThread::IsWellKnownThread to IsThreadInitialized. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Minor comment reword. Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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/policy/browser_policy_connector.h" 5 #include "chrome/browser/policy/browser_policy_connector.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <iterator> 8 #include <iterator>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 // Cleanup properly in those cases and avoid crashing the ToastCrasher test. 145 // Cleanup properly in those cases and avoid crashing the ToastCrasher test.
146 Shutdown(); 146 Shutdown();
147 } 147 }
148 } 148 }
149 149
150 void BrowserPolicyConnector::Init( 150 void BrowserPolicyConnector::Init(
151 PrefService* local_state, 151 PrefService* local_state,
152 scoped_refptr<net::URLRequestContextGetter> request_context) { 152 scoped_refptr<net::URLRequestContextGetter> request_context) {
153 // Initialization of some of the providers requires the FILE thread; make 153 // Initialization of some of the providers requires the FILE thread; make
154 // sure that threading is ready at this point. 154 // sure that threading is ready at this point.
155 DCHECK(BrowserThread::IsWellKnownThread(BrowserThread::FILE)); 155 DCHECK(BrowserThread::IsThreadInitialized(BrowserThread::FILE));
156 DCHECK(!is_initialized()) << "BrowserPolicyConnector::Init() called twice."; 156 DCHECK(!is_initialized()) << "BrowserPolicyConnector::Init() called twice.";
157 157
158 local_state_ = local_state; 158 local_state_ = local_state;
159 request_context_ = request_context; 159 request_context_ = request_context;
160 160
161 device_management_service_->ScheduleInitialization( 161 device_management_service_->ScheduleInitialization(
162 kServiceInitializationStartupDelay); 162 kServiceInitializationStartupDelay);
163 163
164 if (g_testing_provider) 164 if (g_testing_provider)
165 g_testing_provider->Init(); 165 g_testing_provider->Init();
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
475 return new AsyncPolicyProvider(loader.Pass()); 475 return new AsyncPolicyProvider(loader.Pass());
476 } else { 476 } else {
477 return NULL; 477 return NULL;
478 } 478 }
479 #else 479 #else
480 return NULL; 480 return NULL;
481 #endif 481 #endif
482 } 482 }
483 483
484 } // namespace policy 484 } // namespace policy
OLDNEW
« no previous file with comments | « chrome/browser/history/shortcuts_backend.cc ('k') | chrome/browser/profiles/profile_shortcut_manager_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698