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

Issue 2898133002: CSS: Use count unitless 0 supplied as <angle> (Closed)

Created:
3 years, 7 months ago by Eric Willigers
Modified:
3 years, 6 months ago
CC:
darktears, apavlov+blink_chromium.org, asvitkine+watch_chromium.org, blink-reviews, blink-reviews-css, blink-reviews-frames_chromium.org, chromium-reviews, dglazkov+blink, meade_UTC10, rwlbuis
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

CSS: Use count unitless 0 supplied as <angle> A recent spec change means that 0 is no longer supported as a valid value for angles. https://github.com/w3c/csswg-drafts/issues/1162#issuecomment-293637767 We add use counters to detect how often 0 is currently being used as an angle. image-orientation and rotate and offset-path's ray() have not yet shipped, so we don't need use counters for these, we simply reject 0 as an angle. ConsumeGradientAngleOrPercent now accepts a CSSParserContext by const reference. ConsumeGradientLengthOrPercent has been implemented with the same function signature as ConsumeGradientAngleOrPercent so they can be called via ConsumeGradientColorStops using the same function pointer type. BUG=725382 Review-Url: https://codereview.chromium.org/2898133002 Cr-Commit-Position: refs/heads/master@{#474578} Committed: https://chromium.googlesource.com/chromium/src/+/e24202c3b5752cb040117fe5ae0247c27089766c

Patch Set 1 #

Patch Set 2 : extra argument #

Patch Set 3 : test custom property #

Total comments: 6

Patch Set 4 : Optional #

Total comments: 13

Patch Set 5 : kUnitless #

Total comments: 2

Patch Set 6 : test #

Unified diffs Side-by-side diffs Delta from patch set Stats (+282 lines, -56 lines) Patch
A third_party/WebKit/LayoutTests/css-parser/unitless-zero-angle.html View 1 2 3 4 5 1 chunk +13 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/fast/css/usecounter-angle-zero-custom.html View 1 2 3 4 1 chunk +41 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/fast/css/usecounter-angle-zero-filter.html View 1 2 3 4 1 chunk +32 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/fast/css/usecounter-angle-zero-gradient.html View 1 2 3 4 1 chunk +32 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/fast/css/usecounter-angle-zero-offset-rotate.html View 1 2 3 4 1 chunk +32 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/fast/css/usecounter-angle-zero-transform.html View 1 2 3 4 1 chunk +32 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.cpp View 1 2 3 4 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/css/parser/CSSPropertyParser.cpp View 1 2 3 4 4 chunks +12 lines, -7 lines 0 comments Download
M third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.h View 1 2 3 4 1 chunk +5 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp View 1 2 3 4 14 chunks +56 lines, -39 lines 0 comments Download
M third_party/WebKit/Source/core/css/properties/CSSPropertyAPIImageOrientation.cpp View 1 2 3 4 5 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/css/properties/CSSPropertyAPIRotate.cpp View 1 2 3 4 5 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/css/properties/CSSPropertyAPITransform.cpp View 1 2 3 4 5 2 chunks +6 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/css/properties/CSSPropertyOffsetPathUtils.cpp View 1 2 3 4 5 3 chunks +5 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/frame/UseCounter.h View 1 2 3 4 1 chunk +5 lines, -0 lines 0 comments Download
M tools/metrics/histograms/enums.xml View 1 2 3 4 1 chunk +5 lines, -0 lines 0 comments Download

Messages

Total messages: 33 (18 generated)
Eric Willigers
3 years, 7 months ago (2017-05-23 08:29:12 UTC) #2
Eric Willigers
3 years, 6 months ago (2017-05-24 03:54:59 UTC) #8
suzyh_UTC10 (ex-contributor)
core/css OWNERS lgtm with similar caveats as on https://codereview.chromium.org/2888283006. I have not done a full ...
3 years, 6 months ago (2017-05-24 04:47:48 UTC) #9
Bugs Nash
lgtm with nits https://codereview.chromium.org/2898133002/diff/40001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp File third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp (right): https://codereview.chromium.org/2898133002/diff/40001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp#newcode326 third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp:326: CSSPrimitiveValue* ConsumeGradientLengthOrPercent( This seems like an ...
3 years, 6 months ago (2017-05-24 06:24:20 UTC) #10
Eric Willigers
3 years, 6 months ago (2017-05-24 06:37:31 UTC) #12
Bugs Nash
On 2017/05/24 at 06:37:31, ericwilligers wrote: > As per offline discussion, UnitlessQuirk isn't intended for ...
3 years, 6 months ago (2017-05-24 07:01:36 UTC) #14
Eric Willigers
https://codereview.chromium.org/2898133002/diff/40001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp File third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp (right): https://codereview.chromium.org/2898133002/diff/40001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp#newcode326 third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp:326: CSSPrimitiveValue* ConsumeGradientLengthOrPercent( On 2017/05/24 06:24:20, Bugs Nash wrote: > ...
3 years, 6 months ago (2017-05-24 07:13:18 UTC) #15
Eric Willigers
https://codereview.chromium.org/2898133002/diff/40001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp File third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp (right): https://codereview.chromium.org/2898133002/diff/40001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp#newcode358 third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp:358: context.Count(literalZero); On 2017/05/24 06:24:20, Bugs Nash wrote: > literalZeroFeature ...
3 years, 6 months ago (2017-05-24 17:07:26 UTC) #16
Bugs Nash
On 2017/05/24 at 07:13:18, ericwilligers wrote: > https://codereview.chromium.org/2898133002/diff/40001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp > File third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp (right): > > https://codereview.chromium.org/2898133002/diff/40001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp#newcode326 ...
3 years, 6 months ago (2017-05-24 21:46:25 UTC) #17
alancutter (OOO until 2018)
https://codereview.chromium.org/2898133002/diff/60001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp File third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp (right): https://codereview.chromium.org/2898133002/diff/60001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp#newcode326 third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp:326: CSSPrimitiveValue* ConsumeGradientLengthOrPercent( I don't understand the purpose of this ...
3 years, 6 months ago (2017-05-25 01:53:17 UTC) #20
Eric Willigers
https://codereview.chromium.org/2898133002/diff/60001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp File third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp (right): https://codereview.chromium.org/2898133002/diff/60001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp#newcode326 third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp:326: CSSPrimitiveValue* ConsumeGradientLengthOrPercent( On 2017/05/25 01:53:16, alancutter wrote: > I ...
3 years, 6 months ago (2017-05-25 02:56:41 UTC) #24
alancutter (OOO until 2018)
lgtm Please add tests for the change in behaviour for image-orientation and rotate and offset-path's ...
3 years, 6 months ago (2017-05-25 03:11:52 UTC) #25
Eric Willigers
https://codereview.chromium.org/2898133002/diff/60001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp File third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp (right): https://codereview.chromium.org/2898133002/diff/60001/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp#newcode326 third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp:326: CSSPrimitiveValue* ConsumeGradientLengthOrPercent( On 2017/05/25 03:11:52, alancutter wrote: > On ...
3 years, 6 months ago (2017-05-25 03:58:14 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2898133002/100001
3 years, 6 months ago (2017-05-25 03:59:30 UTC) #30
commit-bot: I haz the power
3 years, 6 months ago (2017-05-25 06:04:47 UTC) #33
Message was sent while issue was closed.
Committed patchset #6 (id:100001) as
https://chromium.googlesource.com/chromium/src/+/e24202c3b5752cb040117fe5ae02...

Powered by Google App Engine
This is Rietveld 408576698