From http://www.jwz.org/xscreensaver/xscreensaver-5.30.tar.gz
[xscreensaver] / hacks / crystal.c
index 3acd7caee386f3e211f6e9803ffdf16365d66d0e..8b077c88fa29725db65cb11d5c23280f184f4bc3 100644 (file)
@@ -77,7 +77,6 @@ static const char sccsid[] = "@(#)crystal.c   4.12 98/09/10 xlockmore";
                                                 "*fpsSolid:       True \n" \
                                                 "*ignoreRotation: True \n" \
 
-# define crystal_handle_event 0
 # include "xlockmore.h"                /* in xscreensaver distribution */
 #else /* STANDALONE */
 # include "xlock.h"                    /* in xlockmore distribution */
@@ -1286,4 +1285,15 @@ reshape_crystal(ModeInfo * mi, int width, int height)
   init_crystal(mi);
 }
 
+ENTRYPOINT Bool
+crystal_handle_event (ModeInfo *mi, XEvent *event)
+{
+  if (screenhack_event_helper (MI_DISPLAY(mi), MI_WINDOW(mi), event))
+    {
+      reshape_crystal (mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+      return True;
+    }
+  return False;
+}
+
 XSCREENSAVER_MODULE ("Crystal", crystal)