From 13852a10d4e2a94320f4c6db09a274de0aba63d7 Mon Sep 17 00:00:00 2001 From: Owen Taylor Date: Wed, 28 Nov 2001 23:51:51 +0000 Subject: [PATCH] Rename (private) GSource.id and id parameter to Wed Nov 28 18:34:22 2001 Owen Taylor * glib/gmain.[ch]: Rename (private) GSource.id and id parameter to g_main_context_find_source_by_id() to avoid problems with Objective C where 'id' is a keyword. (#65616) --- ChangeLog | 7 ++++ ChangeLog.pre-2-0 | 7 ++++ ChangeLog.pre-2-10 | 7 ++++ ChangeLog.pre-2-12 | 7 ++++ ChangeLog.pre-2-2 | 7 ++++ ChangeLog.pre-2-4 | 7 ++++ ChangeLog.pre-2-6 | 7 ++++ ChangeLog.pre-2-8 | 7 ++++ docs/reference/ChangeLog | 4 ++ docs/reference/glib/glib-sections.txt | 1 + docs/reference/glib/tmpl/main.sgml | 4 +- docs/reference/glib/tmpl/trees-binary.sgml | 2 +- docs/reference/glib/tmpl/trees-nary.sgml | 2 +- docs/reference/gobject/tmpl/gobject-unused.sgml | 56 +++++++++++++++++++++++++ docs/reference/gobject/tmpl/gtype.sgml | 56 ------------------------- glib/gmain.c | 12 +++--- glib/gmain.h | 4 +- 17 files changed, 130 insertions(+), 67 deletions(-) diff --git a/ChangeLog b/ChangeLog index dc0a824..1d0f6f5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +Wed Nov 28 18:34:22 2001 Owen Taylor + + * glib/gmain.[ch]: Rename (private) GSource.id and + id parameter to g_main_context_find_source_by_id() + to avoid problems with Objective C where 'id' is + a keyword. (#65616) + 2001-11-28 Daniel Elstner * glib/gutf8.c (utf8_skip_data): In order to avoid infinite loops diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index dc0a824..1d0f6f5 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,10 @@ +Wed Nov 28 18:34:22 2001 Owen Taylor + + * glib/gmain.[ch]: Rename (private) GSource.id and + id parameter to g_main_context_find_source_by_id() + to avoid problems with Objective C where 'id' is + a keyword. (#65616) + 2001-11-28 Daniel Elstner * glib/gutf8.c (utf8_skip_data): In order to avoid infinite loops diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index dc0a824..1d0f6f5 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,10 @@ +Wed Nov 28 18:34:22 2001 Owen Taylor + + * glib/gmain.[ch]: Rename (private) GSource.id and + id parameter to g_main_context_find_source_by_id() + to avoid problems with Objective C where 'id' is + a keyword. (#65616) + 2001-11-28 Daniel Elstner * glib/gutf8.c (utf8_skip_data): In order to avoid infinite loops diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12 index dc0a824..1d0f6f5 100644 --- a/ChangeLog.pre-2-12 +++ b/ChangeLog.pre-2-12 @@ -1,3 +1,10 @@ +Wed Nov 28 18:34:22 2001 Owen Taylor + + * glib/gmain.[ch]: Rename (private) GSource.id and + id parameter to g_main_context_find_source_by_id() + to avoid problems with Objective C where 'id' is + a keyword. (#65616) + 2001-11-28 Daniel Elstner * glib/gutf8.c (utf8_skip_data): In order to avoid infinite loops diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index dc0a824..1d0f6f5 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,10 @@ +Wed Nov 28 18:34:22 2001 Owen Taylor + + * glib/gmain.[ch]: Rename (private) GSource.id and + id parameter to g_main_context_find_source_by_id() + to avoid problems with Objective C where 'id' is + a keyword. (#65616) + 2001-11-28 Daniel Elstner * glib/gutf8.c (utf8_skip_data): In order to avoid infinite loops diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index dc0a824..1d0f6f5 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,10 @@ +Wed Nov 28 18:34:22 2001 Owen Taylor + + * glib/gmain.[ch]: Rename (private) GSource.id and + id parameter to g_main_context_find_source_by_id() + to avoid problems with Objective C where 'id' is + a keyword. (#65616) + 2001-11-28 Daniel Elstner * glib/gutf8.c (utf8_skip_data): In order to avoid infinite loops diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index dc0a824..1d0f6f5 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,10 @@ +Wed Nov 28 18:34:22 2001 Owen Taylor + + * glib/gmain.[ch]: Rename (private) GSource.id and + id parameter to g_main_context_find_source_by_id() + to avoid problems with Objective C where 'id' is + a keyword. (#65616) + 2001-11-28 Daniel Elstner * glib/gutf8.c (utf8_skip_data): In order to avoid infinite loops diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index dc0a824..1d0f6f5 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,10 @@ +Wed Nov 28 18:34:22 2001 Owen Taylor + + * glib/gmain.[ch]: Rename (private) GSource.id and + id parameter to g_main_context_find_source_by_id() + to avoid problems with Objective C where 'id' is + a keyword. (#65616) + 2001-11-28 Daniel Elstner * glib/gutf8.c (utf8_skip_data): In order to avoid infinite loops diff --git a/docs/reference/ChangeLog b/docs/reference/ChangeLog index eca9728..ad6c40d 100644 --- a/docs/reference/ChangeLog +++ b/docs/reference/ChangeLog @@ -1,3 +1,7 @@ +Wed Nov 28 18:50:19 2001 Owen Taylor + + * glib/glib-sections.txt: Update. + 2001-11-28 Sebastian Wilhelmi * glib/tmpl/date.sgml: Fix g_usleep docs. diff --git a/docs/reference/glib/glib-sections.txt b/docs/reference/glib/glib-sections.txt index caf539d..a7c94cd 100644 --- a/docs/reference/glib/glib-sections.txt +++ b/docs/reference/glib/glib-sections.txt @@ -43,6 +43,7 @@ gssize gldouble GLIB_SIZEOF_VOID_P GLIB_SIZEOF_LONG +GLIB_SIZEOF_SIZE_T
diff --git a/docs/reference/glib/tmpl/main.sgml b/docs/reference/glib/tmpl/main.sgml index cbfc0f0..d7c0e86 100644 --- a/docs/reference/glib/tmpl/main.sgml +++ b/docs/reference/glib/tmpl/main.sgml @@ -349,8 +349,10 @@ g_main_context_pending(). @context: -@id: +@source_id: @Returns: + +@id: diff --git a/docs/reference/glib/tmpl/trees-binary.sgml b/docs/reference/glib/tmpl/trees-binary.sgml index 7e9a558..36af29e 100644 --- a/docs/reference/glib/tmpl/trees-binary.sgml +++ b/docs/reference/glib/tmpl/trees-binary.sgml @@ -178,10 +178,10 @@ Specifies the type of traveral performed by g_tree_traverse(), g_node_traverse() and g_node_find(). -@G_PRE_ORDER: visits a node, then its children. @G_IN_ORDER: vists a node's left child first, then the node itself, then its right child. This is the one to use if you want the output sorted according to the compare function. +@G_PRE_ORDER: visits a node, then its children. @G_POST_ORDER: visits the node's children, then the node itself. @G_LEVEL_ORDER: is not implemented for Balanced Binary Trees. diff --git a/docs/reference/glib/tmpl/trees-nary.sgml b/docs/reference/glib/tmpl/trees-nary.sgml index 647ae0b..ee83166 100644 --- a/docs/reference/glib/tmpl/trees-nary.sgml +++ b/docs/reference/glib/tmpl/trees-nary.sgml @@ -224,7 +224,7 @@ Specifies which nodes are visited during several of the tree functions, including g_node_traverse() and g_node_find(). -@G_TRAVERSE_LEAFS: only leaf nodes should be visited. +@G_TRAVERSE_LEAFS: only leaf nodes should be visited. @G_TRAVERSE_NON_LEAFS: only non-leaf nodes should be visited. @G_TRAVERSE_ALL: all nodes should be visited. @G_TRAVERSE_MASK: diff --git a/docs/reference/gobject/tmpl/gobject-unused.sgml b/docs/reference/gobject/tmpl/gobject-unused.sgml index 70a7e1e..b04f4a8 100644 --- a/docs/reference/gobject/tmpl/gobject-unused.sgml +++ b/docs/reference/gobject/tmpl/gobject-unused.sgml @@ -46,6 +46,62 @@ Parameter Specifications @parent_instance: + + +The predefined identifiers of the reserved fundamental types. + + +@G_TYPE_INVALID: Usually a return value indicating an error. +@G_TYPE_NONE: A synonym for the "void" type in C. +@G_TYPE_INTERFACE: Root type of all interface types. +@G_TYPE_CHAR: Identifier for the built-in type "gchar". +@G_TYPE_UCHAR: Identifier for the built-in type "guchar". +@G_TYPE_BOOLEAN: Identifier for the built-in type "gboolean". +@G_TYPE_INT: Identifier for the built-in type "gint". +@G_TYPE_UINT: Identifier for the built-in type "guint". +@G_TYPE_LONG: Identifier for the built-in type "glong". +@G_TYPE_ULONG: Identifier for the built-in type "gulong". +@G_TYPE_INT64: +@G_TYPE_UINT64: +@G_TYPE_ENUM: Identifier for the "#GEnum" type. +@G_TYPE_FLAGS: Identifier for the "#GFlags" type. +@G_TYPE_FLOAT: Identifier for the built-in type "gfloat". +@G_TYPE_DOUBLE: Identifier for the built-in type "gdouble". +@G_TYPE_STRING: Identifier for a pointer to a null-terminated string "gchar*". +@G_TYPE_POINTER: Identifier for anonymous pointers "void*". +@G_TYPE_BOXED: Identifier for the "#GBoxed" type. +@G_TYPE_PARAM: Identifier for the "#GParam" type. +@G_TYPE_OBJECT: Identifier for the "#GObject" type. +@G_TYPE_RESERVED_BSE_FIRST: First fundamental type ID reserved for BSE. +@G_TYPE_RESERVED_BSE_LAST: Last fundamental type ID reserved for BSE. +@G_TYPE_RESERVED_LAST_FUNDAMENTAL: +@G_TYPE_CONSTANT_TYPES: +@G_TYPE_CLOSURE: +@G_TYPE_VALUE: +@G_TYPE_VALUE_ARRAY: +@G_TYPE_GSTRING: +@G_TYPE_PARAM_CHAR: +@G_TYPE_PARAM_UCHAR: +@G_TYPE_PARAM_BOOLEAN: +@G_TYPE_PARAM_INT: +@G_TYPE_PARAM_UINT: +@G_TYPE_PARAM_LONG: +@G_TYPE_PARAM_ULONG: +@G_TYPE_PARAM_INT64: +@G_TYPE_PARAM_UINT64: +@G_TYPE_PARAM_UNICHAR: +@G_TYPE_PARAM_ENUM: +@G_TYPE_PARAM_FLAGS: +@G_TYPE_PARAM_FLOAT: +@G_TYPE_PARAM_DOUBLE: +@G_TYPE_PARAM_STRING: +@G_TYPE_PARAM_PARAM: +@G_TYPE_PARAM_BOXED: +@G_TYPE_PARAM_POINTER: +@G_TYPE_PARAM_VALUE_ARRAY: +@G_TYPE_PARAM_CLOSURE: +@G_TYPE_PARAM_OBJECT: + diff --git a/docs/reference/gobject/tmpl/gtype.sgml b/docs/reference/gobject/tmpl/gtype.sgml index fe6ce1c..9e85621 100644 --- a/docs/reference/gobject/tmpl/gtype.sgml +++ b/docs/reference/gobject/tmpl/gtype.sgml @@ -161,62 +161,6 @@ interfaces and C++ classes containing only pure virtual functions. @type: A #GType value. - - -The predefined identifiers of the reserved fundamental types. - - -@G_TYPE_INVALID: Usually a return value indicating an error. -@G_TYPE_NONE: A synonym for the "void" type in C. -@G_TYPE_INTERFACE: Root type of all interface types. -@G_TYPE_CHAR: Identifier for the built-in type "gchar". -@G_TYPE_UCHAR: Identifier for the built-in type "guchar". -@G_TYPE_BOOLEAN: Identifier for the built-in type "gboolean". -@G_TYPE_INT: Identifier for the built-in type "gint". -@G_TYPE_UINT: Identifier for the built-in type "guint". -@G_TYPE_LONG: Identifier for the built-in type "glong". -@G_TYPE_ULONG: Identifier for the built-in type "gulong". -@G_TYPE_INT64: -@G_TYPE_UINT64: -@G_TYPE_ENUM: Identifier for the "#GEnum" type. -@G_TYPE_FLAGS: Identifier for the "#GFlags" type. -@G_TYPE_FLOAT: Identifier for the built-in type "gfloat". -@G_TYPE_DOUBLE: Identifier for the built-in type "gdouble". -@G_TYPE_STRING: Identifier for a pointer to a null-terminated string "gchar*". -@G_TYPE_POINTER: Identifier for anonymous pointers "void*". -@G_TYPE_BOXED: Identifier for the "#GBoxed" type. -@G_TYPE_PARAM: Identifier for the "#GParam" type. -@G_TYPE_OBJECT: Identifier for the "#GObject" type. -@G_TYPE_RESERVED_BSE_FIRST: First fundamental type ID reserved for BSE. -@G_TYPE_RESERVED_BSE_LAST: Last fundamental type ID reserved for BSE. -@G_TYPE_RESERVED_LAST_FUNDAMENTAL: -@G_TYPE_CONSTANT_TYPES: -@G_TYPE_CLOSURE: -@G_TYPE_VALUE: -@G_TYPE_VALUE_ARRAY: -@G_TYPE_GSTRING: -@G_TYPE_PARAM_CHAR: -@G_TYPE_PARAM_UCHAR: -@G_TYPE_PARAM_BOOLEAN: -@G_TYPE_PARAM_INT: -@G_TYPE_PARAM_UINT: -@G_TYPE_PARAM_LONG: -@G_TYPE_PARAM_ULONG: -@G_TYPE_PARAM_INT64: -@G_TYPE_PARAM_UINT64: -@G_TYPE_PARAM_UNICHAR: -@G_TYPE_PARAM_ENUM: -@G_TYPE_PARAM_FLAGS: -@G_TYPE_PARAM_FLOAT: -@G_TYPE_PARAM_DOUBLE: -@G_TYPE_PARAM_STRING: -@G_TYPE_PARAM_PARAM: -@G_TYPE_PARAM_BOXED: -@G_TYPE_PARAM_POINTER: -@G_TYPE_PARAM_VALUE_ARRAY: -@G_TYPE_PARAM_CLOSURE: -@G_TYPE_PARAM_OBJECT: - An opaque structure used as the base of all interface types. diff --git a/glib/gmain.c b/glib/gmain.c index 3d1fa0b..5b7d920 100644 --- a/glib/gmain.c +++ b/glib/gmain.c @@ -794,7 +794,7 @@ g_source_attach (GSource *source, LOCK_CONTEXT (context); source->context = context; - result = source->id = context->next_id++; + result = source->source_id = context->next_id++; source->ref_count++; g_source_list_add (source, context); @@ -901,7 +901,7 @@ g_source_get_id (GSource *source) g_return_val_if_fail (source->context != NULL, 0); LOCK_CONTEXT (source->context); - result = source->id; + result = source->source_id; UNLOCK_CONTEXT (source->context); return result; @@ -1317,7 +1317,7 @@ g_source_unref (GSource *source) /** * g_main_context_find_source_by_id: * @context: a #GMainContext (if %NULL, the default context will be used) - * @id: the source ID, as returned by g_source_get_id() + * @source_id: the source ID, as returned by g_source_get_id() * * Finds a #GSource given a pair of context and ID * @@ -1325,11 +1325,11 @@ g_source_unref (GSource *source) **/ GSource * g_main_context_find_source_by_id (GMainContext *context, - guint id) + guint source_id) { GSource *source; - g_return_val_if_fail (id > 0, FALSE); + g_return_val_if_fail (source_id > 0, FALSE); if (context == NULL) context = g_main_context_default (); @@ -1340,7 +1340,7 @@ g_main_context_find_source_by_id (GMainContext *context, while (source) { if (!SOURCE_DESTROYED (source) && - source->id == id) + source->source_id == source_id) break; source = source->next; } diff --git a/glib/gmain.h b/glib/gmain.h index cd95288..49e8acc 100644 --- a/glib/gmain.h +++ b/glib/gmain.h @@ -46,7 +46,7 @@ struct _GSource gint priority; guint flags; - guint id; + guint source_id; GSList *poll_fds; @@ -143,7 +143,7 @@ gboolean g_main_context_pending (GMainContext *context); /* For implementation of legacy interfaces */ GSource *g_main_context_find_source_by_id (GMainContext *context, - guint id); + guint source_id); GSource *g_main_context_find_source_by_user_data (GMainContext *context, gpointer user_data); GSource *g_main_context_find_source_by_funcs_user_data (GMainContext *context, -- 2.7.4