Title: [96009] trunk/Source/WebCore
Revision
96009
Author
[email protected]
Date
2011-09-26 15:28:31 -0700 (Mon, 26 Sep 2011)

Log Message

[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.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (96008 => 96009)


--- trunk/Source/WebCore/ChangeLog	2011-09-26 22:27:19 UTC (rev 96008)
+++ trunk/Source/WebCore/ChangeLog	2011-09-26 22:28:31 UTC (rev 96009)
@@ -1,3 +1,14 @@
+2011-09-26  Xan Lopez  <[email protected]>
+
+        [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  <[email protected]>
 
         Leopard build fix.

Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorGObject.pm (96008 => 96009)


--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorGObject.pm	2011-09-26 22:27:19 UTC (rev 96008)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorGObject.pm	2011-09-26 22:28:31 UTC (rev 96009)
@@ -155,11 +155,10 @@
     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;
@@ -307,7 +306,10 @@
                                  $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);
         }
     }
@@ -1039,8 +1041,11 @@
         $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;
         }
         
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to