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

Side by Side Diff: ash/system/overview/overview_button_tray.cc

Issue 2864663002: cros: Merge SystemTrayDelegate::GetUserLoginStatus (Closed)
Patch Set: Created 3 years, 7 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/system/overview/overview_button_tray.h" 5 #include "ash/system/overview/overview_button_tray.h"
6 6
7 #include "ash/resources/vector_icons/vector_icons.h" 7 #include "ash/resources/vector_icons/vector_icons.h"
8 #include "ash/session/session_controller.h" 8 #include "ash/session/session_controller.h"
9 #include "ash/shelf/shelf_constants.h" 9 #include "ash/shelf/shelf_constants.h"
10 #include "ash/shell.h" 10 #include "ash/shell.h"
11 #include "ash/shell_port.h" 11 #include "ash/shell_port.h"
12 #include "ash/strings/grit/ash_strings.h" 12 #include "ash/strings/grit/ash_strings.h"
13 #include "ash/system/tray/system_tray_delegate.h"
14 #include "ash/system/tray/tray_constants.h" 13 #include "ash/system/tray/tray_constants.h"
15 #include "ash/system/tray/tray_container.h" 14 #include "ash/system/tray/tray_container.h"
16 #include "ash/wm/maximize_mode/maximize_mode_controller.h" 15 #include "ash/wm/maximize_mode/maximize_mode_controller.h"
17 #include "ash/wm/overview/window_selector_controller.h" 16 #include "ash/wm/overview/window_selector_controller.h"
18 #include "ui/base/l10n/l10n_util.h" 17 #include "ui/base/l10n/l10n_util.h"
19 #include "ui/gfx/paint_vector_icon.h" 18 #include "ui/gfx/paint_vector_icon.h"
20 #include "ui/views/border.h" 19 #include "ui/views/border.h"
21 #include "ui/views/controls/image_view.h" 20 #include "ui/views/controls/image_view.h"
22 21
23 namespace ash { 22 namespace ash {
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 // a modal dialog is present. 99 // a modal dialog is present.
101 SessionController* session_controller = Shell::Get()->session_controller(); 100 SessionController* session_controller = Shell::Get()->session_controller();
102 101
103 Shell* shell = Shell::Get(); 102 Shell* shell = Shell::Get();
104 SetVisible( 103 SetVisible(
105 shell->maximize_mode_controller()->IsMaximizeModeWindowManagerEnabled() && 104 shell->maximize_mode_controller()->IsMaximizeModeWindowManagerEnabled() &&
106 session_controller->IsActiveUserSessionStarted() && 105 session_controller->IsActiveUserSessionStarted() &&
107 !session_controller->IsScreenLocked() && 106 !session_controller->IsScreenLocked() &&
108 session_controller->GetSessionState() == 107 session_controller->GetSessionState() ==
109 session_manager::SessionState::ACTIVE && 108 session_manager::SessionState::ACTIVE &&
110 shell->system_tray_delegate()->GetUserLoginStatus() != 109 session_controller->login_status() != LoginStatus::KIOSK_APP &&
James Cook 2017/05/05 17:51:53 optional: WDYT of adding either SessionController:
xiyuan 2017/05/05 18:36:33 Added a SessionController::IsKioskSession() and up
111 LoginStatus::KIOSK_APP && 110 session_controller->login_status() != LoginStatus::ARC_KIOSK_APP);
112 shell->system_tray_delegate()->GetUserLoginStatus() !=
113 LoginStatus::ARC_KIOSK_APP);
114 } 111 }
115 112
116 } // namespace ash 113 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698