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

Unified Diff: components/wifi/wifi_service_mac.mm

Issue 880143003: Add SSID getter to WiFiService (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add error param Created 5 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: components/wifi/wifi_service_mac.mm
diff --git a/components/wifi/wifi_service_mac.mm b/components/wifi/wifi_service_mac.mm
index 890b22906fc478fd042d7ce50ca3cab3168f8589..11f1a5d30ec874ef6e979baf9fdbc2a30bdc9dbb 100644
--- a/components/wifi/wifi_service_mac.mm
+++ b/components/wifi/wifi_service_mac.mm
@@ -76,6 +76,8 @@ class WiFiServiceMac : public WiFiService {
void RequestConnectedNetworkUpdate() override;
+ void GetConnectedNetworkGUID(std::string* guid, std::string* error) override;
+
private:
// Checks |ns_error| and if is not |nil|, then stores |error_name|
// into |error|.
@@ -416,6 +418,12 @@ void WiFiServiceMac::RequestConnectedNetworkUpdate() {
OnWlanObserverNotification();
}
+void WiFiServiceMac::GetConnectedNetworkGUID(std::string* guid,
+ std::string* error) {
+ *guid = GUIDFromSSID([interface_ ssid]);
+ *error = "";
+}
+
std::string WiFiServiceMac::GetNetworkConnectionState(
const std::string& network_guid) const {
if (network_guid != GUIDFromSSID([interface_ ssid]))

Powered by Google App Engine
This is Rietveld 408576698