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

Unified Diff: ash/shelf/shelf_constants.h

Issue 1998933002: Update shelf spacing in Chrome OS according to the MD specs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
Index: ash/shelf/shelf_constants.h
diff --git a/ash/shelf/shelf_constants.h b/ash/shelf/shelf_constants.h
index d7f0825b7394263afdec8f6f8952ef8c6e7f7a03..6c99603093c5ae00599d8c479df31a4b4f5a4913 100644
--- a/ash/shelf/shelf_constants.h
+++ b/ash/shelf/shelf_constants.h
@@ -9,19 +9,34 @@
namespace ash {
+enum ShelfLayoutConstant {
+ // Size of the shelf when visible (height when the shelf is horizontal).
bruthig 2016/05/25 20:24:52 nit: Can you add 'and width when the shelf is vert
yiyix 2016/06/02 03:54:53 Done.
+ SHELF_SIZE,
+
+ // Size of the space between buttons on the shelf.
+ SHELF_BUTTON_SPACING,
+
+ // Size allocated for each button on the shelf.
+ SHELF_BUTTON_SIZE
+};
+
+ASH_EXPORT int GetShelfLayoutConstant(ShelfLayoutConstant constant);
+
// Invalid image resource id used for ShelfItemDetails.
extern const int kInvalidImageResourceID;
-const int kInvalidShelfID = 0;
+// We reserve a small area on the edge of the workspace area to ensure that
+// the resize handle at the edge of the window can be hit.
+extern const int kWorkspaceAreaVisibleInset;
bruthig 2016/05/25 20:24:52 Please wrap these three constants in a class. 'kA
tdanderson 2016/05/26 22:55:56 For the purposes of this CL, I would actually refr
yiyix 2016/06/02 03:54:53 I wanted to move most of the shelf property relate
-// Size of the shelf when visible (height when the shelf is horizontal).
-ASH_EXPORT extern const int kShelfSize;
+// When autohidden we extend the touch hit target onto the screen so that the
+// user can drag the shelf out.
+extern const int kWorkspaceAreaAutoHideInset;
-// Size of the space between buttons on the shelf.
-ASH_EXPORT extern const int kShelfButtonSpacing;
+// Size of the shelf when auto-hidden.
+ASH_EXPORT extern const int kAutoHideSize;
-// Size allocated for each button on the shelf.
-ASH_EXPORT extern const int kShelfButtonSize;
+const int kInvalidShelfID = 0;
// The direction of the focus cycling.
enum CycleDirection {

Powered by Google App Engine
This is Rietveld 408576698