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

Side by Side Diff: third_party/WebKit/Source/core/css/properties/CSSPropertyAPIGridGap.cpp

Issue 2882603002: Implemented remaining non-grouped longhand property APIs (Closed)
Patch Set: implemented single property apis using script Created 3 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
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "core/css/properties/CSSPropertyAPIGridGap.h"
6
7 namespace blink {
8
9 class CSSParserContext;
10 class CSSParserLocalContext;
11 class CSSParserTokenRange;
12 class CSSValue;
13
14 const CSSValue* CSSPropertyAPIGridGap::parseSingleValue(
Jia 2017/06/08 22:07:14 This is a shorthand, it should impl parseShorthand
15 CSSParserTokenRange& range,
16 const CSSParserContext& context,
17 const CSSParserLocalContext&) {
18 DCHECK(RuntimeEnabledFeatures::CSSGridLayoutEnabled());
19 DCHECK_EQ(shorthandForProperty(CSSPropertyGridGap).length(), 2u);
20 CSSValue* row_gap = ConsumeLengthOrPercent(range, context->Mode(),
21 kValueRangeNonNegative);
22 CSSValue* column_gap = ConsumeLengthOrPercent(range, context->Mode(),
23 kValueRangeNonNegative);
24 if (!row_gap || !range.AtEnd())
25 return false;
26 if (!column_gap)
27 column_gap = row_gap;
28 AddParsedProperty(CSSPropertyGridRowGap, CSSPropertyGridGap, *row_gap,
29 important);
Jia 2017/06/08 22:07:14 AddParsedProperty is a wrapper function private to
Bugs Nash 2017/06/09 00:00:17 no this code certainly doesn't compile! as I menti
Jia 2017/06/09 00:10:07 Ok, so I don't need to lgtm for now. Thanks for th
30 AddParsedProperty(CSSPropertyGridColumnGap, CSSPropertyGridGap,
31 *column_gap, important);
32 return true;
33 }
34 }
35
36 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698