mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-09 19:06:15 +01:00
Revert "Rename user data parameters to user_data"
This reverts commit da7a31a052
. The renaming of parameters implicitly introduced "closure" annotations in the documentation which are wrong on callbacks.
This commit is contained in:
parent
ec3b1bfc45
commit
19a02d7d14
@ -300,7 +300,7 @@ typedef void (*GFileProgressCallback) (goffset current_num_bytes,
|
||||
* GFileReadMoreCallback:
|
||||
* @file_contents: the data as currently read.
|
||||
* @file_size: the size of the data currently read.
|
||||
* @user_data: data passed to the callback.
|
||||
* @callback_data: (closure): data passed to the callback.
|
||||
*
|
||||
* When loading the partial contents of a file with g_file_load_partial_contents_async(),
|
||||
* it may become necessary to determine if any more data from the file should be loaded.
|
||||
@ -311,7 +311,7 @@ typedef void (*GFileProgressCallback) (goffset current_num_bytes,
|
||||
**/
|
||||
typedef gboolean (* GFileReadMoreCallback) (const char *file_contents,
|
||||
goffset file_size,
|
||||
gpointer user_data);
|
||||
gpointer callback_data);
|
||||
|
||||
/**
|
||||
* GFileMeasureProgressCallback:
|
||||
|
@ -584,7 +584,7 @@ g_hook_list_invoke_check (GHookList *hook_list,
|
||||
/**
|
||||
* GHookCheckMarshaller:
|
||||
* @hook: a #GHook
|
||||
* @user_data: user data
|
||||
* @marshal_data: user data
|
||||
*
|
||||
* Defines the type of function used by g_hook_list_marshal_check().
|
||||
*
|
||||
@ -636,7 +636,7 @@ g_hook_list_marshal_check (GHookList *hook_list,
|
||||
/**
|
||||
* GHookMarshaller:
|
||||
* @hook: a #GHook
|
||||
* @user_data: user data
|
||||
* @marshal_data: user data
|
||||
*
|
||||
* Defines the type of function used by g_hook_list_marshal().
|
||||
*/
|
||||
@ -793,7 +793,7 @@ g_hook_get (GHookList *hook_list,
|
||||
/**
|
||||
* GHookFindFunc:
|
||||
* @hook: a #GHook
|
||||
* @user_data: user data passed to g_hook_find_func()
|
||||
* @data: user data passed to g_hook_find_func()
|
||||
*
|
||||
* Defines the type of the function passed to g_hook_find().
|
||||
*
|
||||
|
@ -43,11 +43,11 @@ typedef struct _GHookList GHookList;
|
||||
typedef gint (*GHookCompareFunc) (GHook *new_hook,
|
||||
GHook *sibling);
|
||||
typedef gboolean (*GHookFindFunc) (GHook *hook,
|
||||
gpointer user_data);
|
||||
gpointer data);
|
||||
typedef void (*GHookMarshaller) (GHook *hook,
|
||||
gpointer user_data);
|
||||
gpointer marshal_data);
|
||||
typedef gboolean (*GHookCheckMarshaller) (GHook *hook,
|
||||
gpointer user_data);
|
||||
gpointer marshal_data);
|
||||
typedef void (*GHookFunc) (gpointer data);
|
||||
typedef gboolean (*GHookCheckFunc) (gpointer data);
|
||||
typedef void (*GHookFinalizeFunc) (GHookList *hook_list,
|
||||
|
@ -679,7 +679,7 @@ g_io_add_watch_full (GIOChannel *channel,
|
||||
* GIOFunc:
|
||||
* @source: the #GIOChannel event source
|
||||
* @condition: the condition which has been satisfied
|
||||
* @user_data: user data set in g_io_add_watch() or g_io_add_watch_full()
|
||||
* @data: user data set in g_io_add_watch() or g_io_add_watch_full()
|
||||
*
|
||||
* Specifies the type of function passed to g_io_add_watch() or
|
||||
* g_io_add_watch_full(), which is called when the requested condition
|
||||
|
@ -130,7 +130,7 @@ struct _GIOChannel
|
||||
|
||||
typedef gboolean (*GIOFunc) (GIOChannel *source,
|
||||
GIOCondition condition,
|
||||
gpointer user_data);
|
||||
gpointer data);
|
||||
struct _GIOFuncs
|
||||
{
|
||||
GIOStatus (*io_read) (GIOChannel *channel,
|
||||
|
@ -868,7 +868,7 @@ g_node_depth_traverse_level (GNode *node,
|
||||
/**
|
||||
* GNodeTraverseFunc:
|
||||
* @node: a #GNode.
|
||||
* @user_data: user data passed to g_node_traverse().
|
||||
* @data: user data passed to g_node_traverse().
|
||||
*
|
||||
* Specifies the type of function passed to g_node_traverse(). The
|
||||
* function is called with each of the nodes visited, together with the
|
||||
@ -1245,7 +1245,7 @@ g_node_last_sibling (GNode *node)
|
||||
/**
|
||||
* GNodeForeachFunc:
|
||||
* @node: a #GNode.
|
||||
* @user_data: user data passed to g_node_children_foreach().
|
||||
* @data: user data passed to g_node_children_foreach().
|
||||
*
|
||||
* Specifies the type of function passed to g_node_children_foreach().
|
||||
* The function is called with each child node, together with the user
|
||||
|
@ -58,9 +58,9 @@ typedef enum
|
||||
} GTraverseType;
|
||||
|
||||
typedef gboolean (*GNodeTraverseFunc) (GNode *node,
|
||||
gpointer user_data);
|
||||
gpointer data);
|
||||
typedef void (*GNodeForeachFunc) (GNode *node,
|
||||
gpointer user_data);
|
||||
gpointer data);
|
||||
|
||||
/* N-way tree implementation
|
||||
*/
|
||||
|
@ -85,7 +85,7 @@
|
||||
* GSequenceIterCompareFunc:
|
||||
* @a: a #GSequenceIter
|
||||
* @b: a #GSequenceIter
|
||||
* @user_data: user data
|
||||
* @data: user data
|
||||
*
|
||||
* A #GSequenceIterCompareFunc is a function used to compare iterators.
|
||||
* It must return zero if the iterators compare equal, a negative value
|
||||
|
@ -34,7 +34,7 @@ typedef struct _GSequenceNode GSequenceIter;
|
||||
|
||||
typedef gint (* GSequenceIterCompareFunc) (GSequenceIter *a,
|
||||
GSequenceIter *b,
|
||||
gpointer user_data);
|
||||
gpointer data);
|
||||
|
||||
|
||||
/* GSequence */
|
||||
|
@ -474,7 +474,7 @@
|
||||
|
||||
/**
|
||||
* GThreadFunc:
|
||||
* @user_data: data passed to the thread
|
||||
* @data: data passed to the thread
|
||||
*
|
||||
* Specifies the type of the @func functions passed to g_thread_new()
|
||||
* or g_thread_try_new().
|
||||
|
@ -46,7 +46,7 @@ typedef enum
|
||||
G_THREAD_ERROR_AGAIN /* Resource temporarily unavailable */
|
||||
} GThreadError;
|
||||
|
||||
typedef gpointer (*GThreadFunc) (gpointer user_data);
|
||||
typedef gpointer (*GThreadFunc) (gpointer data);
|
||||
|
||||
typedef struct _GThread GThread;
|
||||
|
||||
|
@ -1197,7 +1197,7 @@ g_tree_foreach_node (GTree *tree,
|
||||
* GTraverseFunc:
|
||||
* @key: a key of a #GTree node
|
||||
* @value: the value corresponding to the key
|
||||
* @user_data: user data passed to g_tree_traverse()
|
||||
* @data: user data passed to g_tree_traverse()
|
||||
*
|
||||
* Specifies the type of function passed to g_tree_traverse(). It is
|
||||
* passed the key and value of each node, together with the @user_data
|
||||
|
@ -50,7 +50,7 @@ typedef struct _GTreeNode GTreeNode;
|
||||
|
||||
typedef gboolean (*GTraverseFunc) (gpointer key,
|
||||
gpointer value,
|
||||
gpointer user_data);
|
||||
gpointer data);
|
||||
|
||||
/**
|
||||
* GTraverseNodeFunc:
|
||||
|
@ -148,7 +148,7 @@ typedef void (*GHFunc) (gpointer key,
|
||||
/**
|
||||
* GCopyFunc:
|
||||
* @src: (not nullable): A pointer to the data which should be copied
|
||||
* @user_data: Additional data
|
||||
* @data: Additional data
|
||||
*
|
||||
* A function of this signature is used to copy the node data
|
||||
* when doing a deep-copy of a tree.
|
||||
@ -158,7 +158,7 @@ typedef void (*GHFunc) (gpointer key,
|
||||
* Since: 2.4
|
||||
*/
|
||||
typedef gpointer (*GCopyFunc) (gconstpointer src,
|
||||
gpointer user_data);
|
||||
gpointer data);
|
||||
/**
|
||||
* GFreeFunc:
|
||||
* @data: a data pointer
|
||||
|
@ -112,7 +112,7 @@ typedef void (*GClosureNotify) (gpointer data,
|
||||
* callback of @closure
|
||||
* @invocation_hint: (nullable): the invocation hint given as the
|
||||
* last argument to g_closure_invoke()
|
||||
* @user_data: (nullable): additional data specified when
|
||||
* @marshal_data: (nullable): additional data specified when
|
||||
* registering the marshaller, see g_closure_set_marshal() and
|
||||
* g_closure_set_meta_marshal()
|
||||
*
|
||||
@ -123,7 +123,7 @@ typedef void (*GClosureMarshal) (GClosure *closure,
|
||||
guint n_param_values,
|
||||
const GValue *param_values,
|
||||
gpointer invocation_hint,
|
||||
gpointer user_data);
|
||||
gpointer marshal_data);
|
||||
|
||||
/**
|
||||
* GVaClosureMarshal:
|
||||
|
@ -60,7 +60,7 @@ typedef GVaClosureMarshal GSignalCVaMarshaller;
|
||||
* the instance on which the signal was emitted.
|
||||
* @param_values: (array length=n_param_values): the instance on which
|
||||
* the signal was emitted, followed by the parameters of the emission.
|
||||
* @user_data: user data associated with the hook.
|
||||
* @data: user data associated with the hook.
|
||||
*
|
||||
* A simple function pointer to get invoked when the signal is emitted.
|
||||
*
|
||||
@ -75,14 +75,14 @@ typedef GVaClosureMarshal GSignalCVaMarshaller;
|
||||
typedef gboolean (*GSignalEmissionHook) (GSignalInvocationHint *ihint,
|
||||
guint n_param_values,
|
||||
const GValue *param_values,
|
||||
gpointer user_data);
|
||||
gpointer data);
|
||||
/**
|
||||
* GSignalAccumulator:
|
||||
* @ihint: Signal invocation hint, see #GSignalInvocationHint.
|
||||
* @return_accu: Accumulator to collect callback return values in, this
|
||||
* is the return value of the current signal emission.
|
||||
* @handler_return: A #GValue holding the return value of the signal handler.
|
||||
* @user_data: Callback data that was specified when creating the signal.
|
||||
* @data: Callback data that was specified when creating the signal.
|
||||
*
|
||||
* The signal accumulator is a special callback function that can be used
|
||||
* to collect return values of the various callbacks that are called
|
||||
@ -103,7 +103,7 @@ typedef gboolean (*GSignalEmissionHook) (GSignalInvocationHint *ihint,
|
||||
typedef gboolean (*GSignalAccumulator) (GSignalInvocationHint *ihint,
|
||||
GValue *return_accu,
|
||||
const GValue *handler_return,
|
||||
gpointer user_data);
|
||||
gpointer data);
|
||||
|
||||
|
||||
/* --- run, match and connect types --- */
|
||||
|
Loading…
Reference in New Issue
Block a user