From http://www.jwz.org/xscreensaver/xscreensaver-5.35.tar.gz
[xscreensaver] / hacks / nerverot.c
index d0de73c98dbd4769a496ede4d5a2754dd58530df..081dbcab728d84bcbcd522e475af340d78dbf957 100644 (file)
@@ -799,7 +799,8 @@ static void setupColormap (struct state *st, XWindowAttributes *xgwa)
     colors[0].pixel = get_pixel_resource (st->dpy, xgwa->colormap,
                                           "background", "Background");
     
-    make_color_ramp (st->dpy, xgwa->colormap, h1, s1, v1, h2, s2, v2,
+    make_color_ramp (xgwa->screen, xgwa->visual, xgwa->colormap,
+                     h1, s1, v1, h2, s2, v2,
                     colors + 1, &st->colorCount, False, True, False);
 
     if (st->colorCount < 1)
@@ -1113,7 +1114,7 @@ static void eraseAndDraw (struct state *st)
     for (n = 0; n < st->segCount; n++)
     {
        LineSegment *seg = &st->segsToErase[n];
-#ifdef HAVE_COCOA      /* Don't second-guess Quartz's double-buffering */
+#ifdef HAVE_JWXYZ      /* Don't second-guess Quartz's double-buffering */
        XDrawLine (st->dpy, st->drawable, st->gcs[0], 
                   seg->x1, seg->y1, seg->x2, seg->y2);
 #endif
@@ -1172,7 +1173,7 @@ static void initParams (struct state *st)
     
     st->doubleBuffer = get_boolean_resource (st->dpy, "doubleBuffer", "Boolean");
 
-# ifdef HAVE_COCOA     /* Don't second-guess Quartz's double-buffering */
+# ifdef HAVE_JWXYZ     /* Don't second-guess Quartz's double-buffering */
     st->doubleBuffer = False;
 # endif
 
@@ -1324,6 +1325,9 @@ static const char *nerverot_defaults [] = {
     "*maxRadius:        25",
     "*maxNerveRadius:  0.7",
     "*nervousness:     0.3",
+#ifdef HAVE_MOBILE
+    "*ignoreRotation:   True",
+#endif
     0
 };