[gimp] app: remove one more usage of gimp_image_get_active_vectors().
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: remove one more usage of gimp_image_get_active_vectors().
- Date: Tue, 18 Oct 2022 14:36:54 +0000 (UTC)
commit cff1ae4176b20216017fd7f0c513d28c26ccb96b
Author: Jehan <jehan girinstud io>
Date: Tue Oct 18 16:35:00 2022 +0200
app: remove one more usage of gimp_image_get_active_vectors().
For "text-tool-text-along-path", it makes sense to keep it only usable when a
single path is selected.
app/actions/text-tool-actions.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/app/actions/text-tool-actions.c b/app/actions/text-tool-actions.c
index 8cfb548a44..dc40411451 100644
--- a/app/actions/text-tool-actions.c
+++ b/app/actions/text-tool-actions.c
@@ -162,7 +162,7 @@ text_tool_actions_update (GimpActionGroup *group,
GimpDisplay *display = GIMP_TOOL (text_tool)->display;
GimpImage *image = gimp_display_get_image (display);
GList *layers;
- GimpVectors *vectors;
+ GList *paths;
GimpDisplayShell *shell;
GtkClipboard *clipboard;
gboolean text_layer = FALSE;
@@ -176,7 +176,7 @@ text_tool_actions_update (GimpActionGroup *group,
if (g_list_length (layers) == 1)
text_layer = gimp_item_is_text_layer (GIMP_ITEM (layers->data));
- vectors = gimp_image_get_active_vectors (image);
+ paths = gimp_image_get_selected_vectors (image);
text_sel = gimp_text_tool_get_has_text_selection (text_tool);
@@ -200,7 +200,7 @@ text_tool_actions_update (GimpActionGroup *group,
SET_SENSITIVE ("text-tool-clear", text_layer);
SET_SENSITIVE ("text-tool-load", image);
SET_SENSITIVE ("text-tool-text-to-path", text_layer);
- SET_SENSITIVE ("text-tool-text-along-path", text_layer && vectors);
+ SET_SENSITIVE ("text-tool-text-along-path", text_layer && g_list_length (paths) == 1);
direction = gimp_text_tool_get_direction (text_tool);
for (i = 0; i < G_N_ELEMENTS (text_tool_direction_actions); i++)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]