summaryrefslogtreecommitdiff
path: root/gtk/gtkobject.c
diff options
context:
space:
mode:
authorTim Janik <timj@gtk.org>1998-08-24 05:27:29 +0000
committerTim Janik <timj@src.gnome.org>1998-08-24 05:27:29 +0000
commit02a871bc3104655c339af984ea111ddc11ced545 (patch)
tree509355697bf71a948b32c2b47d12059101a2ac95 /gtk/gtkobject.c
parentdb10ace6c86c01e8dc08eb76044ad0e64deb3efb (diff)
downloadgdk-pixbuf-02a871bc3104655c339af984ea111ddc11ced545.tar.gz
begin the parameter elipsis (...) after the first argument name. this
Mon Aug 24 02:36:53 1998 Tim Janik <timj@gtk.org> * gtk/gtkarg.h: * gtk/gtkarg.c: * gtk/gtkwidget.h: * gtk/gtkwidget.c: * gtk/gtkobject.h: * gtk/gtkobject.c: * gtk/gtkcontainer.h: * gtk/gtkcontainer.c: (gtk_object_new): (gtk_object_set): (gtk_widget_new): (gtk_widget_set): (gtk_container_add_with_args): (gtk_container_child_set): begin the parameter elipsis (...) after the first argument name. this change is source compatible, since it was always required, even as NULL. (gtk_args_collect): (gtk_object_args_collect): (gtk_container_child_args_collect): changed prototypes to pass first_arg_name, also, pass va_list variable by value (portability concerns). callers changed. * gtk/gtkargcollector.c: implemented gtk_arg_collect_value() as a huge macro GTK_ARG_COLLECT_VALUE() <shrug>. this is needed because we can't pass va_list variables by reference for portability reasons.
Diffstat (limited to 'gtk/gtkobject.c')
-rw-r--r--gtk/gtkobject.c20
1 files changed, 13 insertions, 7 deletions
diff --git a/gtk/gtkobject.c b/gtk/gtkobject.c
index f94b485d4..f8f1d4e2e 100644
--- a/gtk/gtkobject.c
+++ b/gtk/gtkobject.c
@@ -621,7 +621,8 @@ gtk_object_notify_weaks (GtkObject *object)
****************************************************/
GtkObject*
-gtk_object_new (GtkType object_type,
+gtk_object_new (GtkType object_type,
+ const gchar *first_arg_name,
...)
{
GtkObject *object;
@@ -634,11 +635,12 @@ gtk_object_new (GtkType object_type,
object = gtk_type_new (object_type);
- va_start (var_args, object_type);
+ va_start (var_args, first_arg_name);
error = gtk_object_args_collect (GTK_OBJECT_TYPE (object),
&arg_list,
&info_list,
- &var_args);
+ first_arg_name,
+ var_args);
va_end (var_args);
if (error)
@@ -719,6 +721,7 @@ gtk_object_getv (GtkObject *object,
void
gtk_object_set (GtkObject *object,
+ const gchar *first_arg_name,
...)
{
va_list var_args;
@@ -729,11 +732,12 @@ gtk_object_set (GtkObject *object,
g_return_if_fail (object != NULL);
g_return_if_fail (GTK_IS_OBJECT (object));
- va_start (var_args, object);
+ va_start (var_args, first_arg_name);
error = gtk_object_args_collect (GTK_OBJECT_TYPE (object),
&arg_list,
&info_list,
- &var_args);
+ first_arg_name,
+ var_args);
va_end (var_args);
if (error)
@@ -878,13 +882,15 @@ gchar*
gtk_object_args_collect (GtkType object_type,
GSList **arg_list_p,
GSList **info_list_p,
- gpointer var_args_p)
+ const gchar *first_arg_name,
+ va_list var_args)
{
return gtk_args_collect (object_type,
object_arg_info_ht,
arg_list_p,
info_list_p,
- var_args_p);
+ first_arg_name,
+ var_args);
}
gchar*