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

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

Issue 1849623002: Remove unused ash::SHELF_ALIGNMENT_TOP (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix autoformat problem with <x, >y Created 4 years, 8 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/session/session_state_delegate.h" 7 #include "ash/session/session_state_delegate.h"
8 #include "ash/shelf/shelf_types.h" 8 #include "ash/shelf/shelf_types.h"
9 #include "ash/shell.h" 9 #include "ash/shell.h"
10 #include "ash/system/tray/system_tray_delegate.h" 10 #include "ash/system/tray/system_tray_delegate.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 100
101 void OverviewButtonTray::SetShelfAlignment(ShelfAlignment alignment) { 101 void OverviewButtonTray::SetShelfAlignment(ShelfAlignment alignment) {
102 if (alignment == shelf_alignment()) 102 if (alignment == shelf_alignment())
103 return; 103 return;
104 104
105 TrayBackgroundView::SetShelfAlignment(alignment); 105 TrayBackgroundView::SetShelfAlignment(alignment);
106 SetIconBorderForShelfAlignment(); 106 SetIconBorderForShelfAlignment();
107 } 107 }
108 108
109 void OverviewButtonTray::SetIconBorderForShelfAlignment() { 109 void OverviewButtonTray::SetIconBorderForShelfAlignment() {
110 if (shelf_alignment() == SHELF_ALIGNMENT_BOTTOM || 110 if (shelf_alignment() == SHELF_ALIGNMENT_BOTTOM) {
111 shelf_alignment() == SHELF_ALIGNMENT_TOP) {
112 icon_->SetBorder(views::Border::CreateEmptyBorder( 111 icon_->SetBorder(views::Border::CreateEmptyBorder(
113 kHorizontalShelfVerticalPadding, 112 kHorizontalShelfVerticalPadding,
114 kHorizontalShelfHorizontalPadding, 113 kHorizontalShelfHorizontalPadding,
115 kHorizontalShelfVerticalPadding, 114 kHorizontalShelfVerticalPadding,
116 kHorizontalShelfHorizontalPadding)); 115 kHorizontalShelfHorizontalPadding));
117 } else { 116 } else {
118 icon_->SetBorder(views::Border::CreateEmptyBorder( 117 icon_->SetBorder(views::Border::CreateEmptyBorder(
119 kVerticalShelfVerticalPadding, 118 kVerticalShelfVerticalPadding,
120 kVerticalShelfHorizontalPadding, 119 kVerticalShelfHorizontalPadding,
121 kVerticalShelfVerticalPadding, 120 kVerticalShelfVerticalPadding,
(...skipping 14 matching lines...) Expand all
136 shell->maximize_mode_controller()->IsMaximizeModeWindowManagerEnabled() && 135 shell->maximize_mode_controller()->IsMaximizeModeWindowManagerEnabled() &&
137 session_state_delegate->IsActiveUserSessionStarted() && 136 session_state_delegate->IsActiveUserSessionStarted() &&
138 !session_state_delegate->IsScreenLocked() && 137 !session_state_delegate->IsScreenLocked() &&
139 session_state_delegate->GetSessionState() == 138 session_state_delegate->GetSessionState() ==
140 SessionStateDelegate::SESSION_STATE_ACTIVE && 139 SessionStateDelegate::SESSION_STATE_ACTIVE &&
141 shell->system_tray_delegate()->GetUserLoginStatus() != 140 shell->system_tray_delegate()->GetUserLoginStatus() !=
142 user::LOGGED_IN_KIOSK_APP); 141 user::LOGGED_IN_KIOSK_APP);
143 } 142 }
144 143
145 } // namespace ash 144 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698