• Zebediah Figura's avatar
    winex11: Resize the screen when changing CRTC modes. · 70d842b1
    Zebediah Figura authored
    Based on a patch by Gabriel Corona.
    
    According to the RandR spec for RRSetCrtcConfig:
    
    "The entire area of the CRTC must fit within the screen size, else a Match
    error results. As an example, rotating the screen so that a single CRTC fills
    the entire screen before and after may necessitate disabling the CRTC,
    resizing the screen, then re-enabling the CRTC at the new configuration to
    avoid an invalid intermediate configuration."
    
    This patch involves resizing the screen also when shrinking a CRTC, not just
    when expanding it past the current screen size. This is partially because we
    have no way to reliably determine the current display width (DisplayWidth() is
    never updated past opening the connection, and RandR exposes no way to
    retrieve the screen dimensions), and partially because it's probably what the
    user wants anyway (e.g. it's what the `xrandr` configuration app does when the
    screen size is not expliticly specified).
    
    This patch fixes TestBot failures on the Debian machines for ddraw, d3d8, and
    d3d9 device tests.
    
    Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=33290Signed-off-by: 's avatarZebediah Figura <z.figura12@gmail.com>
    Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
    70d842b1
xrandr.c 17.9 KB