adf0225368
New patch-ad fixes problem with unset loginmoveInterval resource, reported (including patch) by Robert Elz in pkg/15040.
32 lines
1,005 B
Text
32 lines
1,005 B
Text
$NetBSD: patch-ad,v 1.1 2002/03/20 01:52:31 wiz Exp $
|
|
|
|
--- greeter/greet.c.orig Tue Aug 18 16:24:56 1998
|
|
+++ greeter/greet.c Sun Dec 23 23:45:13 2001
|
|
@@ -122,6 +122,9 @@
|
|
|
|
d = (struct display *) closure;
|
|
|
|
+if (d->loginmoveInterval <= 0)
|
|
+ return;
|
|
+
|
|
scrn = XDefaultScreenOfDisplay(dpy);
|
|
/*
|
|
XtSetArg (args[0], XtNwidth, (XtArgVal) &width);
|
|
@@ -255,7 +258,7 @@
|
|
0, 0, 0, 0,
|
|
XWidthOfScreen(scrn) / 2,
|
|
XHeightOfScreen(scrn) / 2);
|
|
- if (d->loginmoveInterval > -1)
|
|
+ if (d->loginmoveInterval > 0)
|
|
moveTimeout = XtAppAddTimeOut (context, d->loginmoveInterval*10000, time_test, (XtPointer) d);
|
|
|
|
if (d->pingInterval)
|
|
@@ -315,7 +318,7 @@
|
|
while (!done) {
|
|
XtAppNextEvent (context, &event);
|
|
/* by Amit Margalit 19-Apr-1997 */
|
|
- if(event.type == KeyPress)
|
|
+ if(moveTimeout && event.type == KeyPress)
|
|
{ /* reset the timeout as long as we type it stays in place */
|
|
XtMoveWidget(toplevel,orig_x,orig_y);
|
|
XtRemoveTimeOut(moveTimeout);
|