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

Side by Side Diff: chromeos/network/onc/onc_translation_tables.cc

Issue 2844363003: [CrOS Tether] Add HasConnectedToHost property for Tether networks. (Closed)
Patch Set: Rebased. Created 3 years, 7 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
« no previous file with comments | « chromeos/network/onc/onc_signature.cc ('k') | chromeos/network/onc/onc_validator.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "chromeos/network/onc/onc_translation_tables.h" 5 #include "chromeos/network/onc/onc_translation_tables.h"
6 6
7 #include <cstddef> 7 #include <cstddef>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "chromeos/network/network_type_pattern.h" 10 #include "chromeos/network/network_type_pattern.h"
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 const FieldTranslationEntry vpn_fields[] = { 107 const FieldTranslationEntry vpn_fields[] = {
108 {::onc::vpn::kAutoConnect, shill::kAutoConnectProperty}, 108 {::onc::vpn::kAutoConnect, shill::kAutoConnectProperty},
109 // These fields are converted during translation, see onc_translator_*. 109 // These fields are converted during translation, see onc_translator_*.
110 // { ::onc::vpn::kHost, shill::kProviderHostProperty}, 110 // { ::onc::vpn::kHost, shill::kProviderHostProperty},
111 // { ::onc::vpn::kType, shill::kProviderTypeProperty }, 111 // { ::onc::vpn::kType, shill::kProviderTypeProperty },
112 {NULL}}; 112 {NULL}};
113 113
114 const FieldTranslationEntry tether_fields[] = { 114 const FieldTranslationEntry tether_fields[] = {
115 {::onc::tether::kBatteryPercentage, kTetherBatteryPercentage}, 115 {::onc::tether::kBatteryPercentage, kTetherBatteryPercentage},
116 {::onc::tether::kCarrier, kTetherCarrier}, 116 {::onc::tether::kCarrier, kTetherCarrier},
117 {::onc::tether::kHasConnectedToHost, kTetherHasConnectedToHost},
117 {::onc::tether::kSignalStrength, kTetherSignalStrength}, 118 {::onc::tether::kSignalStrength, kTetherSignalStrength},
118 {NULL}}; 119 {NULL}};
119 120
120 const FieldTranslationEntry wifi_fields[] = { 121 const FieldTranslationEntry wifi_fields[] = {
121 {::onc::wifi::kAutoConnect, shill::kAutoConnectProperty}, 122 {::onc::wifi::kAutoConnect, shill::kAutoConnectProperty},
122 {::onc::wifi::kBSSID, shill::kWifiBSsid}, 123 {::onc::wifi::kBSSID, shill::kWifiBSsid},
123 // This dictionary is converted during translation, see onc_translator_*. 124 // This dictionary is converted during translation, see onc_translator_*.
124 // { ::onc::wifi::kEAP, shill::kEap*}, 125 // { ::onc::wifi::kEAP, shill::kEap*},
125 {::onc::wifi::kFrequency, shill::kWifiFrequency}, 126 {::onc::wifi::kFrequency, shill::kWifiFrequency},
126 {::onc::wifi::kFrequencyList, shill::kWifiFrequencyListProperty}, 127 {::onc::wifi::kFrequencyList, shill::kWifiFrequencyListProperty},
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after
450 continue; 451 continue;
451 *onc_value = table[i].onc_value; 452 *onc_value = table[i].onc_value;
452 return true; 453 return true;
453 } 454 }
454 LOG(ERROR) << "Value '" << shill_value << "' cannot be translated to ONC"; 455 LOG(ERROR) << "Value '" << shill_value << "' cannot be translated to ONC";
455 return false; 456 return false;
456 } 457 }
457 458
458 } // namespace onc 459 } // namespace onc
459 } // namespace chromeos 460 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/network/onc/onc_signature.cc ('k') | chromeos/network/onc/onc_validator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698