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

Side by Side Diff: ash/common/system/cast/tray_cast.cc

Issue 2162153002: Added Ash.SystemMenu.DefaultView.VisibleItems histogram. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed the COUNT value from the SystemMenuDefaultViewRows enum. Created 4 years, 5 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/cast/tray_cast.h" 5 #include "ash/common/system/cast/tray_cast.h"
6 6
7 #include "ash/common/session/session_state_delegate.h" 7 #include "ash/common/session/session_state_delegate.h"
8 #include "ash/common/shelf/shelf_types.h" 8 #include "ash/common/shelf/shelf_types.h"
9 #include "ash/common/shelf/wm_shelf_util.h" 9 #include "ash/common/shelf/wm_shelf_util.h"
10 #include "ash/common/system/chromeos/screen_security/screen_tray_item.h" 10 #include "ash/common/system/chromeos/screen_security/screen_tray_item.h"
(...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after
525 if (it != receiver_activity_map_.end()) { 525 if (it != receiver_activity_map_.end()) {
526 cast_config_delegate->CastToReceiver(it->second); 526 cast_config_delegate->CastToReceiver(it->second);
527 WmShell::Get()->RecordUserMetricsAction( 527 WmShell::Get()->RecordUserMetricsAction(
528 UMA_STATUS_AREA_DETAILED_CAST_VIEW_LAUNCH_CAST); 528 UMA_STATUS_AREA_DETAILED_CAST_VIEW_LAUNCH_CAST);
529 } 529 }
530 } 530 }
531 } 531 }
532 532
533 } // namespace tray 533 } // namespace tray
534 534
535 TrayCast::TrayCast(SystemTray* system_tray) : SystemTrayItem(system_tray) { 535 TrayCast::TrayCast(SystemTray* system_tray)
536 : SystemTrayItem(system_tray, UMA_CAST) {
536 WmShell::Get()->AddShellObserver(this); 537 WmShell::Get()->AddShellObserver(this);
537 } 538 }
538 539
539 TrayCast::~TrayCast() { 540 TrayCast::~TrayCast() {
540 WmShell::Get()->RemoveShellObserver(this); 541 WmShell::Get()->RemoveShellObserver(this);
541 if (added_observer_) 542 if (added_observer_)
542 GetCastConfigDelegate()->RemoveObserver(this); 543 GetCastConfigDelegate()->RemoveObserver(this);
543 } 544 }
544 545
545 void TrayCast::StartCastForTest(const std::string& receiver_id) { 546 void TrayCast::StartCastForTest(const std::string& receiver_id) {
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
661 is_casting_ = started; 662 is_casting_ = started;
662 UpdatePrimaryView(); 663 UpdatePrimaryView();
663 } 664 }
664 665
665 void TrayCast::UpdateAfterShelfAlignmentChange(ShelfAlignment alignment) { 666 void TrayCast::UpdateAfterShelfAlignmentChange(ShelfAlignment alignment) {
666 if (tray_) 667 if (tray_)
667 tray_->UpdateAlignment(alignment); 668 tray_->UpdateAlignment(alignment);
668 } 669 }
669 670
670 } // namespace ash 671 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/system/audio/volume_view.cc ('k') | ash/common/system/chromeos/bluetooth/tray_bluetooth.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698