From db2529159cb7362d143a24c7a23626860d3f2e69 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Fri, 22 Oct 2021 20:04:23 +0200 Subject: [PATCH] =?UTF-8?q?term:=20bell:=20simplify=20if-statement=20-=20w?= =?UTF-8?q?e=20don=E2=80=99t=20need=20two=20nested=20levels?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- terminal.c | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/terminal.c b/terminal.c index 69f4755b..50c43d39 100644 --- a/terminal.c +++ b/terminal.c @@ -3072,17 +3072,15 @@ term_bell(struct terminal *term) if (!term->bell_action_enabled) return; - if (!term->kbd_focus) { - if (term->conf->bell.urgent) { - if (!wayl_win_set_urgent(term->window)) { - /* - * Urgency (xdg-activation) is relatively new in - * Wayland. Fallback to our old, “faked”, urgency - - * rendering our window margins in red - */ - term->render.urgency = true; - term_damage_margins(term); - } + if (term->conf->bell.urgent && !term->kbd_focus) { + if (!wayl_win_set_urgent(term->window)) { + /* + * Urgency (xdg-activation) is relatively new in + * Wayland. Fallback to our old, “faked”, urgency - + * rendering our window margins in red + */ + term->render.urgency = true; + term_damage_margins(term); } }