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

Issue 577303002: IDL: Support [DeprecateAs] and [MeasureAs] on constants (Closed)

Created:
6 years, 3 months ago by Jens Widell
Modified:
6 years, 2 months ago
CC:
blink-reviews, blink-reviews-bindings_chromium.org, arv+blink, abarth-chromium
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Project:
blink
Visibility:
Public.

Description

IDL: Support [DeprecateAs] and [MeasureAs] on constants For constants with [DeprecateAs] or [MeasureAs], create the property using v8::Template::SetNativeDataProperty() instead, using a simple accessor callback function that handles the deprecation/measuring and returns the constant value. BUG=358506 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=182492

Patch Set 1 #

Total comments: 1

Patch Set 2 : #

Patch Set 3 : refactoring a little #

Total comments: 5

Patch Set 4 : added comment #

Patch Set 5 : adjusted encrypted-media-constants-expected.txt #

Unified diffs Side-by-side diffs Delta from patch set Stats (+114 lines, -33 lines) Patch
M LayoutTests/media/encrypted-media/prefixed/encrypted-media-constants-expected.txt View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
M Source/bindings/core/v8/V8DOMConfiguration.h View 1 chunk +1 line, -0 lines 0 comments Download
M Source/bindings/core/v8/V8DOMConfiguration.cpp View 1 2 3 2 chunks +16 lines, -0 lines 0 comments Download
M Source/bindings/scripts/v8_interface.py View 2 chunks +19 lines, -8 lines 0 comments Download
M Source/bindings/templates/constants.cpp View 1 2 2 chunks +51 lines, -24 lines 0 comments Download
M Source/bindings/templates/interface_base.cpp View 1 chunk +6 lines, -0 lines 0 comments Download
M Source/bindings/tests/idls/core/TestObject.idl View 1 chunk +1 line, -0 lines 0 comments Download
M Source/bindings/tests/results/core/V8TestObject.cpp View 1 4 chunks +19 lines, -1 line 0 comments Download

Messages

