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

Unified Diff: ash/common/system/chromeos/cast/tray_cast.cc

Issue 2761063002: Move more from WmShell to Shell (Closed)
Patch Set: merge Created 3 years, 9 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: ash/common/system/chromeos/cast/tray_cast.cc
diff --git a/ash/common/system/chromeos/cast/tray_cast.cc b/ash/common/system/chromeos/cast/tray_cast.cc
index 37132c9c0204667b5c261d8d5960a4aecbde4066..9da8418ddff494496e542ccb5f7cf3d9f7178124 100644
--- a/ash/common/system/chromeos/cast/tray_cast.cc
+++ b/ash/common/system/chromeos/cast/tray_cast.cc
@@ -128,7 +128,7 @@ CastCastView::CastCastView()
CastCastView::~CastCastView() {}
void CastCastView::StopCasting() {
- WmShell::Get()->cast_config()->StopCasting(displayed_route_.Clone());
+ Shell::Get()->cast_config()->StopCasting(displayed_route_.Clone());
WmShell::Get()->RecordUserMetricsAction(UMA_STATUS_AREA_CAST_STOP_CAST);
}
@@ -415,7 +415,7 @@ void CastDetailedView::HandleViewClicked(views::View* view) {
// Find the receiver we are going to cast to.
auto it = view_to_sink_map_.find(view);
if (it != view_to_sink_map_.end()) {
- WmShell::Get()->cast_config()->CastToSink(it->second.Clone());
+ Shell::Get()->cast_config()->CastToSink(it->second.Clone());
WmShell::Get()->RecordUserMetricsAction(
UMA_STATUS_AREA_DETAILED_CAST_VIEW_LAUNCH_CAST);
}
@@ -426,12 +426,12 @@ void CastDetailedView::HandleViewClicked(views::View* view) {
TrayCast::TrayCast(SystemTray* system_tray)
: SystemTrayItem(system_tray, UMA_CAST) {
Shell::GetInstance()->AddShellObserver(this);
- WmShell::Get()->cast_config()->AddObserver(this);
- WmShell::Get()->cast_config()->RequestDeviceRefresh();
+ Shell::Get()->cast_config()->AddObserver(this);
+ Shell::Get()->cast_config()->RequestDeviceRefresh();
}
TrayCast::~TrayCast() {
- WmShell::Get()->cast_config()->RemoveObserver(this);
+ Shell::Get()->cast_config()->RemoveObserver(this);
Shell::GetInstance()->RemoveShellObserver(this);
}
@@ -505,8 +505,7 @@ void TrayCast::OnDevicesUpdated(std::vector<mojom::SinkAndRoutePtr> devices) {
}
void TrayCast::UpdatePrimaryView() {
- if (WmShell::Get()->cast_config()->Connected() &&
- !sinks_and_routes_.empty()) {
+ if (Shell::Get()->cast_config()->Connected() && !sinks_and_routes_.empty()) {
if (default_) {
if (HasActiveRoute())
default_->ActivateCastView();
« no previous file with comments | « ash/common/system/chromeos/brightness/tray_brightness.cc ('k') | ash/common/system/chromeos/enterprise/tray_enterprise.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698