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

Issue 2654403003: Added api_methods flag to CSSProperties.json5. (Closed)

Created:
3 years, 10 months ago by aazzam
Modified:
3 years, 10 months ago
Reviewers:
nainar, sashab, ktyliu, shend
CC:
darktears, apavlov+blink_chromium.org, blink-reviews, blink-reviews-css, chromium-reviews, dglazkov+blink, ktyliu, rwlbuis
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Added api_methods flag to CSSProperties.json5. A part of Project Ribbon, separating the parsing logic for CSS properties from the parser into an API. This patch adds an api_methods=["method1", "method2"] flag to CSSProperties.json5, which specifies which methods have been implemented in the API implementation of that property. This is so that when API .h files are generated, only methods implemented for that property are defined. It also adds "parseSingleValue" to the list of api_methods for all existing properties with an API that implements parseSingleValue. Before, when a method was added to the API, this method had to be implemented in all API files - however, not every API should hold each method. In this new design, to add a method to the API: - Add the method name to the valid_values array in CSSProperties.json5. - Add the method to CSSPropertyAPIFiles.h.tmpl - Add the method name to the api_methods list in CSSProperties.json5 for each property where it is implemented. BUG=668012 Review-Url: https://codereview.chromium.org/2654403003 Cr-Original-Commit-Position: refs/heads/master@{#447427} Committed: https://chromium.googlesource.com/chromium/src/+/a252f0fa5f780f176eb3388df35ec67abaf8ca79 Review-Url: https://codereview.chromium.org/2654403003 Cr-Commit-Position: refs/heads/master@{#447459} Committed: https://chromium.googlesource.com/chromium/src/+/d965a330d470c634f1010dd90bc20cfb1e81971f

Patch Set 1 #

Patch Set 2 : rebase #

Patch Set 3 : Added assertion for function names #

Patch Set 4 : Removed parseShorthand from valid_methods #

Total comments: 1

Patch Set 5 : Fixed comments in CSSProperties.json and CSSPropertyAPI.h #

Patch Set 6 : Changed comments again #

Total comments: 11

Patch Set 7 : Moved validation to CSSProperties.json5 #

Patch Set 8 : Added valid_type to CSSProperties.json5 #

Total comments: 5

Patch Set 9 : Changed valid_values from list of lists, to list of valid values #

Total comments: 1

Patch Set 10 : rebase #

Patch Set 11 : rebase #

Patch Set 12 : rebase #

Messages

