OLD | NEW |
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/mobile/mobile_activator.h" | 5 #include "chrome/browser/chromeos/mobile/mobile_activator.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 ErrorMap::iterator iter = error_map_.find(code); | 82 ErrorMap::iterator iter = error_map_.find(code); |
83 if (iter == error_map_.end()) | 83 if (iter == error_map_.end()) |
84 return code; | 84 return code; |
85 return iter->second; | 85 return iter->second; |
86 } | 86 } |
87 | 87 |
88 void CellularConfigDocument::LoadCellularConfigFile() { | 88 void CellularConfigDocument::LoadCellularConfigFile() { |
89 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::FILE)); | 89 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::FILE)); |
90 // Load partner customization startup manifest if it is available. | 90 // Load partner customization startup manifest if it is available. |
91 base::FilePath config_path(kCellularConfigPath); | 91 base::FilePath config_path(kCellularConfigPath); |
92 if (!file_util::PathExists(config_path)) | 92 if (!base::PathExists(config_path)) |
93 return; | 93 return; |
94 | 94 |
95 if (LoadFromFile(config_path)) | 95 if (LoadFromFile(config_path)) |
96 DVLOG(1) << "Cellular config file loaded: " << kCellularConfigPath; | 96 DVLOG(1) << "Cellular config file loaded: " << kCellularConfigPath; |
97 else | 97 else |
98 LOG(ERROR) << "Error loading cellular config file: " << kCellularConfigPath; | 98 LOG(ERROR) << "Error loading cellular config file: " << kCellularConfigPath; |
99 } | 99 } |
100 | 100 |
101 CellularConfigDocument::~CellularConfigDocument() {} | 101 CellularConfigDocument::~CellularConfigDocument() {} |
102 | 102 |
(...skipping 878 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
981 | 981 |
982 std::string MobileActivator::GetErrorMessage(const std::string& code) const { | 982 std::string MobileActivator::GetErrorMessage(const std::string& code) const { |
983 return cellular_config_->GetErrorMessage(code); | 983 return cellular_config_->GetErrorMessage(code); |
984 } | 984 } |
985 | 985 |
986 NetworkLibrary* MobileActivator::GetNetworkLibrary() const { | 986 NetworkLibrary* MobileActivator::GetNetworkLibrary() const { |
987 return CrosLibrary::Get()->GetNetworkLibrary(); | 987 return CrosLibrary::Get()->GetNetworkLibrary(); |
988 } | 988 } |
989 | 989 |
990 } // namespace chromeos | 990 } // namespace chromeos |
OLD | NEW |