Hi there,
I'm using slock to block my laptop screen when it goes to sleep, and
I've noticed 2 small things.
First, although slock hides the mouse when called, it appears over the
slock window when coming back from sleep (it can't be moved, but it's
there). I'm using the /etc/acpi/sleep.sh script to put the laptop to
sleep, if it matters.
And second, when coming back from sleep, a black window isn't the best
option to inform you when the computer is ready for you to type your
password, so I added a line to change the window background to a color
that's a bit more recognizable.
I know it's just a very small and silly patch, but maybe someone finds
it useful :)
Byee
diff -r 38a69d728e64 slock.c
--- a/slock.c Fri Apr 13 11:48:17 2007 +0200
+++ b/slock.c Fri Oct 12 13:37:34 2007 +0200
@@ -80,6 +80,7 @@ main(int argc, char **argv) {
w = XCreateWindow(dpy, root, 0, 0, DisplayWidth(dpy, screen),
DisplayHeight(dpy, screen),
0, DefaultDepth(dpy, screen), CopyFromParent,
DefaultVisual(dpy, screen), CWOverrideRedirect
| CWBackPixel, &wa);
+ XSetWindowBackground(dpy, w, 0x1111FF);
XAllocNamedColor(dpy, DefaultColormap(dpy, screen), "black",
&black, &dummy);
pmap = XCreateBitmapFromData(dpy, w, curs, 8, 8);
invisible = XCreatePixmapCursor(dpy, pmap, pmap, &black, &black, 0, 0);
Received on Fri Oct 12 2007 - 13:50:33 UTC
This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 16:29:45 UTC