"Blank Screen Delay" incorrectly shows "1 minute" when a custom value is configured.
On some of my systems, I find the list of available blank screen delay values to be restrictive, and have manually configured a custom value, e.g.
$ gsettings set org.gnome.desktop.session idle-delay 1800
to get 30 minutes.
With the previous UI for setting the blank screen delay, it would display the current value correctly, even though Settings doesn't allow setting that value.
But with the current UI with a drop-down menu, when the number configured doesn't match one of the available options in the drop-down menu, the first option in the menu is shown instead: "1 minute". (This also happens for values which are less than 15 minutes, if they don't match an available option.) When the UI is in this state, there is no way to change the value directly to "1 minute" - you first have to change to a different value, then change back to 1 minute.
The simplest fix would be to set the selected
property on the Adw.ComboRow to GTK_INVALID_LIST_POSITION
when the value fetched from gsettings does not match one of the available options - that will cause the widget to render in an indeterminate state, with nothing selected. From that point, you can open the menu and select any of the valid options. Note that when the widget is in this state, the selected-item
property will be NULL
.