mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-08 09:40:10 +00:00
Use the appropriate annotations for callback closures
The unary (closure) annotation is for function pointer types; function arguments that represent the user data to be passed to the callback are annotated on the callback argument itself, with (closure arg-name).
This commit is contained in:
parent
54d0bcab71
commit
fa42081556
@ -515,8 +515,8 @@ gdk_clipboard_get_content (GdkClipboard *clipboard)
|
||||
* @clipboard: a `GdkClipboard`
|
||||
* @io_priority: the I/O priority of the request
|
||||
* @cancellable: (nullable): optional `GCancellable` object
|
||||
* @callback: (scope async): callback to call when the request is satisfied
|
||||
* @user_data: (closure): the data to pass to callback function
|
||||
* @callback: (scope async) (closure user_data): callback to call when the request is satisfied
|
||||
* @user_data:: the data to pass to callback function
|
||||
*
|
||||
* Asynchronously instructs the @clipboard to store its contents remotely.
|
||||
*
|
||||
@ -630,8 +630,8 @@ gdk_clipboard_read_internal (GdkClipboard *clipboard,
|
||||
* @mime_types: (array zero-terminated=1): a %NULL-terminated array of mime types to choose from
|
||||
* @io_priority: the I/O priority of the request
|
||||
* @cancellable: (nullable): optional `GCancellable` object
|
||||
* @callback: (scope async): callback to call when the request is satisfied
|
||||
* @user_data: (closure): the data to pass to callback function
|
||||
* @callback: (scope async) (closure user_data): callback to call when the request is satisfied
|
||||
* @user_data: the data to pass to callback function
|
||||
*
|
||||
* Asynchronously requests an input stream to read the @clipboard's
|
||||
* contents from.
|
||||
@ -823,8 +823,8 @@ gdk_clipboard_read_value_internal (GdkClipboard *clipboard,
|
||||
* @type: a `GType` to read
|
||||
* @io_priority: the I/O priority of the request
|
||||
* @cancellable: (nullable): optional `GCancellable` object
|
||||
* @callback: (scope async): callback to call when the request is satisfied
|
||||
* @user_data: (closure): the data to pass to callback function
|
||||
* @callback: (scope async) (closure user_data): callback to call when the request is satisfied
|
||||
* @user_data: the data to pass to callback function
|
||||
*
|
||||
* Asynchronously request the @clipboard contents converted to the given
|
||||
* @type.
|
||||
@ -882,8 +882,8 @@ gdk_clipboard_read_value_finish (GdkClipboard *clipboard,
|
||||
* gdk_clipboard_read_texture_async:
|
||||
* @clipboard: a `GdkClipboard`
|
||||
* @cancellable: (nullable): optional `GCancellable` object, %NULL to ignore.
|
||||
* @callback: (scope async): callback to call when the request is satisfied
|
||||
* @user_data: (closure): the data to pass to callback function
|
||||
* @callback: (scope async) (closure user_data): callback to call when the request is satisfied
|
||||
* @user_data: the data to pass to callback function
|
||||
*
|
||||
* Asynchronously request the @clipboard contents converted to a `GdkPixbuf`.
|
||||
*
|
||||
@ -944,8 +944,8 @@ gdk_clipboard_read_texture_finish (GdkClipboard *clipboard,
|
||||
* gdk_clipboard_read_text_async:
|
||||
* @clipboard: a `GdkClipboard`
|
||||
* @cancellable: (nullable): optional `GCancellable` object
|
||||
* @callback: (scope async): callback to call when the request is satisfied
|
||||
* @user_data: (closure): the data to pass to callback function
|
||||
* @callback: (scope async) (closure user_data): callback to call when the request is satisfied
|
||||
* @user_data: the data to pass to callback function
|
||||
*
|
||||
* Asynchronously request the @clipboard contents converted to a string.
|
||||
*
|
||||
|
@ -533,8 +533,8 @@ deserialize_not_found (GdkContentDeserializer *deserializer)
|
||||
* @type: the GType to deserialize from
|
||||
* @io_priority: the I/O priority of the operation
|
||||
* @cancellable: (nullable): optional `GCancellable` object
|
||||
* @callback: (scope async): callback to call when the operation is done
|
||||
* @user_data: (closure): data to pass to the callback function
|
||||
* @callback: (scope async) (closure user_data): callback to call when the operation is done
|
||||
* @user_data: data to pass to the callback function
|
||||
*
|
||||
* Read content from the given input stream and deserialize it, asynchronously.
|
||||
*
|
||||
|
@ -273,8 +273,8 @@ gdk_content_provider_content_changed (GdkContentProvider *provider)
|
||||
* @stream: the `GOutputStream` to write to
|
||||
* @io_priority: I/O priority of the request.
|
||||
* @cancellable: (nullable): optional `GCancellable` object, %NULL to ignore.
|
||||
* @callback: (scope async): callback to call when the request is satisfied
|
||||
* @user_data: (closure): the data to pass to callback function
|
||||
* @callback: (scope async) (closure user_data): callback to call when the request is satisfied
|
||||
* @user_data: the data to pass to callback function
|
||||
*
|
||||
* Asynchronously writes the contents of @provider to @stream in the given
|
||||
* @mime_type.
|
||||
|
@ -539,8 +539,8 @@ serialize_not_found (GdkContentSerializer *serializer)
|
||||
* @value: the content to serialize
|
||||
* @io_priority: the I/O priority of the operation
|
||||
* @cancellable: (nullable): optional `GCancellable` object
|
||||
* @callback: (scope async): callback to call when the operation is done
|
||||
* @user_data: (closure): data to pass to the callback function
|
||||
* @callback: (scope async) (closure): callback to call when the operation is done
|
||||
* @user_data: data to pass to the callback function
|
||||
*
|
||||
* Serialize content and write it to the given output stream, asynchronously.
|
||||
*
|
||||
|
@ -651,9 +651,9 @@ gdk_drop_read_internal (GdkDrop *self,
|
||||
* pointer to an array of mime types
|
||||
* @io_priority: the I/O priority for the read operation
|
||||
* @cancellable: (nullable): optional `GCancellable` object
|
||||
* @callback: (scope async): a `GAsyncReadyCallback` to call when
|
||||
* @callback: (scope async) (closure user_data): a `GAsyncReadyCallback` to call when
|
||||
* the request is satisfied
|
||||
* @user_data: (closure): the data to pass to @callback
|
||||
* @user_data: the data to pass to @callback
|
||||
*
|
||||
* Asynchronously read the dropped data from a `GdkDrop`
|
||||
* in a format that complies with one of the mime types.
|
||||
@ -843,8 +843,8 @@ gdk_drop_read_value_internal (GdkDrop *self,
|
||||
* @type: a `GType` to read
|
||||
* @io_priority: the I/O priority of the request.
|
||||
* @cancellable: (nullable): optional `GCancellable` object, %NULL to ignore.
|
||||
* @callback: (scope async): callback to call when the request is satisfied
|
||||
* @user_data: (closure): the data to pass to callback function
|
||||
* @callback: (scope async) (closure user_data): callback to call when the request is satisfied
|
||||
* @user_data: the data to pass to callback function
|
||||
*
|
||||
* Asynchronously request the drag operation's contents converted
|
||||
* to the given @type.
|
||||
|
@ -2575,8 +2575,8 @@ export_handle_done (GObject *source,
|
||||
/**
|
||||
* gdk_wayland_toplevel_export_handle:
|
||||
* @toplevel: (type GdkWaylandToplevel): the `GdkToplevel` to obtain a handle for
|
||||
* @callback: callback to call with the handle
|
||||
* @user_data: (closure): user data for @callback
|
||||
* @callback: (scope notified) (closure user_data) (destroy destroy_func): callback to call with the handle
|
||||
* @user_data: user data for @callback
|
||||
* @destroy_func: destroy notify for @user_data
|
||||
*
|
||||
* Asynchronously obtains a handle for a surface that can be passed
|
||||
|
Loading…
Reference in New Issue
Block a user