Skip to content

display: Fix the resolution going to be tested

Jian-Hong Pan requested to merge starnight/gnome-control-center:I903 into master

Gnome-control-center checks the display modes by cc_display_config_is_scaled_mode_valid() ... cc_display_config_dbus_is_scaled_mode_valid() to exclude unusable low resolutions.

However, it is the current using resolution that going to be tested by is_scaled_mode_allowed() in is_scale_allowed_by_active_monitors(), if it is global scaled required or configured as cloning mode originally. Therefor, it will check current using resolution again and again, instead of the enumerated one. This leads gnome-control-center building wrong resolution list on the panel.

This patch replaces the current mode with the enumerated mode to have the correct resolution to be tested by is_scaled_mode_allowed().

Fixes #903 (closed)

Merge request reports