From 35ecf06f563d96a98924b2436a16fc17481abd36 Mon Sep 17 00:00:00 2001 From: Michael Natterer Date: Sat, 13 Jan 2018 21:26:27 +0100 Subject: [PATCH] app: don't add blacklisted/excluded actions to the action history gimp_action_history_init(): when deserializing the action history, check each action against gimp_action_history_excluded_action() so when we decide to exclude an action, it doesn't come back as history zombie from disk. --- app/widgets/gimpaction-history.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/app/widgets/gimpaction-history.c b/app/widgets/gimpaction-history.c index 745609e3ea..aa079c41e7 100644 --- a/app/widgets/gimpaction-history.c +++ b/app/widgets/gimpaction-history.c @@ -138,12 +138,15 @@ gimp_action_history_init (Gimp *gimp) break; } - history.items = - g_list_insert_sorted (history.items, - gimp_action_history_item_new (action_name, count), - (GCompareFunc) gimp_action_history_init_compare_func); + if (! gimp_action_history_excluded_action (action_name)) + { + history.items = + g_list_insert_sorted (history.items, + gimp_action_history_item_new (action_name, count), + (GCompareFunc) gimp_action_history_init_compare_func); - n_items++; + n_items++; + } g_free (action_name); }