| Index: chromeos/components/tether/fake_host_scan_cache.cc
|
| diff --git a/chromeos/components/tether/fake_host_scan_cache.cc b/chromeos/components/tether/fake_host_scan_cache.cc
|
| index 917a13a0f0a44528e8166c0a008a497102efa928..fae2ff673e2d9c47dbc2fc786c53fb2940ed01b8 100644
|
| --- a/chromeos/components/tether/fake_host_scan_cache.cc
|
| +++ b/chromeos/components/tether/fake_host_scan_cache.cc
|
| @@ -51,7 +51,8 @@ void FakeHostScanCache::SetHostScanResult(
|
| const std::string& device_name,
|
| const std::string& carrier,
|
| int battery_percentage,
|
| - int signal_strength) {
|
| + int signal_strength,
|
| + bool setup_required) {
|
| auto it = cache_.find(tether_network_guid);
|
| if (it != cache_.end()) {
|
| // If already in the cache, update the cache with new values.
|
| @@ -59,13 +60,14 @@ void FakeHostScanCache::SetHostScanResult(
|
| it->second.carrier = carrier;
|
| it->second.battery_percentage = battery_percentage;
|
| it->second.signal_strength = signal_strength;
|
| + it->second.setup_required = setup_required;
|
| return;
|
| }
|
|
|
| // Otherwise, add a new entry.
|
| - cache_.emplace(
|
| - tether_network_guid,
|
| - CacheEntry{device_name, carrier, battery_percentage, signal_strength});
|
| + cache_.emplace(tether_network_guid,
|
| + CacheEntry{device_name, carrier, battery_percentage,
|
| + signal_strength, setup_required});
|
| }
|
|
|
| bool FakeHostScanCache::RemoveHostScanResult(
|
| @@ -86,6 +88,15 @@ void FakeHostScanCache::ClearCacheExceptForActiveHost() {
|
| }
|
| }
|
|
|
| +bool FakeHostScanCache::DoesHostRequireSetup(
|
| + const std::string& tether_network_guid) {
|
| + auto it = cache_.find(tether_network_guid);
|
| + if (it != cache_.end())
|
| + return it->second.setup_required;
|
| +
|
| + return false;
|
| +}
|
| +
|
| void FakeHostScanCache::OnPreviouslyConnectedHostIdsChanged() {}
|
|
|
| } // namespace tether
|
|
|