X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=hacks%2Fxlockmore.c;h=00994ac878d93763e22f2a28f69e00e473afda34;hb=aa75c7476aeaa84cf3abc192b376a8b03c325213;hp=d5b71f9bb4f956b595cd1daf50b3a6d324117bd4;hpb=6afd6db0ae9396cd7ff897ade597cd5483f49b0e;p=xscreensaver diff --git a/hacks/xlockmore.c b/hacks/xlockmore.c index d5b71f9b..00994ac8 100644 --- a/hacks/xlockmore.c +++ b/hacks/xlockmore.c @@ -19,9 +19,9 @@ #include "xlockmoreI.h" #include "screenhack.h" -#ifndef HAVE_COCOA +#ifndef HAVE_JWXYZ # include -#endif /* !HAVE_COCOA */ +#endif /* !HAVE_JWXYZ */ #define countof(x) (sizeof((x))/sizeof(*(x))) @@ -157,7 +157,7 @@ xlockmore_setup (struct xscreensaver_function_table *xsft, void *arg) /* Put on the PROGCLASS.background/foreground resources. */ s = (char *) malloc(50); *s = 0; -# ifndef HAVE_COCOA +# ifndef HAVE_JWXYZ strcpy (s, progclass); # endif strcat (s, ".background: black"); @@ -165,7 +165,7 @@ xlockmore_setup (struct xscreensaver_function_table *xsft, void *arg) s = (char *) malloc(50); *s = 0; -# ifndef HAVE_COCOA +# ifndef HAVE_JWXYZ strcpy (s, progclass); # endif strcat (s, ".foreground: white"); @@ -292,12 +292,12 @@ xlockmore_init (Display *dpy, Window window, mi->window = window; XGetWindowAttributes (dpy, window, &mi->xgwa); -#ifdef HAVE_COCOA +#ifdef HAVE_JWXYZ # if 0 - /* In Cocoa-based xscreensaver, all hacks run in the same address space, - so each one needs to get its own screen number. Believe what jwxyz - says about screen counts and numbers. + /* In Cocoa and Android-based xscreensaver, all hacks run in the + same address space, so each one needs to get its own screen + number. Believe what jwxyz says about screen counts and numbers. */ mi->num_screens = ScreenCount (dpy); mi->screen_number = XScreenNumberOfScreen (mi->xgwa.screen); @@ -316,7 +316,7 @@ xlockmore_init (Display *dpy, Window window, # endif root_p = True; -#else /* !HAVE_COCOA -- real Xlib */ +#else /* real Xlib */ /* In Xlib-based xscreensaver, each hack runs in its own address space, so each one only needs to be aware of one screen. @@ -337,7 +337,7 @@ xlockmore_init (Display *dpy, Window window, /* Everybody gets motion events, just in case. */ XSelectInput (dpy, window, (mi->xgwa.your_event_mask | PointerMotionMask)); -#endif /* !HAVE_COCOA */ +#endif /* !HAVE_JWXYZ */ color.flags = DoRed|DoGreen|DoBlue; color.red = color.green = color.blue = 0; @@ -351,7 +351,6 @@ xlockmore_init (Display *dpy, Window window, if (mono_p) { - static unsigned long pixels[2]; static XColor colors[2]; MONO: mi->npixels = 2; @@ -361,8 +360,6 @@ xlockmore_init (Display *dpy, Window window, if (!mi->colors) mi->colors = (XColor *) calloc (mi->npixels, sizeof (*mi->colors)); - pixels[0] = mi->black; - pixels[1] = mi->white; colors[0].flags = DoRed|DoGreen|DoBlue; colors[1].flags = DoRed|DoGreen|DoBlue; colors[0].red = colors[0].green = colors[0].blue = 0;