glib' error patch
- From: Mathieu Lacage <mathieu eazel com>
- To: gtk-devel-list gnome org
- Subject: glib' error patch
- Date: 07 Dec 2000 14:42:22 -0800
hi all,
here is the patch I discussed with havoc:
Index: gerror.c
===================================================================
RCS file: /cvs/gnome/glib/gerror.c,v
retrieving revision 1.18
diff -u -r1.18 gerror.c
--- gerror.c 2000/11/05 17:02:35 1.18
+++ gerror.c 2000/12/07 19:28:25
@@ -29,6 +29,8 @@
static GError*
g_error_new_valist(GQuark domain,
gint code,
+ const gpointer data,
+ GDestroyNotify destroy_notify,
const gchar *format,
va_list args)
{
@@ -39,6 +41,8 @@
error->domain = domain;
error->code = code;
error->message = g_strdup_vprintf (format, args);
+ error->data = data;
+ error->destroy_notify = destroy_notify;
return error;
}
@@ -68,13 +72,51 @@
g_return_val_if_fail (domain != 0, NULL);
va_start (args, format);
- error = g_error_new_valist (domain, code, format, args);
+ error = g_error_new_valist (domain, code, NULL, NULL, format, args);
va_end (args);
return error;
}
/**
+ * g_error_new_with_data:
+ * @domain: error domain
+ * @code: error code
+ * @data: error data
+ * @destroy_notify: data destruction handler.
+ * @format: printf()-style format for error message
+ * @Varargs: parameters for message format
+ *
+ * Creates a new #GError with the given @domain, @code,
+ * @data and a message formatted with @format.
+ * @destroy_notify can be NULL if you do not want to destroy
+ * the data.
+ *
+ * Return value: a new #GError
+ **/
+GError*
+g_error_new_with_data (GQuark domain,
+ gint code,
+ const gpointer data,
+ GDestroyNotify destroy_notify,
+ const gchar *format,
+ ...)
+{
+ GError* error;
+ va_list args;
+
+ g_return_val_if_fail (format != NULL, NULL);
+ g_return_val_if_fail (domain != 0, NULL);
+ g_return_val_if_fail (data != NULL, NULL);
+
+ va_start (args, format);
+ error = g_error_new_valist (domain, code, data, destroy_notify, format, args);
+ va_end (args);
+
+ return error;
+}
+
+/**
* g_error_new_literal:
* @domain: error domain
* @code: error code
@@ -92,18 +134,20 @@
gint code,
const gchar *message)
{
- GError* err;
+ GError* error;
g_return_val_if_fail (message != NULL, NULL);
g_return_val_if_fail (domain != 0, NULL);
- err = g_new (GError, 1);
+ error = g_new (GError, 1);
- err->domain = domain;
- err->code = code;
- err->message = g_strdup (message);
+ error->domain = domain;
+ error->code = code;
+ error->message = g_strdup (message);
+ error->data = NULL;
+ error->destroy_notify = NULL;
- return err;
+ return error;
}
/**
@@ -119,6 +163,9 @@
g_return_if_fail (error != NULL);
g_free (error->message);
+ if (error->destroy_notify != NULL) {
+ (* error->destroy_notify) (error->data);
+ }
g_free (error);
}
@@ -137,6 +184,7 @@
GError *copy;
g_return_val_if_fail (error != NULL, NULL);
+ g_return_val_if_fail (error->data != NULL, NULL);
copy = g_new (GError, 1);
@@ -197,8 +245,43 @@
if (*err != NULL)
g_warning (ERROR_OVERWRITTEN_WARNING);
+ va_start (args, format);
+ *err = g_error_new_valist (domain, code, NULL, NULL, format, args);
+ va_end (args);
+}
+
+/**
+ * g_set_data_error:
+ * @err: a return location for a #GError, or NULL
+ * @domain: error domain
+ * @code: error code
+ * @data: error data
+ * @destroy_notify: destroy callback
+ * @format: printf()-style format
+ * @Varargs: args for @format
+ *
+ * Does nothing if @err is NULL; if @err is non-NULL, then * err must
+ * be NULL. A new #GError is created and assigned to * err
+ **/
+void
+g_set_data_error (GError **err,
+ GQuark domain,
+ gint code,
+ const gpointer data,
+ GDestroyNotify destroy_notify,
+ const gchar *format,
+ ...)
+{
+ va_list args;
+
+ if (err == NULL)
+ return;
+
+ if (*err != NULL)
+ g_warning (ERROR_OVERWRITTEN_WARNING);
+
va_start (args, format);
- *err = g_error_new_valist (domain, code, format, args);
+ *err = g_error_new_valist (domain, code, data, destroy_notify, format, args);
va_end (args);
}
Index: gerror.h
===================================================================
RCS file: /cvs/gnome/glib/gerror.h,v
retrieving revision 1.4
diff -u -r1.4 gerror.h
--- gerror.h 2000/10/12 11:52:07 1.4
+++ gerror.h 2000/12/07 19:28:25
@@ -29,9 +29,11 @@
struct _GError
{
- GQuark domain;
- gint code;
- gchar *message;
+ GQuark domain;
+ gint code;
+ gchar *message;
+ gpointer data;
+ GDestroyNotify destroy_notify;
};
GError* g_error_new (GQuark domain,
@@ -39,6 +41,14 @@
const gchar *format,
...) G_GNUC_PRINTF (3, 4);
+GError* g_error_new_with_data (GQuark domain,
+ gint code,
+ const gpointer data,
+ GDestroyNotify destroy_notify,
+ const gchar *format,
+ ...) G_GNUC_PRINTF (5, 6);
+
+
GError* g_error_new_literal (GQuark domain,
gint code,
const gchar *message);
@@ -58,6 +68,15 @@
gint code,
const gchar *format,
...) G_GNUC_PRINTF (4, 5);
+
+void g_set_data_error (GError **err,
+ GQuark domain,
+ gint code,
+ const gpointer data,
+ GDestroyNotify destroy_notify,
+ const gchar *format,
+ ...) G_GNUC_PRINTF (6, 7);
+
/* if (dest) *dest = src; also has some sanity checks.
*/
Index: docs/reference/glib/tmpl/completion.sgml
===================================================================
RCS file: /cvs/gnome/glib/docs/reference/glib/tmpl/completion.sgml,v
retrieving revision 1.5
diff -u -r1.5 completion.sgml
--- docs/reference/glib/tmpl/completion.sgml 2000/12/05 20:43:57 1.5
+++ docs/reference/glib/tmpl/completion.sgml 2000/12/07 19:28:25
@@ -71,16 +71,6 @@
@Returns: the string corresponding to the item.
-<!-- ##### USER_FUNCTION GCompletionStrcmpFunc ##### -->
-<para>
-
-</para>
-
- s1:
- s2:
- Returns:
-
-
<!-- ##### FUNCTION g_completion_add_items ##### -->
<para>
Adds items to the #GCompletion.
Index: docs/reference/glib/tmpl/error_reporting.sgml
===================================================================
RCS file: /cvs/gnome/glib/docs/reference/glib/tmpl/error_reporting.sgml,v
retrieving revision 1.5
diff -u -r1.5 error_reporting.sgml
--- docs/reference/glib/tmpl/error_reporting.sgml 2000/11/05 17:02:37 1.5
+++ docs/reference/glib/tmpl/error_reporting.sgml 2000/12/07 19:28:26
@@ -378,6 +378,8 @@
@domain: error domain, e.g. #G_FILE_ERROR
@code: error code, e.g. %G_FILE_ERROR_NOENT
@message: human-readable informative error message
+ data:
+ destroy_notify:
<!-- ##### FUNCTION g_error_new ##### -->
<para>
Index: docs/reference/glib/tmpl/glib-unused.sgml
===================================================================
RCS file: /cvs/gnome/glib/docs/reference/glib/tmpl/glib-unused.sgml,v
retrieving revision 1.12
diff -u -r1.12 glib-unused.sgml
--- docs/reference/glib/tmpl/glib-unused.sgml 2000/12/05 20:43:57 1.12
+++ docs/reference/glib/tmpl/glib-unused.sgml 2000/12/07 19:28:26
@@ -1,24 +1,19 @@
-<!-- ##### FUNCTION g_main_remove_poll ##### -->
+<!-- ##### FUNCTION g_source_connect_indirect ##### -->
<para>
-Removes a file descriptor from the list being polled.
-</para>
- fd: the #GPollFD to remove.
-
-<!-- ##### MACRO lseek ##### -->
-<para>
-
</para>
+ source:
+ callback_data:
+ callback_funcs:
-<!-- ##### FUNCTION g_convert_error_quark ##### -->
+<!-- ##### MACRO popen ##### -->
<para>
</para>
- Returns:
-<!-- ##### MACRO write ##### -->
+<!-- ##### MACRO pclose ##### -->
<para>
</para>
@@ -39,27 +34,14 @@
the results may be needed.
See #G_PRIORITY_DEFAULT, #G_PRIORITY_DEFAULT_IDLE, #G_PRIORITY_HIGH,
#G_PRIORITY_HIGH_IDLE, and #G_PRIORITY_LOW.
-
-<!-- ##### MACRO pclose ##### -->
-<para>
-
-</para>
-
-
-<!-- ##### MACRO g_string ##### -->
-<para>
-Turns the argument into a string literal by using the '#' stringizing operator.
-</para>
- x: text to convert to a literal string.
-
-<!-- ##### MACRO popen ##### -->
+<!-- ##### MACRO lseek ##### -->
<para>
</para>
-<!-- ##### MACRO access ##### -->
+<!-- ##### MACRO getpid ##### -->
<para>
</para>
@@ -78,17 +60,19 @@
type of source.
@Returns: TRUE if an event source was found and removed.
-<!-- ##### MACRO open ##### -->
+<!-- ##### MACRO close ##### -->
<para>
</para>
-<!-- ##### MACRO getpid ##### -->
+<!-- ##### FUNCTION g_source_add ##### -->
<para>
-
</para>
+ source:
+ context:
+ Returns:
<!-- ##### MACRO fdopen ##### -->
<para>
@@ -96,11 +80,24 @@
</para>
-<!-- ##### MACRO close ##### -->
+<!-- ##### USER_FUNCTION GCompletionStrcmpFunc ##### -->
+<para>
+
+</para>
+
+ s1:
+ s2:
+ Returns:
+
+<!-- ##### FUNCTION g_source_connect ##### -->
<para>
</para>
+ source:
+ func:
+ data:
+ notify:
<!-- ##### MACRO getcwd ##### -->
<para>
@@ -108,16 +105,55 @@
</para>
-<!-- ##### MACRO read ##### -->
+<!-- ##### MACRO write ##### -->
<para>
</para>
+<!-- ##### FUNCTION g_main_remove_poll ##### -->
+<para>
+Removes a file descriptor from the list being polled.
+</para>
+
+ fd: the #GPollFD to remove.
+
+<!-- ##### MACRO access ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### MACRO g_string ##### -->
+<para>
+Turns the argument into a string literal by using the '#' stringizing operator.
+</para>
+
+ x: text to convert to a literal string.
+
<!-- ##### FUNCTION g_main_win32_get_poll_func ##### -->
<para>
</para>
@Returns:
+
+<!-- ##### MACRO read ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### FUNCTION g_convert_error_quark ##### -->
+<para>
+
+</para>
+
+ Returns:
+
+<!-- ##### MACRO open ##### -->
+<para>
+
+</para>
+
Index: docs/reference/glib/tmpl/macros_misc.sgml
===================================================================
RCS file: /cvs/gnome/glib/docs/reference/glib/tmpl/macros_misc.sgml,v
retrieving revision 1.8
diff -u -r1.8 macros_misc.sgml
--- docs/reference/glib/tmpl/macros_misc.sgml 2000/10/30 16:08:23 1.8
+++ docs/reference/glib/tmpl/macros_misc.sgml 2000/12/07 19:28:26
@@ -66,7 +66,6 @@
Portable way to copy <type>va_list</type> variables.
</para>
-<!-- # Unused Parameters # -->
@ap1: the <type>va_list</type> variable to place a copy of @ap2 in.
@ap2: a <type>va_list</type>.
Index: docs/reference/glib/tmpl/main.sgml
===================================================================
RCS file: /cvs/gnome/glib/docs/reference/glib/tmpl/main.sgml,v
retrieving revision 1.7
diff -u -r1.7 main.sgml
--- docs/reference/glib/tmpl/main.sgml 2000/12/05 20:43:57 1.7
+++ docs/reference/glib/tmpl/main.sgml 2000/12/07 19:28:26
@@ -96,6 +96,7 @@
<graphic fileref="mainloop-states.gif" format="gif"></graphic>
</figure>
</refsect2>
+
<!-- ##### SECTION See_Also ##### -->
<para>
@@ -458,22 +459,22 @@
<!-- ##### FUNCTION g_timeout_add ##### -->
<para>
</para>
-
- interval:
- function:
- data:
- Returns:
+ interval:
+ function:
+ data:
+ Returns:
+
<!-- ##### FUNCTION g_timeout_add_full ##### -->
<para>
</para>
- priority:
+ priority:
@interval:
- function:
- data:
- notify:
+ function:
+ data:
+ notify:
@Returns:
@@ -672,15 +673,6 @@
@source:
-<!-- ##### FUNCTION g_source_add ##### -->
-<para>
-</para>
-
- source:
- context:
- Returns:
-
-
<!-- ##### FUNCTION g_source_destroy ##### -->
<para>
@@ -743,17 +735,6 @@
@Returns:
-<!-- ##### FUNCTION g_source_connect ##### -->
-<para>
-
-</para>
-
- source:
- func:
- data:
- notify:
-
-
<!-- ##### USER_FUNCTION GSourceFunc ##### -->
<para>
Specifies the type of function passed to g_timeout_add(), g_timeout_add_full(),
@@ -765,16 +746,6 @@
@Returns: it should return FALSE if the source should be removed.
-<!-- ##### FUNCTION g_source_connect_indirect ##### -->
-<para>
-
-</para>
-
- source:
- callback_data:
- callback_funcs:
-
-
<!-- ##### FUNCTION g_source_add_poll ##### -->
<para>
@@ -825,7 +796,6 @@
@user_data:
@Returns:
-
<!--
Local variables:
Index: docs/reference/gobject/tmpl/gobject-unused.sgml
===================================================================
RCS file: /cvs/gnome/glib/docs/reference/gobject/tmpl/gobject-unused.sgml,v
retrieving revision 1.6
diff -u -r1.6 gobject-unused.sgml
--- docs/reference/gobject/tmpl/gobject-unused.sgml 2000/12/05 20:43:58 1.6
+++ docs/reference/gobject/tmpl/gobject-unused.sgml 2000/12/07 19:28:27
@@ -1,36 +1,33 @@
-<!-- ##### SECTION ./tmpl/gtypemodule.sgml.sgml:Long_Description ##### -->
+<!-- ##### SECTION ./tmpl/gtypemodule.sgml.sgml:See_Also ##### -->
<para>
</para>
-<!-- ##### USER_FUNCTION GTypePluginUnRef ##### -->
+<!-- ##### USER_FUNCTION GTypePluginRef ##### -->
<para>
</para>
@plugin:
-<!-- ##### FUNCTION g_signals_destroy ##### -->
+<!-- ##### ENUM GSignalType ##### -->
<para>
</para>
-
- itype:
-
-<!-- ##### SECTION ./tmpl/gtypemodule.sgml.sgml:Short_Description ##### -->
-
+ G_SIGNAL_RUN_FIRST:
+ G_SIGNAL_RUN_LAST:
+ G_SIGNAL_RUN_CLEANUP:
+ G_SIGNAL_NO_RECURSE:
+ G_SIGNAL_ACTION:
+ G_SIGNAL_NO_HOOKS:
-<!-- ##### STRUCT GTypePluginVTable ##### -->
+<!-- ##### SECTION ./tmpl/gtypemodule.sgml.sgml:Long_Description ##### -->
<para>
</para>
- plugin_ref:
- plugin_unref:
- complete_type_info:
- complete_interface_info:
<!-- ##### FUNCTION g_signal_connect_closure ##### -->
<para>
@@ -44,60 +41,59 @@
@after:
@Returns:
-<!-- ##### ENUM GSignalType ##### -->
+<!-- ##### SECTION ./tmpl/gtypemodule.sgml.sgml:Title ##### -->
+gtypemodule.sgml
+
+
+<!-- ##### USER_FUNCTION GTypePluginUnRef ##### -->
<para>
</para>
- G_SIGNAL_RUN_FIRST:
- G_SIGNAL_RUN_LAST:
- G_SIGNAL_RUN_CLEANUP:
- G_SIGNAL_NO_RECURSE:
- G_SIGNAL_ACTION:
- G_SIGNAL_NO_HOOKS:
+ plugin:
-<!-- ##### USER_FUNCTION GTypePluginFillTypeInfo ##### -->
+<!-- ##### FUNCTION g_signal_handlers_destroy ##### -->
<para>
</para>
- plugin:
- g_type:
- info:
- value_table:
+ instance:
-<!-- ##### SECTION ./tmpl/gtypemodule.sgml.sgml:See_Also ##### -->
+<!-- ##### FUNCTION g_type_is_dynamic ##### -->
<para>
</para>
+ type:
+ flags:
+ Returns:
-<!-- ##### USER_FUNCTION GTypePluginRef ##### -->
+<!-- ##### USER_FUNCTION GTypePluginFillTypeInfo ##### -->
<para>
</para>
@plugin:
+ g_type:
+ info:
+ value_table:
-<!-- ##### FUNCTION g_signal_handlers_destroy ##### -->
+<!-- ##### FUNCTION g_signals_destroy ##### -->
<para>
</para>
- instance:
+ itype:
-<!-- ##### FUNCTION g_type_is_dynamic ##### -->
+<!-- ##### STRUCT GTypePluginVTable ##### -->
<para>
</para>
-
- type:
- flags:
- Returns:
-
-<!-- ##### SECTION ./tmpl/gtypemodule.sgml.sgml:Title ##### -->
-gtypemodule.sgml
+ plugin_ref:
+ plugin_unref:
+ complete_type_info:
+ complete_interface_info:
<!-- ##### USER_FUNCTION GTypePluginFillInterfaceInfo ##### -->
<para>
@@ -108,4 +104,8 @@
@interface_type:
@instance_type:
@info:
+
+<!-- ##### SECTION ./tmpl/gtypemodule.sgml.sgml:Short_Description ##### -->
+
+
Index: docs/reference/gobject/tmpl/signals.sgml
===================================================================
RCS file: /cvs/gnome/glib/docs/reference/gobject/tmpl/signals.sgml,v
retrieving revision 1.6
diff -u -r1.6 signals.sgml
--- docs/reference/gobject/tmpl/signals.sgml 2000/11/21 05:57:14 1.6
+++ docs/reference/gobject/tmpl/signals.sgml 2000/12/07 19:28:27
@@ -76,9 +76,9 @@
to callbacks during a signal emission.
</para>
- signal_id: The signal id of the signal invoking the callback
- detail: The detail passed on for this emission
- run_type: The stage the signal emission is currently in, this
+ signal_id: The signal id of the signal invoking the callback
+ detail: The detail passed on for this emission
+ run_type: The stage the signal emission is currently in, this
field will contain one of @G_SIGNAL_RUN_FIRST,
@G_SIGNAL_RUN_LAST or @G_SIGNAL_RUN_CLEANUP.
@@ -92,11 +92,11 @@
value returned by the last callback.
</para>
- ihint: Signal invokation hint, see @GSignalInvocationHint
- return_accu: Accumulator to collect callback return values in, this
+ ihint: Signal invokation hint, see @GSignalInvocationHint
+ return_accu: Accumulator to collect callback return values in, this
is the return value of the current signal emission
- return_value: The return value of the most recent callback function
- Returns: The accumulator function returns whether the signal emission
+ return_value: The return value of the most recent callback function
+ Returns: The accumulator function returns whether the signal emission
should be aborted. Returning @FALSE means to abort the
current emission and @TRUE is returned for continuation.
@@ -153,14 +153,14 @@
filled in by the g_signal_query() function.
</para>
- signal_id: The signal id of the signal being querried, or 0 if the
+ signal_id: The signal id of the signal being querried, or 0 if the
signal to be querried was unknown
- signal_name: The signal name
- itype: The interface/instance type that this signal can be emitted for
- signal_flags: The signal flags as passed in to @g_signal_new()
- return_type: The return type for user callbacks
- n_params: The number of parameters that user callbacks take
- param_types: The individual parameter types for user callbacks, note that the
+ signal_name: The signal name
+ itype: The interface/instance type that this signal can be emitted for
+ signal_flags: The signal flags as passed in to @g_signal_new()
+ return_type: The return type for user callbacks
+ n_params: The number of parameters that user callbacks take
+ param_types: The individual parameter types for user callbacks, note that the
effective callback signature is:
<msgtext><programlisting>
@return_type callback (@gpointer data1,
@@ -225,8 +225,8 @@
be considered constant and have to be left untouched.
</para>
- signal_id: The signal id of the signal to query information for
- query: A user provided structure that is filled in with constant
+ signal_id: The signal id of the signal to query information for
+ query: A user provided structure that is filled in with constant
values upon success.
@@ -237,9 +237,9 @@
g_signal_query().
</para>
- itype: Instance or interface type
- n_ids: Location to store the number of signal ids for @itype
- Returns: Newly allocated array of signal ids
+ itype: Instance or interface type
+ n_ids: Location to store the number of signal ids for @itype
+ Returns: Newly allocated array of signal ids
<!-- ##### FUNCTION g_signal_connect_closure_by_id ##### -->
@@ -268,8 +268,8 @@
@instance.
</para>
- instance: The instance to block the signal handler of
- handler_id: Handler id of the handler to be blocked
+ instance: The instance to block the signal handler of
+ handler_id: Handler id of the handler to be blocked
<!-- ##### FUNCTION g_signal_handler_unblock ##### -->
@@ -290,8 +290,8 @@
signal of @instance and is currently blocked.
</para>
- instance: The instance to unblock the signal handler of
- handler_id: Handler id of the handler to be unblocked
+ instance: The instance to unblock the signal handler of
+ handler_id: Handler id of the handler to be unblocked
<!-- ##### FUNCTION g_signal_handler_disconnect ##### -->
@@ -305,8 +305,8 @@
@instance.
</para>
- instance: The instance to remove the signal handler from
- handler_id: Handler id of the handler to be disconnected
+ instance: The instance to remove the signal handler from
+ handler_id: Handler id of the handler to be disconnected
<!-- ##### FUNCTION g_signal_handler_find ##### -->
@@ -318,15 +318,15 @@
If no handler was found, 0 is returned.
</para>
- instance: The instance owning the signal handler to be found
- mask: Mask indicating which of @signal_id, @detail,
+ instance: The instance owning the signal handler to be found
+ mask: Mask indicating which of @signal_id, @detail,
@closure, @func and/or @data the handler has to match
- signal_id: Signal the handler has to be connected to
- detail: Signal detail the handler has to be connected to
- closure: The closure the handler will invoke
- func: The C closure callback of the handler (useless for non-C closures)
- data: The closure data of the handler's closure
- Returns: A valid non-0 signal handler id for a successfull match
+ signal_id: Signal the handler has to be connected to
+ detail: Signal detail the handler has to be connected to
+ closure: The closure the handler will invoke
+ func: The C closure callback of the handler (useless for non-C closures)
+ data: The closure data of the handler's closure
+ Returns: A valid non-0 signal handler id for a successfull match
<!-- ##### FUNCTION g_signal_handlers_block_matched ##### -->
@@ -340,15 +340,15 @@
otherwise.
</para>
- instance: The instance to block handlers from
- mask: Mask indicating which of @signal_id, @detail,
+ instance: The instance to block handlers from
+ mask: Mask indicating which of @signal_id, @detail,
@closure, @func and/or @data the handlers have to match
- signal_id: Signal the handlers have to be connected to
- detail: Signal detail the handlers have to be connected to
- closure: The closure the handlers will invoke
- func: The C closure callback of the handlers (useless for non-C closures)
- data: The closure data of the handlers' closures
- Returns: The amount of handlers that got blocked
+ signal_id: Signal the handlers have to be connected to
+ detail: Signal detail the handlers have to be connected to
+ closure: The closure the handlers will invoke
+ func: The C closure callback of the handlers (useless for non-C closures)
+ data: The closure data of the handlers' closures
+ Returns: The amount of handlers that got blocked
<!-- ##### FUNCTION g_signal_handlers_unblock_matched ##### -->
@@ -363,15 +363,15 @@
not currently blocked.
</para>
- instance: The instance to unblock handlers from
- mask: Mask indicating which of @signal_id, @detail,
+ instance: The instance to unblock handlers from
+ mask: Mask indicating which of @signal_id, @detail,
@closure, @func and/or @data the handlers have to match
- signal_id: Signal the handlers have to be connected to
- detail: Signal detail the handlers have to be connected to
- closure: The closure the handlers will invoke
- func: The C closure callback of the handlers (useless for non-C closures)
- data: The closure data of the handlers' closures
- Returns: The amount of handlers that got unblocked
+ signal_id: Signal the handlers have to be connected to
+ detail: Signal detail the handlers have to be connected to
+ closure: The closure the handlers will invoke
+ func: The C closure callback of the handlers (useless for non-C closures)
+ data: The closure data of the handlers' closures
+ Returns: The amount of handlers that got unblocked
<!-- ##### FUNCTION g_signal_handlers_disconnect_matched ##### -->
@@ -385,15 +385,15 @@
otherwise.
</para>
- instance: The instance to remove handlers from
- mask: Mask indicating which of @signal_id, @detail,
+ instance: The instance to remove handlers from
+ mask: Mask indicating which of @signal_id, @detail,
@closure, @func and/or @data the handlers have to match
- signal_id: Signal the handlers have to be connected to
- detail: Signal detail the handlers have to be connected to
- closure: The closure the handlers will invoke
- func: The C closure callback of the handlers (useless for non-C closures)
- data: The closure data of the handlers' closures
- Returns: The amount of handlers that got disconnected
+ signal_id: Signal the handlers have to be connected to
+ detail: Signal detail the handlers have to be connected to
+ closure: The closure the handlers will invoke
+ func: The C closure callback of the handlers (useless for non-C closures)
+ data: The closure data of the handlers' closures
+ Returns: The amount of handlers that got disconnected
<!-- ##### FUNCTION g_signal_has_handler_pending ##### -->
@@ -453,12 +453,12 @@
and @detail quark.
</para>
- detailed_signal: A string of the form "signal-name::detail"
- itype: The interface/instance type taht introduced "signal-name"
- signal_id_p: Location to store the signal id
- detail_p: Location to stroe the detail quark
- force_detail_quark: %TRUE forces creation of a GQuark for the detail
- Returns: Whether the signal name could successfully be parsed and
+ detailed_signal: A string of the form "signal-name::detail"
+ itype: The interface/instance type taht introduced "signal-name"
+ signal_id_p: Location to store the signal id
+ detail_p: Location to stroe the detail quark
+ force_detail_quark: %TRUE forces creation of a GQuark for the detail
+ Returns: Whether the signal name could successfully be parsed and
@signal_id_p and @detail_p contain valid return values.
--
Mathieu Lacage <mathieu eazel com>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]