| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/chromeos/ui_proxy_config_service.h" | 5 #include "chrome/browser/chromeos/ui_proxy_config_service.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "base/values.h" | 9 #include "base/values.h" |
| 10 #include "chrome/browser/chromeos/net/proxy_config_handler.h" | 10 #include "chrome/browser/chromeos/net/proxy_config_handler.h" |
| 11 #include "chrome/browser/chromeos/proxy_config_service_impl.h" | 11 #include "chrome/browser/chromeos/proxy_config_service_impl.h" |
| 12 #include "chromeos/network/network_state.h" | 12 #include "chromeos/network/network_state.h" |
| 13 #include "chromeos/network/network_state_handler.h" | 13 #include "chromeos/network/network_state_handler.h" |
| 14 #include "components/device_event_log/device_event_log.h" | 14 #include "components/device_event_log/device_event_log.h" |
| 15 #include "components/proxy_config/pref_proxy_config_tracker_impl.h" |
| 15 #include "net/proxy/proxy_config.h" | 16 #include "net/proxy/proxy_config.h" |
| 16 | 17 |
| 17 namespace chromeos { | 18 namespace chromeos { |
| 18 | 19 |
| 19 namespace { | 20 namespace { |
| 20 | 21 |
| 21 const char* ModeToString(UIProxyConfig::Mode mode) { | 22 const char* ModeToString(UIProxyConfig::Mode mode) { |
| 22 switch (mode) { | 23 switch (mode) { |
| 23 case UIProxyConfig::MODE_DIRECT: | 24 case UIProxyConfig::MODE_DIRECT: |
| 24 return "direct"; | 25 return "direct"; |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 175 } else if (!IsNetworkProxySettingsEditable(onc_source)) { | 176 } else if (!IsNetworkProxySettingsEditable(onc_source)) { |
| 176 current_ui_config_.state = ProxyPrefs::CONFIG_POLICY; | 177 current_ui_config_.state = ProxyPrefs::CONFIG_POLICY; |
| 177 current_ui_config_.user_modifiable = false; | 178 current_ui_config_.user_modifiable = false; |
| 178 } else { | 179 } else { |
| 179 current_ui_config_.user_modifiable = !ProxyConfigServiceImpl::IgnoreProxy( | 180 current_ui_config_.user_modifiable = !ProxyConfigServiceImpl::IgnoreProxy( |
| 180 profile_prefs_, network.profile_path(), onc_source); | 181 profile_prefs_, network.profile_path(), onc_source); |
| 181 } | 182 } |
| 182 } | 183 } |
| 183 | 184 |
| 184 } // namespace chromeos | 185 } // namespace chromeos |
| OLD | NEW |