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

Side by Side Diff: ash/shelf/overflow_button.h

Issue 2051663005: Vectorize the remaining material design shelf icons (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nit addressed Created 4 years, 6 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 | « no previous file | ash/shelf/overflow_button.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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef ASH_SHELF_OVERFLOW_BUTTON_H_ 5 #ifndef ASH_SHELF_OVERFLOW_BUTTON_H_
6 #define ASH_SHELF_OVERFLOW_BUTTON_H_ 6 #define ASH_SHELF_OVERFLOW_BUTTON_H_
7 7
8 #include "ash/common/shelf/shelf_types.h" 8 #include "ash/common/shelf/shelf_types.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 25 matching lines...) Expand all
36 // current shelf state. 36 // current shelf state.
37 // TODO(tdanderson): Remove this once the material design shelf is enabled 37 // TODO(tdanderson): Remove this once the material design shelf is enabled
38 // by default. See crbug.com/614453. 38 // by default. See crbug.com/614453.
39 int NonMaterialBackgroundImageId(); 39 int NonMaterialBackgroundImageId();
40 40
41 // Calculates the bounds of the overflow button based on the shelf alignment. 41 // Calculates the bounds of the overflow button based on the shelf alignment.
42 // TODO(tdanderson): The button size and bounds need to be adjusted to 42 // TODO(tdanderson): The button size and bounds need to be adjusted to
43 // conform to the material design spec. See crbug.com/617295. 43 // conform to the material design spec. See crbug.com/617295.
44 gfx::Rect CalculateButtonBounds(); 44 gfx::Rect CalculateButtonBounds();
45 45
46 // Left and right images are rotations of bottom_image and are 46 // Used for bottom shelf alignment. |bottom_image_| points to
47 // owned by the overflow button. 47 // |bottom_image_md_| for material design, otherwise it is points to a
48 // resource owned by the ResourceBundle.
49 // TODO(tdanderson): Remove the non-md code once the material design shelf is
50 // enabled by default. See crbug.com/614453.
51 const gfx::ImageSkia* bottom_image_;
52 gfx::ImageSkia bottom_image_md_;
53
54 // Cached rotations of |bottom_image_| used for left and right shelf
55 // alignments.
48 gfx::ImageSkia left_image_; 56 gfx::ImageSkia left_image_;
49 gfx::ImageSkia right_image_; 57 gfx::ImageSkia right_image_;
50 // Bottom image is owned by the resource bundle. 58
51 const gfx::ImageSkia* bottom_image_;
52 Shelf* shelf_; 59 Shelf* shelf_;
53 60
54 DISALLOW_COPY_AND_ASSIGN(OverflowButton); 61 DISALLOW_COPY_AND_ASSIGN(OverflowButton);
55 }; 62 };
56 63
57 } // namespace ash 64 } // namespace ash
58 65
59 #endif // ASH_SHELF_OVERFLOW_BUTTON_H_ 66 #endif // ASH_SHELF_OVERFLOW_BUTTON_H_
OLDNEW
« no previous file with comments | « no previous file | ash/shelf/overflow_button.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698