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

Side by Side Diff: ash/common/system/tray/system_tray.cc

Issue 2563943002: Revert of Add test for system tray network menu icon for extension-controlled networks (Closed)
Patch Set: Created 4 years 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/tray/system_tray.h" 5 #include "ash/common/system/tray/system_tray.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
209 : TrayBackgroundView(wm_shelf), 209 : TrayBackgroundView(wm_shelf),
210 web_notification_tray_(nullptr), 210 web_notification_tray_(nullptr),
211 detailed_item_(nullptr), 211 detailed_item_(nullptr),
212 default_bubble_height_(0), 212 default_bubble_height_(0),
213 hide_notifications_(false), 213 hide_notifications_(false),
214 full_system_tray_menu_(false), 214 full_system_tray_menu_(false),
215 tray_accessibility_(nullptr), 215 tray_accessibility_(nullptr),
216 tray_audio_(nullptr), 216 tray_audio_(nullptr),
217 tray_cast_(nullptr), 217 tray_cast_(nullptr),
218 tray_date_(nullptr), 218 tray_date_(nullptr),
219 tray_network_(nullptr),
220 tray_tiles_(nullptr), 219 tray_tiles_(nullptr),
221 tray_system_info_(nullptr), 220 tray_system_info_(nullptr),
222 tray_update_(nullptr), 221 tray_update_(nullptr),
223 screen_capture_tray_item_(nullptr), 222 screen_capture_tray_item_(nullptr),
224 screen_share_tray_item_(nullptr) { 223 screen_share_tray_item_(nullptr) {
225 if (MaterialDesignController::IsShelfMaterial()) { 224 if (MaterialDesignController::IsShelfMaterial()) {
226 SetInkDropMode(InkDropMode::ON); 225 SetInkDropMode(InkDropMode::ON);
227 SetContentsBackground(false); 226 SetContentsBackground(false);
228 } else { 227 } else {
229 SetContentsBackground(true); 228 SetContentsBackground(true);
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 tray_update_ = new TrayUpdate(this); 283 tray_update_ = new TrayUpdate(this);
285 284
286 #if defined(OS_CHROMEOS) 285 #if defined(OS_CHROMEOS)
287 AddTrayItem(new TraySessionLengthLimit(this)); 286 AddTrayItem(new TraySessionLengthLimit(this));
288 AddTrayItem(new TrayEnterprise(this)); 287 AddTrayItem(new TrayEnterprise(this));
289 AddTrayItem(new TraySupervisedUser(this)); 288 AddTrayItem(new TraySupervisedUser(this));
290 AddTrayItem(new TrayIME(this)); 289 AddTrayItem(new TrayIME(this));
291 AddTrayItem(tray_accessibility_); 290 AddTrayItem(tray_accessibility_);
292 AddTrayItem(new TrayTracing(this)); 291 AddTrayItem(new TrayTracing(this));
293 AddTrayItem(new TrayPower(this, message_center::MessageCenter::Get())); 292 AddTrayItem(new TrayPower(this, message_center::MessageCenter::Get()));
294 tray_network_ = new TrayNetwork(this); 293 AddTrayItem(new TrayNetwork(this));
295 AddTrayItem(tray_network_);
296 AddTrayItem(new TrayVPN(this)); 294 AddTrayItem(new TrayVPN(this));
297 AddTrayItem(new TraySms(this)); 295 AddTrayItem(new TraySms(this));
298 AddTrayItem(new TrayBluetooth(this)); 296 AddTrayItem(new TrayBluetooth(this));
299 tray_cast_ = new TrayCast(this); 297 tray_cast_ = new TrayCast(this);
300 AddTrayItem(tray_cast_); 298 AddTrayItem(tray_cast_);
301 screen_capture_tray_item_ = new ScreenCaptureTrayItem(this); 299 screen_capture_tray_item_ = new ScreenCaptureTrayItem(this);
302 AddTrayItem(screen_capture_tray_item_); 300 AddTrayItem(screen_capture_tray_item_);
303 screen_share_tray_item_ = new ScreenShareTrayItem(this); 301 screen_share_tray_item_ = new ScreenShareTrayItem(this);
304 AddTrayItem(screen_share_tray_item_); 302 AddTrayItem(screen_share_tray_item_);
305 AddTrayItem(new MultiProfileMediaTrayItem(this)); 303 AddTrayItem(new MultiProfileMediaTrayItem(this));
(...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after
803 } 801 }
804 802
805 TrayCast* SystemTray::GetTrayCastForTesting() const { 803 TrayCast* SystemTray::GetTrayCastForTesting() const {
806 return tray_cast_; 804 return tray_cast_;
807 } 805 }
808 806
809 TrayDate* SystemTray::GetTrayDateForTesting() const { 807 TrayDate* SystemTray::GetTrayDateForTesting() const {
810 return tray_date_; 808 return tray_date_;
811 } 809 }
812 810
813 TrayNetwork* SystemTray::GetTrayNetworkForTesting() const {
814 return tray_network_;
815 }
816
817 TraySystemInfo* SystemTray::GetTraySystemInfoForTesting() const { 811 TraySystemInfo* SystemTray::GetTraySystemInfoForTesting() const {
818 return tray_system_info_; 812 return tray_system_info_;
819 } 813 }
820 814
821 TrayTiles* SystemTray::GetTrayTilesForTesting() const { 815 TrayTiles* SystemTray::GetTrayTilesForTesting() const {
822 return tray_tiles_; 816 return tray_tiles_;
823 } 817 }
824 818
825 TrayUpdate* SystemTray::GetTrayUpdateForTesting() const { 819 TrayUpdate* SystemTray::GetTrayUpdateForTesting() const {
826 return tray_update_; 820 return tray_update_;
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
915 .work_area() 909 .work_area()
916 .height(); 910 .height();
917 if (work_area_height > 0) { 911 if (work_area_height > 0) {
918 UMA_HISTOGRAM_CUSTOM_COUNTS( 912 UMA_HISTOGRAM_CUSTOM_COUNTS(
919 "Ash.SystemMenu.PercentageOfWorkAreaHeightCoveredByMenu", 913 "Ash.SystemMenu.PercentageOfWorkAreaHeightCoveredByMenu",
920 100 * bubble_view->height() / work_area_height, 1, 300, 100); 914 100 * bubble_view->height() / work_area_height, 1, 300, 100);
921 } 915 }
922 } 916 }
923 917
924 } // namespace ash 918 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/system/tray/system_tray.h ('k') | chrome/browser/ui/ash/networking_config_delegate_chromeos_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698