From 22502abf2cda44d5311ba2fd8424bdfd99fb04c0 Mon Sep 17 00:00:00 2001 From: vague666 Date: Fri, 22 Mar 2019 19:10:10 +0100 Subject: [PATCH] Add setting to choose between window name and visible name in actlist --- src/fe-text/statusbar-items.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/fe-text/statusbar-items.c b/src/fe-text/statusbar-items.c index 5740a40b..bd715950 100644 --- a/src/fe-text/statusbar-items.c +++ b/src/fe-text/statusbar-items.c @@ -123,7 +123,9 @@ static char *get_activity_list(MAIN_WINDOW_REC *window, int normal, int hilight) window->hilight_color, window->refnum); if (add_name && window->active != NULL) - g_string_append_printf(format, ":%s", window->active->visible_name); + g_string_append_printf(format, ":%s", + settings_get_bool("actlist_prefer_window_name") && + window->name != NULL ? window->name : window->active->visible_name); g_string_append_c(format, '}'); value = theme_format_expand(theme, format->str); @@ -470,6 +472,7 @@ void statusbar_items_init(void) settings_add_time("misc", "lag_min_show", "1sec"); settings_add_str("lookandfeel", "actlist_sort", "refnum"); settings_add_bool("lookandfeel", "actlist_names", FALSE); + settings_add_bool("lookandfeel", "actlist_prefer_window_name", FALSE); statusbar_item_register("window", NULL, item_window_active); statusbar_item_register("window_empty", NULL, item_window_empty);