aboutsummaryrefslogtreecommitdiffstats
path: root/dwm.c
diff options
context:
space:
mode:
authorEduardo Pedroni <e.pedroni91@gmail.com>2016-12-07 22:00:03 +0100
committerEduardo Pedroni <e.pedroni91@gmail.com>2016-12-07 22:00:03 +0100
commit12dc48cfbbfa5bfd3520a375da561e4a4713b3e2 (patch)
treebf1fe71fe1f735dd0fb1bb64dbf584345191362e /dwm.c
parent309cbf2b363ed530d20f686b4bc5a9e8e576cab9 (diff)
Updated productivity mode to include bottom bar indicator
Diffstat (limited to 'dwm.c')
-rw-r--r--dwm.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/dwm.c b/dwm.c
index 59c4b2a..41ae6e2 100644
--- a/dwm.c
+++ b/dwm.c
@@ -857,6 +857,14 @@ drawbar(Monitor *m) {
else
drawtext(dc.drawable, NULL, 0, False);
}
+
+ struct timeval tv;
+ gettimeofday(&tv, NULL);
+ if (tv.tv_sec - latestlock.tv_sec < ptimeout)
+ drawtext(dc.drawable, "\uE2FC", 2, True);
+ else
+ drawtext(dc.drawable, NULL, 0, False);
+
XCopyArea(dpy, dc.drawable, m->barwin, dc.gc, 0, 0, m->ww, bh, 0, 0);
XSync(dpy, False);
}