[gthumb] fixed scripts always disabled in the tools menu
- From: Paolo Bacchilega <paobac src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gthumb] fixed scripts always disabled in the tools menu
- Date: Sun, 24 Nov 2019 12:33:53 +0000 (UTC)
commit aafed15f5f81142f549d3d33eabe450d71e3aa57
Author: Paolo Bacchilega <paobac src gnome org>
Date: Sat Nov 16 20:57:08 2019 +0100
fixed scripts always disabled in the tools menu
Ensure there is a 'win.' prefix in the detailed action.
extensions/list_tools/callbacks.c | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
---
diff --git a/extensions/list_tools/callbacks.c b/extensions/list_tools/callbacks.c
index fffa1732..9d49c43e 100644
--- a/extensions/list_tools/callbacks.c
+++ b/extensions/list_tools/callbacks.c
@@ -82,12 +82,23 @@ update_scripts (BrowserData *data)
shortcut);
if (gth_script_is_visible (script)) {
+ const char *script_action;
+ char *detailed_action;
+
+ script_action = gth_script_get_detailed_action (script);
+ if (! g_str_has_prefix (script_action, "win."))
+ detailed_action = g_strdup_printf ("win.%s", script_action);
+ else
+ detailed_action = g_strdup (script_action);
+
gth_menu_manager_append_entry (menu_manager,
data->menu_merge_id,
gth_script_get_display_name (script),
- shortcut->detailed_action,
+ detailed_action,
"",
NULL);
+
+ g_free (detailed_action);
}
gth_shortcut_free (shortcut);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]