[glibmm] gmmproc: _WRAP_PROPERTY(): Fix mixed-up deprecation and documentation.



commit 722b9d793b3873d7ecc0c716843953ed2844a84c
Author: Kjell Ahlstedt <kjell ahlstedt bredband net>
Date:   Mon Mar 26 15:10:07 2012 +0200

    gmmproc: _WRAP_PROPERTY(): Fix mixed-up deprecation and documentation.
    
    * tools/pm/Output.pm: Add $deprecated in the first call to _PROPERTY_PROXY().
    * tools/m4/property.m4: Correct comments in .cc files by swapping #endif's
    in _PROPERTY_PROXY().

 ChangeLog            |    8 ++++++++
 tools/m4/property.m4 |    4 ++--
 tools/pm/Output.pm   |   29 +++++++++++++++--------------
 3 files changed, 25 insertions(+), 16 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 570b9b6..7207b90 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2012-03-26  Kjell Ahlstedt  <kjell ahlstedt bredband net>
+
+	gmmproc: _WRAP_PROPERTY(): Fix mixed-up deprecation and documentation.
+
+	* tools/pm/Output.pm: Add $deprecated in the first call to _PROPERTY_PROXY().
+	* tools/m4/property.m4: Correct comments in .cc files by swapping #endif's
+	in _PROPERTY_PROXY().
+
 2012-03-25  Murray Cumming  <murrayc murrayc com>
 
 	Gio: Move AppLaunchContext into its own header file.
diff --git a/tools/m4/property.m4 b/tools/m4/property.m4
index 8b0fde7..2d270a9 100644
--- a/tools/m4/property.m4
+++ b/tools/m4/property.m4
@@ -6,7 +6,7 @@ dnl  Code generation sections for properties
 dnl
 dnl
 
-dnl
+dnl                  $1         $2            $3          $4           $5        $6
 dnl _PROPERTY_PROXY(name, name_underscored, cpp_type, proxy_suffix, deprecated, docs)
 dnl proxy_suffix could be "_WriteOnly" or "_ReadOnly"
 dnl The method will be const if the propertyproxy is _ReadOnly.
@@ -34,9 +34,9 @@ __PROXY_TYPE__ __CPPNAME__::property_$2`'() ifelse($4,_ReadOnly, const,)
 {
   return __PROXY_TYPE__`'(this, "$1");
 }
+#endif //GLIBMM_PROPERTIES_ENABLED
 ifelse(`$5',,,`_DEPRECATE_IFDEF_END
 ')dnl
-#endif //GLIBMM_PROPERTIES_ENABLED
 
 _POP()
 popdef(`__PROXY_TYPE__')dnl
diff --git a/tools/pm/Output.pm b/tools/pm/Output.pm
index 8fa21d7..889b716 100644
--- a/tools/pm/Output.pm
+++ b/tools/pm/Output.pm
@@ -84,20 +84,20 @@ sub error
 
 sub ifdef($$)
 {
-	my ($self, $ifdef) = @_;
-	if ($ifdef)
-	{
-		$self->append("\n#ifdef $ifdef\n");
-	}
+  my ($self, $ifdef) = @_;
+  if ($ifdef)
+  {
+    $self->append("\n#ifdef $ifdef\n");
+  }
 }
 
 sub endif($$)
 {
-	my ($self, $ifdef) = @_;
-	if ($ifdef)
-	{
-		$self->append("\n#endif // $ifdef\n");
-	}
+  my ($self, $ifdef) = @_;
+  if ($ifdef)
+  {
+    $self->append("\n#endif // $ifdef\n");
+  }
 }
 
 ### Convert _WRAP to a virtual 
@@ -669,11 +669,12 @@ sub output_wrap_property($$$$$$$$)
       $self->append("\n_DEPRECATE_IFDEF_START\n");
     }
     
-    my $str = sprintf("_PROPERTY_PROXY(%s,%s,%s,%s,`%s')dnl\n",
+    my $str = sprintf("_PROPERTY_PROXY(%s,%s,%s,%s,%s,`%s')dnl\n",
       $name,
       $name_underscored,
       $cpp_type,
       $proxy_suffix,
+      $deprecated,
       $documentation
     );
     $self->append($str);
@@ -688,7 +689,7 @@ sub output_wrap_property($$$$$$$$)
         $name_underscored,
         $cpp_type,
         "_ReadOnly",
-	$deprecated,
+        $deprecated,
         $documentation
       );
       $self->append($str);
@@ -1109,8 +1110,8 @@ sub output_implements_interface($$)
   my ($self, $interface, $ifdef) = @_;
 
   my $str = sprintf("_IMPLEMENTS_INTERFACE_CC(%s, %s)dnl\n",
-  	$interface,
-  	$ifdef);
+      $interface,
+      $ifdef);
 
   $self->append($str);
 }



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]