Commit 208057b9 authored by Elliot Lee's avatar Elliot Lee
Browse files

s/string_data/pointer_data/ as needed to match GtkArg



s/string_data/pointer_data/ as needed to match GtkArg
parent e17f31db
......@@ -62,7 +62,7 @@ binding_signal_free (GtkBindingSignal *sig)
for (i = 0; i < sig->n_args; i++)
{
if (sig->args[i].arg_type == GTK_BINDING_ARG_STRING)
g_free (sig->args[i].d.string_data);
g_free (sig->args[i].d.pointer_data);
}
g_free (sig->args);
g_free (sig->signal_name);
......@@ -268,7 +268,7 @@ binding_compose_params (GtkBindingArg *args,
{
case GTK_BINDING_ARG_STRING:
if (params->type == GTK_TYPE_STRING)
GTK_VALUE_STRING (*params) = args->d.string_data;
GTK_VALUE_STRING (*params) = args->d.pointer_data;
else
valid = FALSE;
break;
......@@ -569,14 +569,14 @@ gtk_binding_entry_add_signall (GtkBindingSet *binding_set,
arg->d.double_data = tmp_arg->d.double_data;
break;
case GTK_BINDING_ARG_STRING:
if (!tmp_arg->d.string_data)
if (!tmp_arg->d.pointer_data)
{
g_warning ("gtk_binding_entry_add_signall(): value of `string' arg[%u] is `NULL'", n);
arg->d.string_data = NULL;
arg->d.pointer_data = NULL;
binding_signal_free (signal);
return;
}
arg->d.string_data = g_strdup (tmp_arg->d.string_data);
arg->d.pointer_data = g_strdup (tmp_arg->d.pointer_data);
break;
default:
g_warning ("gtk_binding_entry_add_signall(): unsupported type `%s' for arg[%u]",
......@@ -643,8 +643,8 @@ gtk_binding_entry_add_signal (GtkBindingSet *binding_set,
arg->d.double_data = va_arg (args, gdouble);
break;
case GTK_BINDING_ARG_STRING:
arg->d.string_data = va_arg (args, gchar*);
if (!arg->d.string_data)
arg->d.pointer_data = va_arg (args, gchar*);
if (!arg->d.pointer_data)
{
g_warning ("gtk_binding_entry_add_signal(): value of `string' arg[%u] is `NULL'", i);
i = n_args + 2;
......
......@@ -523,7 +523,7 @@ gtk_arg_copy (GtkArg *src_arg,
dest_arg->d = src_arg->d;
if (src_arg->type == GTK_TYPE_STRING)
dest_arg->d.string_data = g_strdup (src_arg->d.string_data);
dest_arg->d.pointer_data = g_strdup (src_arg->d.pointer_data);
return dest_arg;
}
......
......@@ -106,9 +106,7 @@ struct _GtkArg
gulong ulong_data;
gfloat float_data;
gdouble double_data;
gchar *string_data;
gpointer pointer_data;
GtkObject *object_data;
struct {
GtkCallbackMarshal marshal;
gpointer data;
......@@ -141,7 +139,7 @@ struct _GtkArg
#define GTK_VALUE_ULONG(a) ((a).d.ulong_data)
#define GTK_VALUE_FLOAT(a) ((a).d.float_data)
#define GTK_VALUE_DOUBLE(a) ((a).d.double_data)
#define GTK_VALUE_STRING(a) ((a).d.string_data)
#define GTK_VALUE_STRING(a) ((a).d.pointer_data)
#define GTK_VALUE_ENUM(a) ((a).d.int_data)
#define GTK_VALUE_FLAGS(a) ((a).d.int_data)
#define GTK_VALUE_BOXED(a) ((a).d.pointer_data)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment