From: Mathis Raguin Date: Tue, 28 May 2019 20:08:25 +0000 (+0200) Subject: fix: move all output at once as they are enabled X-Git-Tag: 1.10~19 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=3c4441a95fbd2d91c1e98973df69acab08cefdbc;p=deb_pkgs%2Fautorandr.git fix: move all output at once as they are enabled Signed-off-by: Mathis Raguin --- diff --git a/autorandr.py b/autorandr.py index 433cdc6..1c4377d 100755 --- a/autorandr.py +++ b/autorandr.py @@ -818,10 +818,9 @@ def apply_configuration(new_configuration, current_configuration, dry_run=False) # Fix all outputs if no 0x0 output has been found as xrandr will shift them if require_xrandr_fix: - for index in range(0, len(enable_outputs), 2): - argv = base_argv + list(chain.from_iterable(enable_outputs[index:index + 2])) - if call_and_retry(argv, dry_run=dry_run) != 0: - raise AutorandrException("Command failed: %s" % " ".join(argv)) + argv = base_argv + list(chain.from_iterable(enable_outputs)) + if call_and_retry(argv, dry_run=dry_run) != 0: + raise AutorandrException("Command failed: %s" % " ".join(argv)) def is_equal_configuration(source_configuration, target_configuration):