Merge branch 'fallback-bg' into 'main'

background: Fall back to default wallpaper

See merge request GNOME/gnome-shell!722
This commit is contained in:
Florian Müllner 2024-06-23 16:24:06 +00:00
commit 00d5c5d253

View file

@ -607,6 +607,12 @@ class BackgroundSource {
: PICTURE_URI_KEY);
file = Gio.File.new_for_commandline_arg(uri);
// Fall back to default wallpaper if the file doesn't exist
if (!file.query_exists(null)) {
uri = this._settings.get_default_value(PICTURE_URI_KEY).unpack();
file = Gio.File.new_for_commandline_arg(uri);
}
}
}