| Index: Source/bindings/scripts/CodeGeneratorV8.pm
|
| diff --git a/Source/bindings/scripts/CodeGeneratorV8.pm b/Source/bindings/scripts/CodeGeneratorV8.pm
|
| index e676b6b432d0bdc31d07afa704bd8916ab203549..6cc1832f3a41453644e5c794ec6f027cecfb9ec6 100644
|
| --- a/Source/bindings/scripts/CodeGeneratorV8.pm
|
| +++ b/Source/bindings/scripts/CodeGeneratorV8.pm
|
| @@ -3264,6 +3264,57 @@ END
|
| push(@normalAttributes, $attribute);
|
| }
|
| }
|
| +
|
| + # Generate DOMWindow Constructor attributes.
|
| + if ($interfaceName eq "DOMWindow") {
|
| + foreach my $otherInterface ($codeGenerator->GetAllInterfaces()) {
|
| + my $otherInterfaceName = $otherInterface->name;
|
| + if ($otherInterface->extendedAttributes->{"NoInterfaceObject"}) {
|
| + next;
|
| + }
|
| + my $attribute = domAttribute->new();
|
| + $attribute->type("attribute");
|
| + $attribute->signature(domSignature->new());
|
| + $attribute->signature->type("${otherInterfaceName}Constructor");
|
| +
|
| + if ($otherInterface->extendedAttributes->{"InterfaceName"}) {
|
| + $attribute->signature->name($otherInterface->extendedAttributes->{"InterfaceName"});
|
| + } else {
|
| + $attribute->signature->name($otherInterfaceName);
|
| + }
|
| +
|
| + # In addition to the regular property, for every [NamedConstructor] extended attribute on an interface,
|
| + # a corresponding property MUST exist on the ECMAScript global object.
|
| + my $namedConstructorAttribute;
|
| + if ($otherInterface->extendedAttributes->{"NamedConstructor"}) {
|
| + $namedConstructorAttribute = domAttribute->new();
|
| + $namedConstructorAttribute->type("attribute");
|
| + $namedConstructorAttribute->signature(domSignature->new());
|
| + $namedConstructorAttribute->signature->type("${otherInterfaceName}ConstructorConstructor");
|
| + $namedConstructorAttribute->signature->name(@{$otherInterface->constructors}[0]->signature->extendedAttributes->{"NamedConstructor"});
|
| + }
|
| +
|
| + my $attrExtendedAttributeList = {};
|
| + if ($otherInterface->extendedAttributes->{"Conditional"}) {
|
| + $attrExtendedAttributeList->{"Conditional"} = $otherInterface->extendedAttributes->{"Conditional"};
|
| + }
|
| + if ($otherInterface->extendedAttributes->{"EnabledAtRuntime"}) {
|
| + $attrExtendedAttributeList->{"EnabledAtRuntime"} = $otherInterface->extendedAttributes->{"EnabledAtRuntime"};
|
| + push(@enabledAtRuntimeAttributes, $attribute);
|
| + push(@enabledAtRuntimeAttributes, $namedConstructorAttribute) if $namedConstructorAttribute;
|
| + } elsif ($otherInterface->extendedAttributes->{"EnabledPerContext"}) {
|
| + $attrExtendedAttributeList->{"EnabledPerContext"} = $otherInterface->extendedAttributes->{"EnabledPerContext"};
|
| + push(@enabledPerContextAttributes, $attribute);
|
| + push(@enabledPerContextAttributes, $namedConstructorAttribute) if $namedConstructorAttribute;
|
| + } else {
|
| + push(@normalAttributes, $attribute);
|
| + push(@normalAttributes, $namedConstructorAttribute) if $namedConstructorAttribute;
|
| + }
|
| + $attribute->signature->extendedAttributes($attrExtendedAttributeList);
|
| + $namedConstructorAttribute->signature->extendedAttributes($attrExtendedAttributeList) if $namedConstructorAttribute;
|
| + }
|
| + }
|
| +
|
| $attributes = \@normalAttributes;
|
| # Put the attributes that disallow shadowing on the shadow object.
|
| if (@disallowsShadowing) {
|
|
|