char *name;
GtkType type;
GtkType class_type;
- guint access_mask;
+ guint arg_flags;
guint arg_id;
guint seq_id;
};
g_free (lookup_name);
continue;
}
- else if (!info->access_mask & GTK_ARG_READABLE)
+ else if (!info->arg_flags & GTK_ARG_READABLE)
{
g_warning ("arg is not supplied for read-access: \"%s\"\n", lookup_name);
args[i].type = GTK_TYPE_INVALID;
GtkArg*
gtk_object_query_args (GtkType class_type,
- guint **access_masks,
+ guint32 **arg_flags,
+ guint **seq_ids,
guint *nargs)
{
GtkArg *args;
GtkQueryArgData query_data;
- if (access_masks)
- *access_masks = NULL;
+ if (arg_flags)
+ *arg_flags = NULL;
+ if (seq_ids)
+ *seq_ids = NULL;
g_return_val_if_fail (nargs != NULL, NULL);
*nargs = 0;
g_return_val_if_fail (gtk_type_is_a (class_type, gtk_object_get_type ()), NULL);
args = g_new0 (GtkArg, len);
*nargs = len;
- if (access_masks)
- *access_masks = g_new (guint, len);
+ if (arg_flags)
+ *arg_flags = g_new (guint32, len);
+ if (seq_ids)
+ *seq_ids = g_new (guint, len);
do
{
args[info->seq_id - 1].type = info->type;
args[info->seq_id - 1].name = info->name;
- if (access_masks)
- (*access_masks)[info->seq_id - 1] = info->access_mask;
+ if (arg_flags)
+ (*arg_flags)[info->seq_id - 1] = info->arg_flags;
+ if (seq_ids)
+ (*seq_ids)[info->seq_id - 1] = info->seq_id;
}
while (list);
g_warning ("invalid arg for %s: \"%s\"\n", gtk_type_name (object->klass->type), lookup_name);
arg_ok = FALSE;
}
- else if (!info->access_mask & GTK_ARG_WRITABLE)
+ else if (!info->arg_flags & GTK_ARG_WRITABLE)
{
g_warning ("arg is not supplied for write-access: \"%s\"\n", lookup_name);
arg_ok = FALSE;
void
gtk_object_add_arg_type (const char *arg_name,
GtkType arg_type,
- guint access_mask,
+ guint arg_flags,
guint arg_id)
{
GtkArgInfo *info;
g_return_if_fail (arg_name != NULL);
g_return_if_fail (arg_type > GTK_TYPE_NONE);
g_return_if_fail (arg_id > 0);
- g_return_if_fail ((access_mask & GTK_ARG_READWRITE) != 0);
+ g_return_if_fail ((arg_flags & GTK_ARG_READWRITE) != 0);
arg_part = strchr (arg_name, ':');
if (!arg_part || (arg_part[0] != ':') || (arg_part[1] != ':'))
info->name = g_strdup (arg_name);
info->type = arg_type;
info->class_type = class_type;
- info->access_mask = access_mask & (GTK_ARG_READABLE | GTK_ARG_WRITABLE);
+ info->arg_flags = arg_flags & (GTK_ARG_READABLE | GTK_ARG_WRITABLE);
info->arg_id = arg_id;
info->seq_id = ++((GtkObjectClass*) gtk_type_class (class_type))->n_args;
GTK_RESERVED_2 = 1 << 3
};
-/* GtkArg access bits for gtk_object_add_arg_type
+/* GtkArg flag bits for gtk_object_add_arg_type
*/
enum
{
/* Allocate a GtkArg array of size nargs that hold the
* names and types of the args that can be used with
- * gtk_object_set/gtk_object_get. if (acess_masks!=NULL),
- * (*access_mask) will be set to point to a newly allocated
- * guint array that holds the access masks of the args.
+ * gtk_object_set/gtk_object_get. if (arg_flags!=NULL),
+ * (*arg_flags) will be set to point to a newly allocated
+ * guint array that holds the flags of the args.
* It is the callers response to do a
* g_free (returned_args); g_free (*acess_masks).
*/
GtkArg* gtk_object_query_args (GtkType class_type,
- guint **acess_masks,
+ guint32 **arg_flags,
+ guint **seq_ids,
guint *nargs);
void gtk_object_add_arg_type (const gchar *arg_name,
GtkType arg_type,
- guint access_mask,
+ guint arg_flags,
guint arg_id);
GtkType gtk_object_get_arg_type (const gchar *arg_name);