From b2bf49eae922bffddc952fcc22e4acbd7d40c5f3 Mon Sep 17 00:00:00 2001 From: Rico Tzschichholz Date: Wed, 2 Jul 2014 13:13:02 +0200 Subject: Update glib annotations from git master --- gir/gio-2.0.c | 43 ++++++++++++++++++++++++++++++------------- gir/glib-2.0.c | 7 ++++--- gir/gobject-2.0.c | 17 +++++++++++++++++ 3 files changed, 51 insertions(+), 16 deletions(-) diff --git a/gir/gio-2.0.c b/gir/gio-2.0.c index 2e5c60b3..f55442e5 100644 --- a/gir/gio-2.0.c +++ b/gir/gio-2.0.c @@ -58,16 +58,23 @@ * GActionEntry: * @name: the name of the action * @activate: the callback to connect to the "activate" signal of the - * action + * action. Since GLib 2.40, this can be %NULL for stateful + * actions, in which case the default handler is used. For + * boolean-stated actions with no parameter, this is a + * toggle. For other state types (and parameter type equal + * to the state type) this will be a function that + * just calls @change_state (which you should provide). * @parameter_type: the type of the parameter that must be passed to the * activate function for this action, given as a single * GVariant type string (or %NULL for no parameter) - * @state: the initial state for this action, given in GVariant text - * format. The state is parsed with no extra type information, - * so type tags must be added to the string if they are - * necessary. + * @state: the initial state for this action, given in + * [GVariant text format][gvariant-text]. The state is parsed + * with no extra type information, so type tags must be added to + * the string if they are necessary. Stateless actions should + * give %NULL here. * @change_state: the callback to connect to the "change-state" signal - * of the action + * of the action. All stateful actions should provide a + * handler here; stateless actions should not. * * This struct defines a single action. It is for use with * g_action_map_add_action_entries(). @@ -4401,6 +4408,9 @@ * credential type is a struct cmsgcred. This corresponds * to %G_CREDENTIALS_TYPE_FREEBSD_CMSGCRED. * + * On NetBSD, the native credential type is a struct unpcbid. + * This corresponds to %G_CREDENTIALS_TYPE_NETBSD_UNPCBID. + * * On OpenBSD, the native credential type is a struct sockpeercred. * This corresponds to %G_CREDENTIALS_TYPE_OPENBSD_SOCKPEERCRED. * @@ -20051,7 +20061,6 @@ * This call does no blocking I/O. * * Returns: %TRUE if @file1 and @file2 are equal. - * %FALSE if either is not a #GFile. */ @@ -27173,6 +27182,16 @@ */ +/** + * g_notification_set_priority: + * @notification: a #GNotification + * @priority: a #GNotificationPriority + * + * Sets the priority of @notification to @priority. See + * #GNotificationPriority for possible values. + */ + + /** * g_notification_set_title: * @notification: a #GNotification @@ -27189,7 +27208,7 @@ * @notification: a #GNotification * @urgent: %TRUE if @notification is urgent * - * Sets or unsets whether @notification is marked as urgent. + * Deprecated in favor of g_notification_set_priority(). * * Since: 2.40 */ @@ -33868,7 +33887,7 @@ * @callback: Callback * @user_data: User data * - * Asynchronous version of g_subprocess_communicate_utf(). Complete + * Asynchronous version of g_subprocess_communicate_utf8(). Complete * invocation with g_subprocess_communicate_utf8_finish(). */ @@ -34266,8 +34285,7 @@ * @argv0: Command line arguments * @...: Continued arguments, %NULL terminated * - * A convenience helper for creating a #GSubprocess given a provided - * varargs list of arguments. + * Creates a #GSubprocess given a provided varargs list of arguments. * * Since: 2.40 * Returns: (transfer full): A new #GSubprocess, or %NULL on error (and @error will be set) @@ -34280,8 +34298,7 @@ * @argv: (array zero-terminated=1) (element-type utf8): Command line arguments * @error: Error * - * A convenience helper for creating a #GSubprocess given a provided - * array of arguments. + * Creates a #GSubprocess given a provided array of arguments. * * Since: 2.40 * Returns: (transfer full): A new #GSubprocess, or %NULL on error (and @error will be set) diff --git a/gir/glib-2.0.c b/gir/glib-2.0.c index 84ee1e0b..507eb68b 100644 --- a/gir/glib-2.0.c +++ b/gir/glib-2.0.c @@ -24969,9 +24969,10 @@ /** * g_shell_parse_argv: * @command_line: command line to parse - * @argcp: (out): return location for number of args - * @argvp: (out) (array length=argcp zero-terminated=1): return location for array of args - * @error: return location for error + * @argcp: (out) (optional): return location for number of args, or %NULL + * @argvp: (out) (optional) (array length=argcp zero-terminated=1): return + * location for array of args, or %NULL + * @error: (optional): return location for error, or %NULL * * Parses a command line into an argument vector, in much the same way * the shell would, but without many of the expansions the shell would diff --git a/gir/gobject-2.0.c b/gir/gobject-2.0.c index b2973238..df07e55a 100644 --- a/gir/gobject-2.0.c +++ b/gir/gobject-2.0.c @@ -5711,6 +5711,23 @@ */ +/** + * g_value_init_from_instance: + * @value: An uninitialized #GValue structure. + * @instance: the instance + * + * Initializes and sets @value from an instantiatable type via the + * value_table's collect_value() function. + * + * Note: The @value will be initialised with the exact type of + * @instance. If you wish to set the @value's type to a different GType + * (such as a parent class GType), you need to manually call + * g_value_init() and g_value_set_instance(). + * + * Since: 2.42 + */ + + /** * g_value_peek_pointer: * @value: An initialized #GValue structure -- cgit v1.2.1