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

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

Issue 1849623002: Remove unused ash::SHELF_ALIGNMENT_TOP (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase 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
« no previous file with comments | « ash/shelf/shelf_widget.cc ('k') | ash/system/chromeos/screen_security/screen_tray_item.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/system/cast/tray_cast.h" 5 #include "ash/system/cast/tray_cast.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/chromeos/screen_security/screen_tray_item.h" 10 #include "ash/system/chromeos/screen_security/screen_tray_item.h"
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 } 353 }
354 354
355 CastTrayView::~CastTrayView() { 355 CastTrayView::~CastTrayView() {
356 } 356 }
357 357
358 void CastTrayView::UpdateAlignment(ShelfAlignment alignment) { 358 void CastTrayView::UpdateAlignment(ShelfAlignment alignment) {
359 // Center the item dependent on the orientation of the shelf. 359 // Center the item dependent on the orientation of the shelf.
360 views::BoxLayout::Orientation layout = views::BoxLayout::kHorizontal; 360 views::BoxLayout::Orientation layout = views::BoxLayout::kHorizontal;
361 switch (alignment) { 361 switch (alignment) {
362 case ash::SHELF_ALIGNMENT_BOTTOM: 362 case ash::SHELF_ALIGNMENT_BOTTOM:
363 case ash::SHELF_ALIGNMENT_TOP:
364 layout = views::BoxLayout::kHorizontal; 363 layout = views::BoxLayout::kHorizontal;
365 break; 364 break;
366 case ash::SHELF_ALIGNMENT_LEFT: 365 case ash::SHELF_ALIGNMENT_LEFT:
367 case ash::SHELF_ALIGNMENT_RIGHT: 366 case ash::SHELF_ALIGNMENT_RIGHT:
368 layout = views::BoxLayout::kVertical; 367 layout = views::BoxLayout::kVertical;
369 break; 368 break;
370 } 369 }
371 SetLayoutManager(new views::BoxLayout(layout, 0, 0, 0)); 370 SetLayoutManager(new views::BoxLayout(layout, 0, 0, 0));
372 Layout(); 371 Layout();
373 } 372 }
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after
679 is_casting_ = started; 678 is_casting_ = started;
680 UpdatePrimaryView(); 679 UpdatePrimaryView();
681 } 680 }
682 681
683 void TrayCast::UpdateAfterShelfAlignmentChange(ShelfAlignment alignment) { 682 void TrayCast::UpdateAfterShelfAlignmentChange(ShelfAlignment alignment) {
684 if (tray_) 683 if (tray_)
685 tray_->UpdateAlignment(alignment); 684 tray_->UpdateAlignment(alignment);
686 } 685 }
687 686
688 } // namespace ash 687 } // namespace ash
OLDNEW
« no previous file with comments | « ash/shelf/shelf_widget.cc ('k') | ash/system/chromeos/screen_security/screen_tray_item.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698