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

Issue 22917005: New parser mode for CSSOM @viewport descriptors. (Closed)

Created:
7 years, 4 months ago by rune
Modified:
7 years, 3 months ago
CC:
blink-reviews, apavlov+blink_chromium.org, dglazkov+blink, eae+blinkwatch, darktears, caseq, alancutter (OOO until 2018)
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Visibility:
Public.

Description

New parser mode for CSSOM @viewport descriptors. CSSOM value and descriptor parsing for @viewport used parsing rules for normal CSS property declarations instead, meaning width and height were not parsed as shorthands. This is an issue for other CSSOM access to other descriptors too, like for @font-face. This fix is minimal for the @viewport case and intended for feedback on the general approach. I considered not adding new parser modes, but use a bit in StylePropertySet to indicate a CSSParserMode or a descriptor mode and let two bits store the mode. With both the current changes and the split, a descriptor mode would implicitly be strict. BUG=272718 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=157955

Patch Set 1 #

Total comments: 4

Patch Set 2 : Rebased onto master #

Patch Set 3 : Fixed review issues and added more tests #

Total comments: 8

Patch Set 4 : Rebase #

Patch Set 5 : Fixed review issues. #

Total comments: 4

Patch Set 6 : More comments added. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+113 lines, -11 lines) Patch
A LayoutTests/css3/device-adapt/viewport-cssom-01.html View 1 2 1 chunk +53 lines, -0 lines 0 comments Download
A LayoutTests/css3/device-adapt/viewport-cssom-01-expected.txt View 1 2 1 chunk +7 lines, -0 lines 0 comments Download
M Source/core/css/CSSParser.h View 1 2 3 chunks +26 lines, -1 line 0 comments Download
M Source/core/css/CSSParser-in.cpp View 1 2 3 4 5 4 chunks +15 lines, -4 lines 0 comments Download
M Source/core/css/CSSParserMode.h View 1 2 3 4 5 2 chunks +5 lines, -2 lines 0 comments Download
M Source/core/css/StylePropertySet.h View 1 2 2 chunks +6 lines, -3 lines 0 comments Download
M Source/core/css/StylePropertySet.cpp View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 15 (0 generated)
rune
7 years, 4 months ago (2013-08-14 10:42:24 UTC) #1
kenneth.r.christiansen
7 years, 3 months ago (2013-09-02 15:54:53 UTC) #2
rune
7 years, 3 months ago (2013-09-10 07:25:28 UTC) #3
eseidel
https://codereview.chromium.org/22917005/diff/1/Source/core/css/CSSParser-in.cpp File Source/core/css/CSSParser-in.cpp (right): https://codereview.chromium.org/22917005/diff/1/Source/core/css/CSSParser-in.cpp#newcode1200 Source/core/css/CSSParser-in.cpp:1200: markViewportRuleBodyStart(); Bleh. Do we need a helper function around ...
7 years, 3 months ago (2013-09-10 16:33:57 UTC) #4
rune
https://codereview.chromium.org/22917005/diff/1/Source/core/css/CSSParser-in.cpp File Source/core/css/CSSParser-in.cpp (right): https://codereview.chromium.org/22917005/diff/1/Source/core/css/CSSParser-in.cpp#newcode1200 Source/core/css/CSSParser-in.cpp:1200: markViewportRuleBodyStart(); On 2013/09/10 16:33:58, eseidel wrote: > Bleh. Do ...
7 years, 3 months ago (2013-09-12 13:05:01 UTC) #5
rune
ping
7 years, 3 months ago (2013-09-17 07:29:46 UTC) #6
eseidel
https://codereview.chromium.org/22917005/diff/12001/Source/core/css/CSSParser-in.cpp File Source/core/css/CSSParser-in.cpp (left): https://codereview.chromium.org/22917005/diff/12001/Source/core/css/CSSParser-in.cpp#oldcode1221 Source/core/css/CSSParser-in.cpp:1221: cssyyparse(this); I might have wrapped this in a block, ...
7 years, 3 months ago (2013-09-17 16:28:54 UTC) #7
eseidel
7 years, 3 months ago (2013-09-17 16:29:36 UTC) #8
rune
https://codereview.chromium.org/22917005/diff/12001/Source/core/css/CSSParser-in.cpp File Source/core/css/CSSParser-in.cpp (left): https://codereview.chromium.org/22917005/diff/12001/Source/core/css/CSSParser-in.cpp#oldcode1221 Source/core/css/CSSParser-in.cpp:1221: cssyyparse(this); On 2013/09/17 16:28:55, eseidel wrote: > I might ...
7 years, 3 months ago (2013-09-17 20:17:02 UTC) #9
rune
https://codereview.chromium.org/22917005/diff/12001/Source/core/css/CSSParser-in.cpp File Source/core/css/CSSParser-in.cpp (left): https://codereview.chromium.org/22917005/diff/12001/Source/core/css/CSSParser-in.cpp#oldcode1221 Source/core/css/CSSParser-in.cpp:1221: cssyyparse(this); On 2013/09/17 20:17:03, rune wrote: > On 2013/09/17 ...
7 years, 3 months ago (2013-09-17 20:40:41 UTC) #10
rune
https://codereview.chromium.org/22917005/diff/31001/Source/core/css/StylePropertySet.cpp File Source/core/css/StylePropertySet.cpp (right): https://codereview.chromium.org/22917005/diff/31001/Source/core/css/StylePropertySet.cpp#newcode83 Source/core/css/StylePropertySet.cpp:83: for (unsigned i = 0; i < m_arraySize; ++i) ...
7 years, 3 months ago (2013-09-17 20:47:46 UTC) #11
eseidel
lgtm https://codereview.chromium.org/22917005/diff/31001/Source/core/css/CSSParserMode.h File Source/core/css/CSSParserMode.h (right): https://codereview.chromium.org/22917005/diff/31001/Source/core/css/CSSParserMode.h#newcode49 Source/core/css/CSSParserMode.h:49: ViewportMode If you're willing to go one more ...
7 years, 3 months ago (2013-09-17 22:26:00 UTC) #12
rune
https://codereview.chromium.org/22917005/diff/31001/Source/core/css/CSSParserMode.h File Source/core/css/CSSParserMode.h (right): https://codereview.chromium.org/22917005/diff/31001/Source/core/css/CSSParserMode.h#newcode49 Source/core/css/CSSParserMode.h:49: ViewportMode On 2013/09/17 22:26:00, eseidel wrote: > If you're ...
7 years, 3 months ago (2013-09-18 08:13:09 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rune@opera.com/22917005/37001
7 years, 3 months ago (2013-09-18 08:13:48 UTC) #14
commit-bot: I haz the power
7 years, 3 months ago (2013-09-18 11:25:23 UTC) #15
Message was sent while issue was closed.
Change committed as 157955

Powered by Google App Engine
This is Rietveld 408576698