Total messages: 46 (28 generated)
aazzam
hey darren! please take a look at the CL description and let me know what ...
3 years, 10 months ago (2017-01-31 02:22:56 UTC) #15
shend
On 2017/01/31 at 02:22:56, aazzam wrote: > hey darren! please take a look at the ...
3 years, 10 months ago (2017-01-31 02:47:42 UTC) #16
aazzam
On 2017/01/31 at 02:47:42, shend wrote: > On 2017/01/31 at 02:22:56, aazzam wrote: > > ...
3 years, 10 months ago (2017-01-31 03:08:41 UTC) #19
aazzam
please take a look naina! :) and ptal at CL description darren :)
3 years, 10 months ago (2017-01-31 03:10:04 UTC) #21
shend
On 2017/01/31 at 03:10:04, aazzam wrote: > please take a look naina! :) and ptal ...
3 years, 10 months ago (2017-01-31 03:20:08 UTC) #22
nainar
lgtm https://codereview.chromium.org/2654403003/diff/60001/third_party/WebKit/Source/build/scripts/make_css_property_apis.py File third_party/WebKit/Source/build/scripts/make_css_property_apis.py (right): https://codereview.chromium.org/2654403003/diff/60001/third_party/WebKit/Source/build/scripts/make_css_property_apis.py#newcode45 third_party/WebKit/Source/build/scripts/make_css_property_apis.py:45: '. Methods added to the API must also ...
3 years, 10 months ago (2017-01-31 03:21:19 UTC) #23
aazzam
Fixed the variable names and comments, ptal sasha :)
3 years, 10 months ago (2017-01-31 03:46:23 UTC) #25
sashab
This is one of the most amazing back-and-forth reviews I've ever seen :) Well done ...
3 years, 10 months ago (2017-01-31 20:06:30 UTC) #26
ktyliu
https://codereview.chromium.org/2654403003/diff/100001/third_party/WebKit/Source/build/scripts/make_css_property_apis.py File third_party/WebKit/Source/build/scripts/make_css_property_apis.py (right): https://codereview.chromium.org/2654403003/diff/100001/third_party/WebKit/Source/build/scripts/make_css_property_apis.py#newcode29 third_party/WebKit/Source/build/scripts/make_css_property_apis.py:29: valid_methods = ["parseSingleValue"] On 2017/01/31 at 20:06:30, sashab wrote: ...
3 years, 10 months ago (2017-01-31 22:14:16 UTC) #28
aazzam
done (addressed comments and moved validation to CSSProperties.json5), ptal! :) https://codereview.chromium.org/2654403003/diff/100001/third_party/WebKit/Source/build/scripts/make_css_property_apis.py File third_party/WebKit/Source/build/scripts/make_css_property_apis.py (right): https://codereview.chromium.org/2654403003/diff/100001/third_party/WebKit/Source/build/scripts/make_css_property_apis.py#newcode29 ...
3 years, 10 months ago (2017-01-31 22:38:38 UTC) #30
sashab
Nice :) LGTM, might need to rebase over kevins change https://codereview.chromium.org/2654403003/diff/90005/third_party/WebKit/Source/core/css/CSSProperties.json5 File third_party/WebKit/Source/core/css/CSSProperties.json5 (right): https://codereview.chromium.org/2654403003/diff/90005/third_party/WebKit/Source/core/css/CSSProperties.json5#newcode53 ...
3 years, 10 months ago (2017-01-31 22:50:58 UTC) #31
aazzam
done, will wait for kevin's patch https://codereview.chromium.org/2666173002 to land and will rebase! :) https://codereview.chromium.org/2654403003/diff/90005/third_party/WebKit/Source/core/css/CSSProperties.json5 File ...
3 years, 10 months ago (2017-01-31 22:55:44 UTC) #32
ktyliu
LGTM nice https://codereview.chromium.org/2654403003/diff/90005/third_party/WebKit/Source/core/css/CSSProperties.json5 File third_party/WebKit/Source/core/css/CSSProperties.json5 (right): https://codereview.chromium.org/2654403003/diff/90005/third_party/WebKit/Source/core/css/CSSProperties.json5#newcode53 third_party/WebKit/Source/core/css/CSSProperties.json5:53: valid_values: [["parseSingleValue"]], On 2017/01/31 at 22:55:43, aazzam ...
3 years, 10 months ago (2017-01-31 23:02:46 UTC) #33
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/2654403003/160001
3 years, 10 months ago (2017-02-01 00:47:57 UTC) #36
commit-bot: I haz the power
Committed patchset #10 (id:160001) as https://chromium.googlesource.com/chromium/src/+/a252f0fa5f780f176eb3388df35ec67abaf8ca79
3 years, 10 months ago (2017-02-01 02:44:32 UTC) #39
tsergeant
A revert of this CL (patchset #10 id:160001) has been created in https://codereview.chromium.org/2668093003/ by tsergeant@chromium.org. ...
3 years, 10 months ago (2017-02-01 03:07:04 UTC) #40
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/2654403003/200001
3 years, 10 months ago (2017-02-01 04:16:40 UTC) #43
commit-bot: I haz the power
3 years, 10 months ago (2017-02-01 05:55:35 UTC) #46
Message was sent while issue was closed.
Committed patchset #12 (id:200001) as
https://chromium.googlesource.com/chromium/src/+/d965a330d470c634f1010dd90bc2...

Powered by Google App Engine
This is Rietveld 408576698