From 015dbd9a96d43aa05a69eb47038aa38b2989a303 Mon Sep 17 00:00:00 2001 From: Johannes Heimansberg <70129388+jhe2@users.noreply.github.com> Date: Mon, 24 Aug 2020 08:36:02 +0200 Subject: [PATCH] fix: Fix non-working bell notifications The problem with the bell notifications only happens when Toxic is compiled with X11 support, but does not run under X. This commit changes toxic's behavior such that it behaves identically when not running under an X session, no matter if it has been compiled with X11 support or not. --- src/xtra.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/xtra.c b/src/xtra.c index f81c671..90bdb56 100644 --- a/src/xtra.c +++ b/src/xtra.c @@ -302,7 +302,7 @@ static long unsigned int focused_window_id(void) int is_focused(void) { - return Xtra.proxy_window == focused_window_id() || Xtra.terminal_window == focused_window_id(); + return Xtra.display && (Xtra.proxy_window == focused_window_id() || Xtra.terminal_window == focused_window_id()); } int init_xtra(drop_callback d)