diff options
author | PMR <pmr@pmr-lander> | 2018-06-11 14:05:52 +0000 |
---|---|---|
committer | PMR <pmr@pmr-lander> | 2018-06-11 14:05:52 +0000 |
commit | 79b590a03bcfdb5c4db7b1003cfc8f0de18f57c0 (patch) | |
tree | 5e095ed612f1c12a9c97348c7ca2da2ecc53228b | |
parent | 680e31866f3533510ec5f4293471c7804f3ce2ae (diff) | |
parent | a6e9392068db90292fd616bc3c0024bfe6c8094d (diff) |
Merge #347754 from ~kissiel/plainbox-provider-checkbox:fix-1627581-xrandr-cycle
-rwxr-xr-x | bin/xrandr_cycle | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/bin/xrandr_cycle b/bin/xrandr_cycle index b9f615b..34f953c 100755 --- a/bin/xrandr_cycle +++ b/bin/xrandr_cycle @@ -87,6 +87,13 @@ for adapter, mode in modes: highest_modes = [] for adapter, params in top_res_per_aspect.items(): for aspect, width in params.items(): + # xrandr can list modes that are unsupported, unity-control-center + # defines minimum width and height, below which the resolution + # is not listed as a choice in display settings panel in UCC + # see should_show_resolution function in cc-display-panel.c + # from lp:unity-control-center + if width < 675 or width / aspect < 530: + continue mode = '{}x{}'.format(width, width/aspect) highest_modes.append((adapter, mode)) |