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

Side by Side Diff: ash/common/system/chromeos/network/tray_network.cc

Issue 2698473007: Convert path usage in NetworkListViewBase subclasses to use guids. (Closed)
Patch Set: Tweak NetworkPortalNotificationControllerTest to create GUIDs for new NetworkStates. Created 3 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
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 "ash/common/system/chromeos/network/tray_network.h" 5 #include "ash/common/system/chromeos/network/tray_network.h"
6 6
7 #include "ash/common/shelf/wm_shelf_util.h" 7 #include "ash/common/shelf/wm_shelf_util.h"
8 #include "ash/common/system/chromeos/network/network_icon.h" 8 #include "ash/common/system/chromeos/network/network_icon.h"
9 #include "ash/common/system/chromeos/network/network_icon_animation.h" 9 #include "ash/common/system/chromeos/network/network_icon_animation.h"
10 #include "ash/common/system/chromeos/network/network_icon_animation_observer.h" 10 #include "ash/common/system/chromeos/network/network_icon_animation_observer.h"
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after
316 PopupDetailedView(kTrayPopupAutoCloseDelayForTextInSeconds, false); 316 PopupDetailedView(kTrayPopupAutoCloseDelayForTextInSeconds, false);
317 } 317 }
318 NetworkStateHandler* handler = NetworkHandler::Get()->network_state_handler(); 318 NetworkStateHandler* handler = NetworkHandler::Get()->network_state_handler();
319 bool enabled = handler->IsTechnologyEnabled(NetworkTypePattern::WiFi()); 319 bool enabled = handler->IsTechnologyEnabled(NetworkTypePattern::WiFi());
320 WmShell::Get()->RecordUserMetricsAction( 320 WmShell::Get()->RecordUserMetricsAction(
321 enabled ? UMA_STATUS_AREA_DISABLE_WIFI : UMA_STATUS_AREA_ENABLE_WIFI); 321 enabled ? UMA_STATUS_AREA_DISABLE_WIFI : UMA_STATUS_AREA_ENABLE_WIFI);
322 handler->SetTechnologyEnabled(NetworkTypePattern::WiFi(), !enabled, 322 handler->SetTechnologyEnabled(NetworkTypePattern::WiFi(), !enabled,
323 chromeos::network_handler::ErrorCallback()); 323 chromeos::network_handler::ErrorCallback());
324 } 324 }
325 325
326 void TrayNetwork::OnCaptivePortalDetected( 326 void TrayNetwork::OnCaptivePortalDetected(const std::string& /* guid */) {
327 const std::string& /* service_path */) {
328 NetworkStateChanged(); 327 NetworkStateChanged();
329 } 328 }
330 329
331 void TrayNetwork::NetworkStateChanged() { 330 void TrayNetwork::NetworkStateChanged() {
332 if (tray_) 331 if (tray_)
333 tray_->UpdateNetworkStateHandlerIcon(); 332 tray_->UpdateNetworkStateHandlerIcon();
334 if (default_) 333 if (default_)
335 default_->Update(); 334 default_->Update();
336 if (detailed_) 335 if (detailed_)
337 detailed_->Update(); 336 detailed_->Update();
338 } 337 }
339 338
340 } // namespace ash 339 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/system/chromeos/network/tray_network.h ('k') | ash/common/system/chromeos/network/vpn_list_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698