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

Unified Diff: ash/system/chromeos/network/tray_vpn.cc

Issue 2099443002: Migrate simple ash Shell metrics users. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix win compile error. Created 4 years, 6 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/system/chromeos/network/tray_network.cc ('k') | ash/system/chromeos/network/vpn_list_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/system/chromeos/network/tray_vpn.cc
diff --git a/ash/system/chromeos/network/tray_vpn.cc b/ash/system/chromeos/network/tray_vpn.cc
index 42db330440ca01a8ae7c02033bf6ca498531d7ce..5d6033d5cdafa11bacd12637f82787fefce66a7b 100644
--- a/ash/system/chromeos/network/tray_vpn.cc
+++ b/ash/system/chromeos/network/tray_vpn.cc
@@ -10,8 +10,6 @@
#include "ash/common/system/tray/tray_item_more.h"
#include "ash/common/system/tray/tray_popup_label_button.h"
#include "ash/common/wm_shell.h"
-#include "ash/metrics/user_metrics_recorder.h"
-#include "ash/shell.h"
#include "ash/system/chromeos/network/network_state_list_detailed_view.h"
#include "ash/system/chromeos/network/vpn_delegate.h"
#include "ash/system/tray/system_tray.h"
@@ -134,12 +132,11 @@ views::View* TrayVPN::CreateDefaultView(LoginStatus status) {
if (!tray::VpnDefaultView::ShouldShow())
return NULL;
- bool userAddingRunning = ash::Shell::GetInstance()
- ->session_state_delegate()
- ->IsInSecondaryLoginScreen();
+ const bool is_in_secondary_login_screen =
+ WmShell::Get()->GetSessionStateDelegate()->IsInSecondaryLoginScreen();
default_ = new tray::VpnDefaultView(
- this, status != LoginStatus::LOCKED && !userAddingRunning);
+ this, status != LoginStatus::LOCKED && !is_in_secondary_login_screen);
return default_;
}
@@ -149,8 +146,7 @@ views::View* TrayVPN::CreateDetailedView(LoginStatus status) {
if (!chromeos::NetworkHandler::IsInitialized())
return NULL;
- Shell::GetInstance()->metrics()->RecordUserMetricsAction(
- ash::UMA_STATUS_AREA_DETAILED_VPN_VIEW);
+ WmShell::Get()->RecordUserMetricsAction(UMA_STATUS_AREA_DETAILED_VPN_VIEW);
detailed_ = new tray::NetworkStateListDetailedView(
this, tray::NetworkStateListDetailedView::LIST_TYPE_VPN, status);
detailed_->Init();
« no previous file with comments | « ash/system/chromeos/network/tray_network.cc ('k') | ash/system/chromeos/network/vpn_list_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698