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

Unified Diff: ash/shelf/shelf_view.cc

Issue 2823133002: Clean up some ash constants. (Closed)
Patch Set: updates Created 3 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 side-by-side diff with in-line comments
Download patch
Index: ash/shelf/shelf_view.cc
diff --git a/ash/shelf/shelf_view.cc b/ash/shelf/shelf_view.cc
index c8a3e8214b823bd6b10827497514eb6c3d32ccd7..b5608dff81289423a68d5e06dcc927fa9fb486e6 100644
--- a/ash/shelf/shelf_view.cc
+++ b/ash/shelf/shelf_view.cc
@@ -1343,11 +1343,9 @@ gfx::Rect ShelfView::GetBoundsForDragInsertInScreen() {
}
if (wm_shelf_->IsHorizontalAlignment()) {
- preferred_size =
- gfx::Size(last_button_bounds.right(), GetShelfConstant(SHELF_SIZE));
+ preferred_size = gfx::Size(last_button_bounds.right(), kShelfSize);
} else {
- preferred_size =
- gfx::Size(GetShelfConstant(SHELF_SIZE), last_button_bounds.bottom());
+ preferred_size = gfx::Size(kShelfSize, last_button_bounds.bottom());
}
}
gfx::Point origin(GetMirroredXWithWidthInView(0, preferred_size.width()), 0);
@@ -1396,7 +1394,7 @@ int ShelfView::CancelDrag(int modified_index) {
gfx::Size ShelfView::GetPreferredSize() const {
gfx::Rect overflow_bounds;
CalculateIdealBounds(&overflow_bounds);
- const int shelf_size = GetShelfConstant(SHELF_SIZE);
+ const int shelf_size = kShelfSize;
James Cook 2017/04/18 15:31:52 nit: inline uses
Evan Stade 2017/04/18 16:41:09 Done.
int last_button_index = last_visible_index_;
if (!is_overflow_mode()) {

Powered by Google App Engine
This is Rietveld 408576698