summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2009-08-25 16:58:07 -0700
committerKeith Packard <keithp@keithp.com>2009-08-25 18:14:19 -0700
commit1740cda7a37abc7d0a169ab4555b446adaa62211 (patch)
tree8ae7e81cb451e4e64293c82167c24ccd95c95fa4
parent4aab05e3b3231f1ec9795a66a075d17a722634a7 (diff)
Perform rotation redisplay before calling driver block handler (which may flush rendering)
The rotation block handler uses regular driver rendering functions to repaint the screen, if those functions queue commands in the driver, it's important that the driver block handler be invoked after the rotated image is drawn. Signed-off-by: Keith Packard <keithp@keithp.com>
-rw-r--r--hw/xfree86/modes/xf86Rotate.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/hw/xfree86/modes/xf86Rotate.c b/hw/xfree86/modes/xf86Rotate.c
index e808434e0..e0ea274a2 100644
--- a/hw/xfree86/modes/xf86Rotate.c
+++ b/hw/xfree86/modes/xf86Rotate.c
@@ -293,11 +293,12 @@ xf86RotateBlockHandler(int screenNum, pointer blockData,
293 ScreenPtr pScreen = screenInfo.screens[screenNum]; 293 ScreenPtr pScreen = screenInfo.screens[screenNum];
294 ScrnInfoPtr pScrn = xf86Screens[screenNum]; 294 ScrnInfoPtr pScrn = xf86Screens[screenNum];
295 xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); 295 xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn);
296 Bool rotation_active;
296 297
298 rotation_active = xf86RotateRedisplay(pScreen);
297 pScreen->BlockHandler = xf86_config->BlockHandler; 299 pScreen->BlockHandler = xf86_config->BlockHandler;
298 (*pScreen->BlockHandler) (screenNum, blockData, pTimeout, pReadmask); 300 (*pScreen->BlockHandler) (screenNum, blockData, pTimeout, pReadmask);
299 if (xf86RotateRedisplay(pScreen)) 301 if (rotation_active) {
300 {
301 /* Re-wrap if rotation is still happening */ 302 /* Re-wrap if rotation is still happening */
302 xf86_config->BlockHandler = pScreen->BlockHandler; 303 xf86_config->BlockHandler = pScreen->BlockHandler;
303 pScreen->BlockHandler = xf86RotateBlockHandler; 304 pScreen->BlockHandler = xf86RotateBlockHandler;