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

Unified Diff: ash/common/system/chromeos/network/network_state_list_detailed_view.cc

Issue 2311093004: Bug fix to toggle Network scanning indicator for WiFi (Closed)
Patch Set: Bug fix to toggle Network scanning indicator for WiFi Created 4 years, 3 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
« no previous file with comments | « ash/common/system/chromeos/network/network_state_list_detailed_view.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/system/chromeos/network/network_state_list_detailed_view.cc
diff --git a/ash/common/system/chromeos/network/network_state_list_detailed_view.cc b/ash/common/system/chromeos/network/network_state_list_detailed_view.cc
index 142bb4ec51f0995caf46001c60b4f67f099f9812..891dd1993293ee49430b92cb09e56a64ad9dcd3d 100644
--- a/ash/common/system/chromeos/network/network_state_list_detailed_view.cc
+++ b/ash/common/system/chromeos/network/network_state_list_detailed_view.cc
@@ -309,7 +309,7 @@ NetworkStateListDetailedView::NetworkStateListDetailedView(
: NetworkDetailedView(owner),
list_type_(list_type),
login_(login),
- wifi_scanning_(false),
+ prev_wifi_scanning_state_(false),
jdufault 2016/09/06 22:19:19 Since you're already in this file, can you initial
info_icon_(nullptr),
button_wifi_(nullptr),
button_mobile_(nullptr),
@@ -566,15 +566,15 @@ void NetworkStateListDetailedView::UpdateHeaderButtons() {
if (proxy_settings_)
proxy_settings_->SetEnabled(handler->DefaultNetwork() != nullptr);
- if (list_type_ != LIST_TYPE_VPN) {
+ if (list_type_ != LIST_TYPE_VPN &&
+ !MaterialDesignController::IsSystemTrayMenuMaterial()) {
// Update Wifi Scanning throbber.
bool scanning =
NetworkHandler::Get()->network_state_handler()->GetScanningByType(
NetworkTypePattern::WiFi());
- if (scanning != wifi_scanning_ &&
- !MaterialDesignController::IsSystemTrayMenuMaterial()) {
- wifi_scanning_ = scanning;
- if (list_type_ != LIST_TYPE_VPN) {
+ if (scanning != prev_wifi_scanning_state_) {
+ prev_wifi_scanning_state_ = scanning;
+ if (scanning) {
SetScanningStateForThrobberView(true);
// Start animation on the |scanning_throbber_| indicator.
« no previous file with comments | « ash/common/system/chromeos/network/network_state_list_detailed_view.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698