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/tray/tray_background_view.cc

Issue 273223002: views: Make view::Views::GetPreferredSize() const. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: More compile fix for ToT Created 6 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 | Annotate | Revision Log
« no previous file with comments | « ash/system/tray/tray_background_view.h ('k') | ash/system/tray/tray_bar_button_with_title.h » ('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 (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/system/tray/tray_background_view.h" 5 #include "ash/system/tray/tray_background_view.h"
6 6
7 #include "ash/ash_switches.h" 7 #include "ash/ash_switches.h"
8 #include "ash/root_window_controller.h" 8 #include "ash/root_window_controller.h"
9 #include "ash/screen_util.h" 9 #include "ash/screen_util.h"
10 #include "ash/shelf/shelf_layout_manager.h" 10 #include "ash/shelf/shelf_layout_manager.h"
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 UpdateLayout(); 222 UpdateLayout();
223 } 223 }
224 224
225 void TrayBackgroundView::TrayContainer::SetAlignment(ShelfAlignment alignment) { 225 void TrayBackgroundView::TrayContainer::SetAlignment(ShelfAlignment alignment) {
226 if (alignment_ == alignment) 226 if (alignment_ == alignment)
227 return; 227 return;
228 alignment_ = alignment; 228 alignment_ = alignment;
229 UpdateLayout(); 229 UpdateLayout();
230 } 230 }
231 231
232 gfx::Size TrayBackgroundView::TrayContainer::GetPreferredSize() { 232 gfx::Size TrayBackgroundView::TrayContainer::GetPreferredSize() const {
233 if (size_.IsEmpty()) 233 if (size_.IsEmpty())
234 return views::View::GetPreferredSize(); 234 return views::View::GetPreferredSize();
235 return size_; 235 return size_;
236 } 236 }
237 237
238 void TrayBackgroundView::TrayContainer::ChildPreferredSizeChanged( 238 void TrayBackgroundView::TrayContainer::ChildPreferredSizeChanged(
239 views::View* child) { 239 views::View* child) {
240 PreferredSizeChanged(); 240 PreferredSizeChanged();
241 } 241 }
242 242
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
519 background_->set_alpha(kTrayBackgroundAlpha); 519 background_->set_alpha(kTrayBackgroundAlpha);
520 SchedulePaint(); 520 SchedulePaint();
521 } 521 }
522 522
523 void TrayBackgroundView::UpdateBubbleViewArrow( 523 void TrayBackgroundView::UpdateBubbleViewArrow(
524 views::TrayBubbleView* bubble_view) { 524 views::TrayBubbleView* bubble_view) {
525 // Nothing to do here. 525 // Nothing to do here.
526 } 526 }
527 527
528 } // namespace ash 528 } // namespace ash
OLDNEW
« no previous file with comments | « ash/system/tray/tray_background_view.h ('k') | ash/system/tray/tray_bar_button_with_title.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698