Chromium Code Reviews| Index: chromeos/network/network_state_handler.h |
| diff --git a/chromeos/network/network_state_handler.h b/chromeos/network/network_state_handler.h |
| index 3265b00141c167c6fb162db3ff6a8bcd7cd1ba88..6fc19b4e26fd652c6a5f7ec640714623ed300446 100644 |
| --- a/chromeos/network/network_state_handler.h |
| +++ b/chromeos/network/network_state_handler.h |
| @@ -112,6 +112,17 @@ class CHROMEOS_EXPORT NetworkStateHandler |
| bool enabled, |
| const network_handler::ErrorCallback& error_callback); |
| + // Sets the tether technology state. Because Tether networks do not represent |
| + // real Shill networks, this value must be set by the tether component rather |
| + // than being generated by Shill. See TetherDeviceStateManager for more |
| + // details. |
| + void SetTetherTechnologyState(TechnologyState technology_state); |
| + |
| + // Sets the scanning state of the tether technology. Since tether network |
| + // scans are not actually performed as part of Shill, this value must be set |
| + // by the tether component. |
| + void SetTetherScanState(bool is_scanning); |
| + |
| // Asynchronously sets the list of prohibited technologies. The accepted |
| // values are the shill network technology identifiers. See also |
| // chromeos::onc::Validator::ValidateGlobalNetworkConfiguration(). |
| @@ -250,7 +261,11 @@ class CHROMEOS_EXPORT NetworkStateHandler |
| DeviceStateList* list) const; |
| // Requests a network scan. This may trigger updates to the network |
| - // list, which will trigger the appropriate observer calls. |
| + // list, which will trigger the appropriate observer calls. Note that this |
| + // function does not request a tether scan. |
| + // TODO(khorimoto): Add an also_scan_for_tether parameter. Tether scans should |
| + // not occur during start-up, but they should occur when opening networking |
| + // UI. |
|
stevenjb
2017/04/20 16:49:42
I don't think we should put that logic in the star
Kyle Horimoto
2017/04/20 19:38:46
Done.
|
| void RequestScan() const; |
| // Requests an update for an existing NetworkState, e.g. after configuring |
| @@ -259,7 +274,7 @@ class CHROMEOS_EXPORT NetworkStateHandler |
| // acknowledged it (e.g. in the callback of a SetProperties). |
| // When the properties are received, NetworkPropertiesUpdated will be |
| // signaled for each member of |observers_|, regardless of whether any |
| - // properties actually changed. |
| + // properties actually changed. Note that this is a no-op for Tether networks. |
| void RequestUpdateForNetwork(const std::string& service_path); |
| // Informs NetworkStateHandler to notify observers that the properties for |
| @@ -482,6 +497,12 @@ class CHROMEOS_EXPORT NetworkStateHandler |
| // NetworkState that is not saved in a profile. |
| SpecifierGuidMap specifier_guid_map_; |
| + // The state corresponding to the tether device type. Initialized to |
| + // PROHIBITED; this value is changed by the tether component when it starts |
| + // up. |
|
stevenjb
2017/04/20 16:49:42
nit: s/is changed by the tether component when it
Kyle Horimoto
2017/04/20 19:38:46
Done.
|
| + TechnologyState tether_technology_state_ = |
| + TechnologyState::TECHNOLOGY_PROHIBITED; |
|
stevenjb
2017/04/20 18:29:07
This should be initialized to UNAVAILABLE which sh
Kyle Horimoto
2017/04/20 19:38:46
Done.
|
| + |
| // Ensure that Shutdown() gets called exactly once. |
| bool did_shutdown_ = false; |