summaryrefslogtreecommitdiff
path: root/miext
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2010-06-07 13:39:11 -0700
committerKeith Packard <keithp@keithp.com>2010-06-10 19:15:28 -0700
commita8ec9eca850f2a7ad4c5cf31c1c011c120688496 (patch)
treeb5bc031a9016f0d7854d25554fe0708dc9d19587 /miext
parent07a093add0b7e40c4d9b9b59273e3ff9e14a88a7 (diff)
Fix a couple more possible errors with input-only windows
Using type == DRAWABLE_WINDOW to differentiate between pixmaps and windows isn't sufficient as input-only windows will end up in the pixmap case. This patch changes a few more code paths to use WindowDrawable instead. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Jamey Sharp <jamey@minilop.net>
Diffstat (limited to 'miext')
-rw-r--r--miext/damage/damage.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/miext/damage/damage.c b/miext/damage/damage.c
index 7c2f8a048..1cf0513d0 100644
--- a/miext/damage/damage.c
+++ b/miext/damage/damage.c
@@ -84,7 +84,7 @@ getDrawableDamageRef (DrawablePtr pDrawable)
{
PixmapPtr pPixmap;
- if (pDrawable->type == DRAWABLE_WINDOW)
+ if (WindowDrawable(pDrawable->type))
{
ScreenPtr pScreen = pDrawable->pScreen;
@@ -300,7 +300,7 @@ damageRegionAppend (DrawablePtr pDrawable, RegionPtr pRegion, Bool clip,
* Need to move everyone to screen coordinates
* XXX what about off-screen pixmaps with non-zero x/y?
*/
- if (pDamage->pDrawable->type != DRAWABLE_WINDOW)
+ if (!WindowDrawable(pDamage->pDrawable->type))
{
draw_x += ((PixmapPtr) pDamage->pDrawable)->screen_x;
draw_y += ((PixmapPtr) pDamage->pDrawable)->screen_y;