Chromium Code Reviews| Index: Source/bindings/scripts/deprecated_code_generator_v8.pm |
| diff --git a/Source/bindings/scripts/deprecated_code_generator_v8.pm b/Source/bindings/scripts/deprecated_code_generator_v8.pm |
| index a96f3b6f7e6162c7e5c45feb4cd84bc2ea9a3ebb..fc475ef29ef074251ec28539829ae7d95e0c873e 100644 |
| --- a/Source/bindings/scripts/deprecated_code_generator_v8.pm |
| +++ b/Source/bindings/scripts/deprecated_code_generator_v8.pm |
| @@ -819,7 +819,8 @@ public: |
| }; |
| END |
| - my $customWrap = $interface->extendedAttributes->{"CustomToV8"}; |
| + my $setHiddenValue = $interface->extendedAttributes->{"SetHiddenValueTo"}; |
| + my $customWrap = $interface->extendedAttributes->{"CustomToV8"} || $setHiddenValue; |
| if ($noToV8) { |
| die "Can't suppress toV8 for subclass\n" if $interface->parent; |
| } elsif ($noWrap) { |
| @@ -4002,6 +4003,30 @@ v8::Handle<v8::Object> wrap($implClassName* impl, v8::Handle<v8::Object> creatio |
| END |
| } |
| + my $setHiddenValue = $interface->extendedAttributes->{"SetHiddenValueTo"}; |
| + if ($setHiddenValue) { |
| + my @hiddenValues = split /\s*\|\s*/, $setHiddenValue; |
| + |
|
kouhei (in TOK)
2013/09/10 01:30:34
I think we need to addIncludesForType(<$setHiddenV
Nils Barth (inactive)
2013/09/10 01:50:55
Discussed offline; issue is that required include
|
| + $implementation{nameSpaceWebCore}->add(<<END); |
| +v8::Handle<v8::Object> wrap($implClassName* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate) |
| +{ |
| + ASSERT(impl); |
| + v8::Handle<v8::Object> wrapper = ${v8ClassName}::createWrapper(impl, creationContext, isolate); |
| +END |
| + foreach my $hiddenValue (@hiddenValues) { |
| + $implementation{nameSpaceWebCore}->add(<<END); |
| + if (impl->$hiddenValue()) |
| + V8HiddenPropertyName::setNamedHiddenReference(wrapper, "$hiddenValue", toV8(impl->$hiddenValue(), creationContext, isolate)); |
| +END |
| + } |
| + |
| + $implementation{nameSpaceWebCore}->add(<<END); |
| + return wrapper; |
| +} |
| + |
| +END |
| + } |
| + |
| my @enabledPerContextFunctions; |
| my @normalFunctions; |
| my $needsDomainSafeFunctionSetter = 0; |