+2011-09-26 Xan Lopez <xlopez@igalia.com>
+
+ [GTK] Do not ignore 'Replaceable' attributes in the DOM bindings
+ https://bugs.webkit.org/show_bug.cgi?id=68837
+
+ Reviewed by Martin Robinson.
+
+ * bindings/scripts/CodeGeneratorGObject.pm: add getters (but not
+ setters) for 'Replaceable' attributes. Punt for the future
+ actually making them settable, since it seems non trivial.
+
2011-09-26 Ryosuke Niwa <rniwa@webkit.org>
Leopard build fix.
my $attribute = shift;
if ($attribute->signature->extendedAttributes->{"CustomGetter"} ||
- $attribute->signature->extendedAttributes->{"CustomSetter"} ||
- $attribute->signature->extendedAttributes->{"Replaceable"}) {
+ $attribute->signature->extendedAttributes->{"CustomSetter"}) {
return 1;
}
-
+
my $propType = $attribute->signature->type;
if ($propType =~ /Constructor$/) {
return 1;
$gtype eq "uint64" || $gtype eq "ulong" || $gtype eq "long" ||
$gtype eq "uint" || $gtype eq "ushort" || $gtype eq "uchar" ||
$gtype eq "char" || $gtype eq "string");
- if ($writeable && $hasGtypeSignature) {
+ # FIXME: We are not generating setters for 'Replaceable'
+ # attributes now, but we should somehow.
+ my $replaceable = $property->signature->extendedAttributes->{"Replaceable"};
+ if ($writeable && $hasGtypeSignature && !$replaceable) {
push(@result, $property);
}
}
$function->signature($attribute->signature);
$function->raisesExceptions($attribute->getterExceptions);
$object->GenerateFunction($interfaceName, $function, "get_");
-
- if ($attribute->type =~ /^readonly/) {
+
+ # FIXME: We are not generating setters for 'Replaceable'
+ # attributes now, but we should somehow.
+ if ($attribute->type =~ /^readonly/ ||
+ $attribute->signature->extendedAttributes->{"Replaceable"}) {
next TOP;
}