Total messages: 28 (3 generated)
Jens Widell
haraken@: do you think we should support this, given the complexity added, and if so, ...
6 years, 3 months ago (2014-09-18 16:34:11 UTC) #2
haraken
I don't think we should support this. If we use SetAccessor to install a constant, ...
6 years, 3 months ago (2014-09-18 16:57:10 UTC) #3
Jens Widell
On 2014/09/18 16:57:10, haraken(OOO til Sep 21) wrote: > If we use SetAccessor to install ...
6 years, 3 months ago (2014-09-18 18:07:46 UTC) #4
haraken
On 2014/09/18 18:07:46, Jens Widell wrote: > On 2014/09/18 16:57:10, haraken(OOO til Sep 21) wrote: ...
6 years, 3 months ago (2014-09-18 23:17:47 UTC) #5
Jens Widell
On 2014/09/18 23:17:47, haraken(OOO til Sep 21) wrote: > Hmm, I understand SetAccessor will "work", ...
6 years, 3 months ago (2014-09-19 06:27:23 UTC) #6
haraken
On 2014/09/19 06:27:23, Jens Widell wrote: > On 2014/09/18 23:17:47, haraken(OOO til Sep 21) wrote: ...
6 years, 3 months ago (2014-09-19 06:40:31 UTC) #7
Erik Dahlström (inactive)
On 2014/09/19 06:40:31, haraken(OOO til Sep 21) wrote: ... > Do we have any real ...
6 years, 3 months ago (2014-09-19 07:29:49 UTC) #8
haraken
On 2014/09/19 07:29:49, Erik Dahlström wrote: > On 2014/09/19 06:40:31, haraken(OOO til Sep 21) wrote: ...
6 years, 3 months ago (2014-09-19 07:38:41 UTC) #9
philipj_slow
Some more constants that needs removing: MediaError.MEDIA_ERR_ENCRYPTED (already DeprecateAs, but obviously that doesn't work) Element.ALLOW_KEYBOARD_INPUT ...
6 years, 3 months ago (2014-09-19 07:58:35 UTC) #10
Jens Widell
On 2014/09/19 06:27:23, Jens Widell wrote: > I guess our options would be: > > ...
6 years, 3 months ago (2014-09-19 09:18:21 UTC) #11
haraken
On 2014/09/19 09:18:21, Jens Widell wrote: > On 2014/09/19 06:27:23, Jens Widell wrote: > > ...
6 years, 3 months ago (2014-09-19 09:27:14 UTC) #12
haraken
+Dan, Jochen
6 years, 3 months ago (2014-09-19 09:29:02 UTC) #14
dcarney
> So, for completeness, I had a quick go at finding out what supporting > ...
6 years, 3 months ago (2014-09-22 07:40:00 UTC) #15
Jens Widell
On 2014/09/22 07:40:00, dcarney wrote: > > So, for completeness, I had a quick go ...
6 years, 2 months ago (2014-09-23 06:33:38 UTC) #16
haraken
On 2014/09/23 06:33:38, Jens Widell wrote: > On 2014/09/22 07:40:00, dcarney wrote: > > > ...
6 years, 2 months ago (2014-09-23 06:37:01 UTC) #17
Jens Widell
On 2014/09/23 06:37:01, haraken wrote: > Can we use SetNativeDataProperty for all constants (not only ...
6 years, 2 months ago (2014-09-23 06:51:22 UTC) #18
haraken
LGTM https://codereview.chromium.org/577303002/diff/40001/Source/bindings/core/v8/V8DOMConfiguration.cpp File Source/bindings/core/v8/V8DOMConfiguration.cpp (right): https://codereview.chromium.org/577303002/diff/40001/Source/bindings/core/v8/V8DOMConfiguration.cpp#newcode104 Source/bindings/core/v8/V8DOMConfiguration.cpp:104: void V8DOMConfiguration::installConstant(v8::Handle<v8::FunctionTemplate> functionDescriptor, v8::Handle<v8::ObjectTemplate> prototype, const char* name, ...
6 years, 2 months ago (2014-09-23 07:52:28 UTC) #19
Jens Widell
https://codereview.chromium.org/577303002/diff/40001/Source/bindings/scripts/v8_interface.py File Source/bindings/scripts/v8_interface.py (right): https://codereview.chromium.org/577303002/diff/40001/Source/bindings/scripts/v8_interface.py#newcode266 Source/bindings/scripts/v8_interface.py:266: 'constant_configuration_constants': constant_configuration_constants, On 2014/09/23 07:52:28, haraken wrote: > > ...
6 years, 2 months ago (2014-09-23 08:02:51 UTC) #20
haraken
https://codereview.chromium.org/577303002/diff/40001/Source/bindings/scripts/v8_interface.py File Source/bindings/scripts/v8_interface.py (right): https://codereview.chromium.org/577303002/diff/40001/Source/bindings/scripts/v8_interface.py#newcode266 Source/bindings/scripts/v8_interface.py:266: 'constant_configuration_constants': constant_configuration_constants, On 2014/09/23 08:02:51, Jens Widell wrote: > ...
6 years, 2 months ago (2014-09-23 08:31:43 UTC) #21
Jens Widell
On 2014/09/23 08:31:43, haraken wrote: > https://codereview.chromium.org/577303002/diff/40001/Source/bindings/scripts/v8_interface.py > File Source/bindings/scripts/v8_interface.py (right): > > https://codereview.chromium.org/577303002/diff/40001/Source/bindings/scripts/v8_interface.py#newcode266 > ...
6 years, 2 months ago (2014-09-23 09:01:31 UTC) #22
Jens Widell
https://codereview.chromium.org/577303002/diff/40001/Source/bindings/core/v8/V8DOMConfiguration.cpp File Source/bindings/core/v8/V8DOMConfiguration.cpp (right): https://codereview.chromium.org/577303002/diff/40001/Source/bindings/core/v8/V8DOMConfiguration.cpp#newcode104 Source/bindings/core/v8/V8DOMConfiguration.cpp:104: void V8DOMConfiguration::installConstant(v8::Handle<v8::FunctionTemplate> functionDescriptor, v8::Handle<v8::ObjectTemplate> prototype, const char* name, v8::AccessorGetterCallback ...
6 years, 2 months ago (2014-09-23 09:07:33 UTC) #23
haraken
On 2014/09/23 09:01:31, Jens Widell wrote: > On 2014/09/23 08:31:43, haraken wrote: > > > ...
6 years, 2 months ago (2014-09-23 09:09:34 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/577303002/80001
6 years, 2 months ago (2014-09-23 12:08:59 UTC) #26
commit-bot: I haz the power
Committed patchset #5 (id:80001) as 182492
6 years, 2 months ago (2014-09-23 12:50:33 UTC) #27
Nils Barth (inactive)
6 years, 2 months ago (2014-09-23 14:02:12 UTC) #28
Message was sent while issue was closed.
Thanks Jens!
Docs updated:
http://www.chromium.org/blink/webidl/blink-idl-extended-attributes

Powered by Google App Engine
This is Rietveld 408576698