From http://www.jwz.org/xscreensaver/xscreensaver-5.18.tar.gz
[xscreensaver] / hacks / distort.c
index 4e4c809e63cf4a9fd23f05f673c5b23c93e27f33..92cc0de32b7e801369ff93b5916e32cb084fcc11 100644 (file)
@@ -781,6 +781,12 @@ static void
 distort_reshape (Display *dpy, Window window, void *closure, 
                  unsigned int w, unsigned int h)
 {
+  struct state *st = (struct state *) closure;
+  XGetWindowAttributes (st->dpy, st->window, &st->xgwa);
+  /* XClearWindow (dpy, window); */
+  /* Why doesn't this work? */
+  XPutImage (st->dpy, st->window, st->gc, st->orig_map,
+             0, 0, st->orig_map->width, st->orig_map->height, 0, 0);
 }
 
 static Bool