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

Side by Side Diff: third_party/WebKit/Source/core/style/GridResolvedPosition.h

Issue 1406923009: Rename DISALLOW_ALLOCATION and ALLOW_ONLY_INLINE_ALLOCATION (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 GridResolvedPosition_h 5 #ifndef GridResolvedPosition_h
6 #define GridResolvedPosition_h 6 #define GridResolvedPosition_h
7 7
8 #include "core/style/GridPosition.h" 8 #include "core/style/GridPosition.h"
9 #include "wtf/Allocator.h" 9 #include "wtf/Allocator.h"
10 10
(...skipping 11 matching lines...) Expand all
22 }; 22 };
23 23
24 enum GridTrackSizingDirection { 24 enum GridTrackSizingDirection {
25 ForColumns, 25 ForColumns,
26 ForRows 26 ForRows
27 }; 27 };
28 28
29 // This class represents an index into one of the dimensions of the grid array. 29 // This class represents an index into one of the dimensions of the grid array.
30 // Wraps a size_t integer just for the purpose of knowing what we manipulate in the grid code. 30 // Wraps a size_t integer just for the purpose of knowing what we manipulate in the grid code.
31 class GridResolvedPosition { 31 class GridResolvedPosition {
32 DISALLOW_ALLOCATION(); 32 DISALLOW_NEW();
33 public: 33 public:
34 static GridResolvedPosition adjustGridPositionForAfterEndSide(size_t resolve dPosition) 34 static GridResolvedPosition adjustGridPositionForAfterEndSide(size_t resolve dPosition)
35 { 35 {
36 return resolvedPosition ? GridResolvedPosition(resolvedPosition - 1) : G ridResolvedPosition(0); 36 return resolvedPosition ? GridResolvedPosition(resolvedPosition - 1) : G ridResolvedPosition(0);
37 } 37 }
38 38
39 static GridResolvedPosition adjustGridPositionForSide(size_t resolvedPositio n, GridPositionSide side) 39 static GridResolvedPosition adjustGridPositionForSide(size_t resolvedPositio n, GridPositionSide side)
40 { 40 {
41 // An item finishing on the N-th line belongs to the N-1-th cell. 41 // An item finishing on the N-th line belongs to the N-1-th cell.
42 if (side == ColumnEndSide || side == RowEndSide) 42 if (side == ColumnEndSide || side == RowEndSide)
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 private: 126 private:
127 127
128 static size_t explicitGridSizeForSide(const ComputedStyle&, GridPositionSide ); 128 static size_t explicitGridSizeForSide(const ComputedStyle&, GridPositionSide );
129 129
130 size_t m_integerPosition; 130 size_t m_integerPosition;
131 }; 131 };
132 132
133 } // namespace blink 133 } // namespace blink
134 134
135 #endif // GridResolvedPosition_h 135 #endif // GridResolvedPosition_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/style/GridPosition.h ('k') | third_party/WebKit/Source/core/style/GridTrackSize.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698