mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-01 15:03:39 +02:00
introspection: use (nullable) or (optional) instead of (allow-none)
If we have an input parameter (or return value) we need to use (nullable). However, if it is an (inout) or (out) parameter, (optional) is sufficient. It looks like (nullable) could be used for everything according to the Annotation documentation, but (optional) is more specific.
This commit is contained in:
@@ -1145,7 +1145,7 @@ g_application_set_property (GObject *object,
|
||||
/**
|
||||
* g_application_set_action_group:
|
||||
* @application: a #GApplication
|
||||
* @action_group: (allow-none): a #GActionGroup, or %NULL
|
||||
* @action_group: (nullable): a #GActionGroup, or %NULL
|
||||
*
|
||||
* This used to be how actions were associated with a #GApplication.
|
||||
* Now there is #GActionMap for that.
|
||||
@@ -1606,7 +1606,7 @@ g_application_id_is_valid (const gchar *application_id)
|
||||
/* Public Constructor {{{1 */
|
||||
/**
|
||||
* g_application_new:
|
||||
* @application_id: (allow-none): the application id
|
||||
* @application_id: (nullable): the application id
|
||||
* @flags: the application flags
|
||||
*
|
||||
* Creates a new #GApplication instance.
|
||||
@@ -1653,7 +1653,7 @@ g_application_get_application_id (GApplication *application)
|
||||
/**
|
||||
* g_application_set_application_id:
|
||||
* @application: a #GApplication
|
||||
* @application_id: (allow-none): the identifier for @application
|
||||
* @application_id: (nullable): the identifier for @application
|
||||
*
|
||||
* Sets the unique identifier for @application.
|
||||
*
|
||||
@@ -1979,7 +1979,7 @@ g_application_get_dbus_object_path (GApplication *application)
|
||||
/**
|
||||
* g_application_register:
|
||||
* @application: a #GApplication
|
||||
* @cancellable: (allow-none): a #GCancellable, or %NULL
|
||||
* @cancellable: (nullable): a #GCancellable, or %NULL
|
||||
* @error: a pointer to a NULL #GError, or %NULL
|
||||
*
|
||||
* Attempts registration of the application.
|
||||
@@ -2198,7 +2198,7 @@ g_application_open (GApplication *application,
|
||||
* g_application_run:
|
||||
* @application: a #GApplication
|
||||
* @argc: the argc from main() (or 0 if @argv is %NULL)
|
||||
* @argv: (array length=argc) (allow-none): the argv from main(), or %NULL
|
||||
* @argv: (array length=argc) (nullable): the argv from main(), or %NULL
|
||||
*
|
||||
* Runs the application.
|
||||
*
|
||||
@@ -2577,7 +2577,7 @@ g_application_get_default (void)
|
||||
|
||||
/**
|
||||
* g_application_set_default:
|
||||
* @application: (allow-none): the application to set as default, or %NULL
|
||||
* @application: (nullable): the application to set as default, or %NULL
|
||||
*
|
||||
* Sets or unsets the default application for the process, as returned
|
||||
* by g_application_get_default().
|
||||
@@ -2705,7 +2705,7 @@ g_application_get_is_busy (GApplication *application)
|
||||
/**
|
||||
* g_application_send_notification:
|
||||
* @application: a #GApplication
|
||||
* @id: (allow-none): id of the notification, or %NULL
|
||||
* @id: (nullable): id of the notification, or %NULL
|
||||
* @notification: the #GNotification to send
|
||||
*
|
||||
* Sends a notification on behalf of @application to the desktop shell.
|
||||
|
Reference in New Issue
Block a user