diff tools/mb_c_source.m4 @ 130:3a4d6179e6a9

change mb_c_source.m4 and mb_c_header.m4 to specify parent for SVG object
author Thinker K.F. Li <thinker@branda.to>
date Tue, 16 Sep 2008 21:23:34 +0800
parents cf8ccf06e397
children 6ce68c1f7405
line wrap: on
line diff
--- a/tools/mb_c_source.m4	Tue Sep 16 17:35:04 2008 +0800
+++ b/tools/mb_c_source.m4	Tue Sep 16 21:23:34 2008 +0800
@@ -267,7 +267,7 @@
 #include "mb/paint.h"
 #include "$1.h"
 
-$1_t *$1_new(redraw_man_t *rdman) {
+$1_t *$1_new(redraw_man_t *rdman, coord_t *parent_coord) {
     $1_t *obj;
     grad_stop_t *stops = NULL;]DECLARE_VARS
 $2[]dnl
@@ -275,7 +275,7 @@
     obj = ($1_t *)malloc(sizeof($1_t));
     if(obj == NULL) return NULL;
 ]SETUP_VARS
-    obj->root_coord = rdman_coord_new(rdman, rdman->root_coord);
+    obj->root_coord = rdman_coord_new(rdman, parent_coord);
 $2
 [    return obj;
 }