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

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

Issue 14566009: Add NetworkConnectionHandler class (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Revert Associating Stub change for test Created 7 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 | Annotate | Revision Log
« no previous file with comments | « chromeos/network/network_ui_data.h ('k') | chromeos/network/network_ui_data_unittest.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/network_ui_data.h" 5 #include "chromeos/network/network_ui_data.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/values.h" 8 #include "base/values.h"
9 #include "chromeos/network/onc/onc_signature.h" 9 #include "chromeos/network/onc/onc_signature.h"
10 10
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 const onc::OncFieldSignature* field_signature = 211 const onc::OncFieldSignature* field_signature =
212 GetFieldSignature(signature, it.key()); 212 GetFieldSignature(signature, it.key());
213 213
214 TranslateONCHierarchy(*field_signature->value_signature, *inner_object, 214 TranslateONCHierarchy(*field_signature->value_signature, *inner_object,
215 ui_data); 215 ui_data);
216 } 216 }
217 } 217 }
218 218
219 } // namespace 219 } // namespace
220 220
221 scoped_ptr<NetworkUIData> CreateUIDataFromONC( 221 // static
222 scoped_ptr<NetworkUIData> NetworkUIData::CreateFromONC(
222 onc::ONCSource onc_source, 223 onc::ONCSource onc_source,
223 const base::DictionaryValue& onc_network) { 224 const base::DictionaryValue& onc_network) {
224 scoped_ptr<NetworkUIData> ui_data(new NetworkUIData()); 225 scoped_ptr<NetworkUIData> ui_data(new NetworkUIData());
225 TranslateONCHierarchy(onc::kNetworkConfigurationSignature, onc_network, 226 TranslateONCHierarchy(onc::kNetworkConfigurationSignature, onc_network,
226 ui_data.get()); 227 ui_data.get());
227 228
228 ui_data->set_onc_source(onc_source); 229 ui_data->set_onc_source(onc_source);
229 230
230 return ui_data.Pass(); 231 return ui_data.Pass();
231 } 232 }
232 233
233 } // namespace chromeos 234 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/network/network_ui_data.h ('k') | chromeos/network/network_ui_data_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698