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

Side by Side Diff: chromeos/network/policy_util.cc

Issue 24348002: Migrate DBus service constants from flimflam namespace to shill namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased to ToT Created 7 years, 3 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/policy_applicator.cc ('k') | chromeos/network/shill_property_handler.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 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 "chromeos/network/policy_util.h" 5 #include "chromeos/network/policy_util.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "chromeos/network/network_profile.h" 8 #include "chromeos/network/network_profile.h"
9 #include "chromeos/network/network_ui_data.h" 9 #include "chromeos/network/network_ui_data.h"
10 #include "chromeos/network/onc/onc_constants.h" 10 #include "chromeos/network/onc/onc_constants.h"
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 147
148 // Remove irrelevant fields. 148 // Remove irrelevant fields.
149 onc::Normalizer normalizer(true /* remove recommended fields */); 149 onc::Normalizer normalizer(true /* remove recommended fields */);
150 effective = normalizer.NormalizeObject(&onc::kNetworkConfigurationSignature, 150 effective = normalizer.NormalizeObject(&onc::kNetworkConfigurationSignature,
151 *effective); 151 *effective);
152 152
153 scoped_ptr<base::DictionaryValue> shill_dictionary( 153 scoped_ptr<base::DictionaryValue> shill_dictionary(
154 onc::TranslateONCObjectToShill(&onc::kNetworkConfigurationSignature, 154 onc::TranslateONCObjectToShill(&onc::kNetworkConfigurationSignature,
155 *effective)); 155 *effective));
156 156
157 shill_dictionary->SetStringWithoutPathExpansion(flimflam::kProfileProperty, 157 shill_dictionary->SetStringWithoutPathExpansion(shill::kProfileProperty,
158 profile.path); 158 profile.path);
159 159
160 scoped_ptr<NetworkUIData> ui_data; 160 scoped_ptr<NetworkUIData> ui_data;
161 if (policy) 161 if (policy)
162 ui_data = NetworkUIData::CreateFromONC(onc_source, *policy); 162 ui_data = NetworkUIData::CreateFromONC(onc_source, *policy);
163 else 163 else
164 ui_data.reset(new NetworkUIData()); 164 ui_data.reset(new NetworkUIData());
165 165
166 if (settings) { 166 if (settings) {
167 // Shill doesn't know that sensitive data is contained in the UIData 167 // Shill doesn't know that sensitive data is contained in the UIData
(...skipping 24 matching lines...) Expand all
192 it != policies.end(); ++it) { 192 it != policies.end(); ++it) {
193 if (IsPolicyMatching(*it->second, actual_network)) 193 if (IsPolicyMatching(*it->second, actual_network))
194 return it->second; 194 return it->second;
195 } 195 }
196 return NULL; 196 return NULL;
197 } 197 }
198 198
199 } // namespace policy_util 199 } // namespace policy_util
200 200
201 } // namespace chromeos 201 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/network/policy_applicator.cc ('k') | chromeos/network/shill_property_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698