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/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 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
333 | 333 |
334 NetworkConfigurationUpdater* | 334 NetworkConfigurationUpdater* |
335 BrowserPolicyConnector::GetNetworkConfigurationUpdater() { | 335 BrowserPolicyConnector::GetNetworkConfigurationUpdater() { |
336 if (!network_configuration_updater_) { | 336 if (!network_configuration_updater_) { |
337 CommandLine* command_line = CommandLine::ForCurrentProcess(); | 337 CommandLine* command_line = CommandLine::ForCurrentProcess(); |
338 if (command_line->HasSwitch( | 338 if (command_line->HasSwitch( |
339 chromeos::switches::kUseNewNetworkConfigurationHandlers)) { | 339 chromeos::switches::kUseNewNetworkConfigurationHandlers)) { |
340 network_configuration_updater_.reset( | 340 network_configuration_updater_.reset( |
341 new NetworkConfigurationUpdaterImpl( | 341 new NetworkConfigurationUpdaterImpl( |
342 GetPolicyService(), | 342 GetPolicyService(), |
343 chromeos::ManagedNetworkConfigurationHandler::Get(), | |
344 make_scoped_ptr(new chromeos::CertificateHandler))); | 343 make_scoped_ptr(new chromeos::CertificateHandler))); |
345 } else { | 344 } else { |
346 network_configuration_updater_.reset( | 345 network_configuration_updater_.reset( |
347 new NetworkConfigurationUpdaterImplCros( | 346 new NetworkConfigurationUpdaterImplCros( |
348 GetPolicyService(), | 347 GetPolicyService(), |
349 chromeos::CrosLibrary::Get()->GetNetworkLibrary(), | 348 chromeos::CrosLibrary::Get()->GetNetworkLibrary(), |
350 make_scoped_ptr(new chromeos::CertificateHandler))); | 349 make_scoped_ptr(new chromeos::CertificateHandler))); |
351 } | 350 } |
352 } | 351 } |
353 return network_configuration_updater_.get(); | 352 return network_configuration_updater_.get(); |
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
488 return new AsyncPolicyProvider(loader.Pass()); | 487 return new AsyncPolicyProvider(loader.Pass()); |
489 } else { | 488 } else { |
490 return NULL; | 489 return NULL; |
491 } | 490 } |
492 #else | 491 #else |
493 return NULL; | 492 return NULL; |
494 #endif | 493 #endif |
495 } | 494 } |
496 | 495 |
497 } // namespace policy | 496 } // namespace policy |
OLD | NEW |