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

Side by Side Diff: chrome/browser/chromeos/cros/network_library.cc

Issue 12279012: Change the modem reset command on cellular activation completion. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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
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 "chrome/browser/chromeos/cros/network_library.h" 5 #include "chrome/browser/chromeos/cros/network_library.h"
6 6
7 #include "base/i18n/icu_encoding_detection.h" 7 #include "base/i18n/icu_encoding_detection.h"
8 #include "base/i18n/icu_string_conversions.h" 8 #include "base/i18n/icu_string_conversions.h"
9 #include "base/i18n/time_formatting.h" 9 #include "base/i18n/time_formatting.h"
10 #include "base/json/json_writer.h" // for debug output only. 10 #include "base/json/json_writer.h" // for debug output only.
(...skipping 859 matching lines...) Expand 10 before | Expand all | Expand 10 after
870 return false; 870 return false;
871 if (!CrosActivateCellularModem(service_path(), "")) 871 if (!CrosActivateCellularModem(service_path(), ""))
872 return false; 872 return false;
873 // Don't wait for shill to tell us that we are really activating since 873 // Don't wait for shill to tell us that we are really activating since
874 // other notifications in the message loop might cause us to think that 874 // other notifications in the message loop might cause us to think that
875 // the process hasn't started yet. 875 // the process hasn't started yet.
876 activation_state_ = ACTIVATION_STATE_ACTIVATING; 876 activation_state_ = ACTIVATION_STATE_ACTIVATING;
877 return true; 877 return true;
878 } 878 }
879 879
880 void CellularNetwork::CompleteActivation() {
881 if (!EnsureCrosLoaded())
882 return;
883 CrosCompleteCellularActivation(service_path());
884 }
885
880 void CellularNetwork::SetApn(const CellularApn& apn) { 886 void CellularNetwork::SetApn(const CellularApn& apn) {
881 if (!apn.apn.empty()) { 887 if (!apn.apn.empty()) {
882 DictionaryValue value; 888 DictionaryValue value;
883 // Only use the fields that are needed for establishing 889 // Only use the fields that are needed for establishing
884 // connections, and ignore the rest. 890 // connections, and ignore the rest.
885 value.SetString(flimflam::kApnProperty, apn.apn); 891 value.SetString(flimflam::kApnProperty, apn.apn);
886 value.SetString(flimflam::kApnNetworkIdProperty, apn.network_id); 892 value.SetString(flimflam::kApnNetworkIdProperty, apn.network_id);
887 value.SetString(flimflam::kApnUsernameProperty, apn.username); 893 value.SetString(flimflam::kApnUsernameProperty, apn.username);
888 value.SetString(flimflam::kApnPasswordProperty, apn.password); 894 value.SetString(flimflam::kApnPasswordProperty, apn.password);
889 SetValueProperty(flimflam::kCellularApnProperty, value); 895 SetValueProperty(flimflam::kCellularApnProperty, value);
(...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after
1377 NetworkLibrary* impl; 1383 NetworkLibrary* impl;
1378 if (stub) 1384 if (stub)
1379 impl = new NetworkLibraryImplStub(); 1385 impl = new NetworkLibraryImplStub();
1380 else 1386 else
1381 impl = new NetworkLibraryImplCros(); 1387 impl = new NetworkLibraryImplCros();
1382 impl->Init(); 1388 impl->Init();
1383 return impl; 1389 return impl;
1384 } 1390 }
1385 1391
1386 } // namespace chromeos 1392 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/cros/network_library.h ('k') | chrome/browser/chromeos/mobile/mobile_activator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698