Merge branch 'file-nullable' into 'main'

filelauncher: Make set_file argument nullable

See merge request GNOME/gtk!5357
This commit is contained in:
Matthias Clasen 2022-12-21 03:23:58 +00:00
commit 257ca10eb1

View File

@ -184,7 +184,7 @@ gtk_file_launcher_get_file (GtkFileLauncher *self)
/**
* gtk_file_launcher_set_file:
* @self: a `GtkFileLauncher`
* @file: a `GFile`
* @file: (nullable): a `GFile`
*
* Sets the file that will be opened.
*
@ -195,7 +195,7 @@ gtk_file_launcher_set_file (GtkFileLauncher *self,
GFile *file)
{
g_return_if_fail (GTK_IS_FILE_LAUNCHER (self));
g_return_if_fail (G_IS_FILE (file));
g_return_if_fail (file == NULL || G_IS_FILE (file));
if (!g_set_object (&self->file, file))
return;