]> git.sur5r.net Git - i3/i3lock/commitdiff
Removed obsolete inactivity timeout (#84)
authorFlorian Zipperle <zipperle@users.noreply.github.com>
Wed, 20 Jul 2016 06:50:07 +0000 (08:50 +0200)
committerMichael Stapelberg <stapelberg@users.noreply.github.com>
Wed, 20 Jul 2016 06:50:07 +0000 (07:50 +0100)
* Removed obsolete inactivity timeout

i3lock.1
i3lock.c

index eca7f976ed7d6a012b698479136d62556c2781fd..55af52d759a7576ec53a2058310953b04b8a78e9 100644 (file)
--- a/i3lock.1
+++ b/i3lock.1
@@ -27,8 +27,6 @@ i3lock \- improved screen locker
 .IR pointer\|]
 .RB [\|\-u\|]
 .RB [\|\-e\|]
-.RB [\|\-I
-.IR timeout\|]
 .RB [\|\-f\|]
 
 .SH DESCRIPTION
@@ -64,13 +62,6 @@ Don't fork after starting.
 Enable beeping. Be sure to not do this when you are about to annoy other people,
 like when opening your laptop in a boring lecture.
 
-.TP
-.BI \-I\  seconds \fR,\ \fB\-\-inactivity-timeout= seconds
-Specifies the number of seconds i3lock will wait for another password before
-turning off the monitors, in case you entered a wrong password or canceled by
-pressing Escape. Only makes sense together with \-d. If omitted, the default is
-30 seconds.
-
 .TP
 .B \-u, \-\-no-unlock-indicator
 Disable the unlock indicator. i3lock will by default show an unlock indicator
@@ -140,6 +131,8 @@ use a wrapper script around i3lock like the following:
 \&     revert
 .Ve
 
+The \-I (-\-inactivity-timeout=seconds) was removed because it only makes sense with DPMS.
+
 .SH SEE ALSO
 .IR xautolock(1)
 \- use i3lock as your screen saver
index 0383ebea575eb34027161d65cbed2d341dda533b..380cab47b33292e48bd1c74d03aba626c10899ab 100644 (file)
--- a/i3lock.c
+++ b/i3lock.c
@@ -45,7 +45,6 @@
 typedef void (*ev_callback_t)(EV_P_ ev_timer *w, int revents);
 
 char color[7] = "ffffff";
-int inactivity_timeout = 30;
 uint32_t last_resolution[2];
 xcb_window_t win;
 static xcb_cursor_t cursor;
@@ -806,10 +805,7 @@ int main(int argc, char *argv[]) {
                 fprintf(stderr, "DPMS support has been removed from i3lock. Please see the manpage i3lock(1).\n");
                 break;
             case 'I': {
-                int time = 0;
-                if (sscanf(optarg, "%d", &time) != 1 || time < 0)
-                    errx(EXIT_FAILURE, "invalid timeout, it must be a positive integer\n");
-                inactivity_timeout = time;
+                fprintf(stderr, "Inactivity timeout only makes sense with DPMS, which was removed. Please see the manpage i3lock(1).\n");
                 break;
             }
             case 'c': {