Compare commits

..

4 Commits

Author SHA1 Message Date
Ryan be57a7995c
create initial config.h 2023-09-20 20:52:55 -04:00
Ryan f99733cd99
fix formatting issues 2023-09-20 20:52:16 -04:00
Ryan 6f645ea4af
apply xresources patch 2023-09-20 20:50:24 -04:00
Ryan 69f39f0bf8
apply dpms patch
Turns the monitor off after some time.
2023-09-20 17:42:27 -04:00
2 changed files with 9 additions and 10 deletions

View File

@ -1,6 +1,6 @@
/* user and group to drop privileges to */
static const char *user = "ryan";
static const char *group = "ryan";
static const char *user = "nobody";
static const char *group = "nogroup";
static const char *colorname[NUMCOLS] = {
[BACKGROUND] = "white",
@ -13,10 +13,10 @@ static const char *colorname[NUMCOLS] = {
* Xresources preferences to load at startup
*/
ResourcePref resources[] = {
{ "background", STRING, &colorname[BACKGROUND] },
{ "fadeColor", STRING, &colorname[INIT] },
{ "accentColor", STRING, &colorname[INPUT] },
{ "alertColor", STRING, &colorname[FAILED] },
{ "normbgcolor", STRING, &colorname[BACKGROUND] },
{ "normfgcolor", STRING, &colorname[INIT] },
{ "selfgcolor", STRING, &colorname[INPUT] },
{ "failfgcolor", STRING, &colorname[FAILED] },
};
/* treat a cleared input like a wrong password (color) */

View File

@ -607,10 +607,6 @@ main(int argc, char **argv) {
/* everything is now blank. Wait for the correct password */
readpw(dpy, &rr, locks, nscreens, hash);
/* reset DPMS values to inital ones */
DPMSSetTimeouts(dpy, standby, suspend, off);
XSync(dpy, 0);
for (nlocks = 0, s = 0; s < nscreens; s++) {
XFreePixmap(dpy, locks[s]->drawable);
XFreeGC(dpy, locks[s]->gc);
@ -618,6 +614,9 @@ main(int argc, char **argv) {
XSync(dpy, 0);
XCloseDisplay(dpy);
/* reset DPMS values to inital ones */
DPMSSetTimeouts(dpy, standby, suspend, off);
XSync(dpy, 0);
return 0;
}