summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2013-09-03 19:05:41 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2013-09-03 19:37:29 +0100
commitd2f19d5a1f4d1c9521fb4801c9fb649d19746150 (patch)
tree583c9d43fc6e5ba1c925720245a1935f390615e3 /src
parent47e718bf321f6fe80dc5f797f433b00bc8de91c7 (diff)
sna: Tidy walking the window tree for updating our pixmaps
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src')
-rw-r--r--src/sna/sna_accel.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index 2205b339..c92d4c65 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -15205,8 +15205,8 @@ sna_visit_set_window_pixmap(WindowPtr window, pointer data)
{
struct sna_visit_set_pixmap_window *visit = data;
- if (fbGetWindowPixmap(window) == visit->old) {
- window->drawable.pScreen->SetWindowPixmap(window, visit->new);
+ if (sna_get_window_pixmap(window) == visit->old) {
+ sna_set_window_pixmap(window, visit->new);
return WT_WALKCHILDREN;
}
@@ -15260,10 +15260,7 @@ sna_set_screen_pixmap(PixmapPtr pixmap)
root = get_root_window(screen);
if (root) {
- struct sna_visit_set_pixmap_window visit;
-
- visit.old = old_front;
- visit.new = pixmap;
+ struct sna_visit_set_pixmap_window visit = { old_front, pixmap };
TraverseTree(root, sna_visit_set_window_pixmap, &visit);
assert(fbGetWindowPixmap(root) == pixmap);
}