[gimp] app: in GimpEditSelectionTool, freeze moved items' previews
- From: Ell <ell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: in GimpEditSelectionTool, freeze moved items' previews
- Date: Wed, 4 Sep 2019 18:01:08 +0000 (UTC)
commit 915bdffb5a5ff38a42038be2e7380951df904e30
Author: Ell <ell_se yahoo com>
Date: Wed Sep 4 18:49:54 2019 +0300
app: in GimpEditSelectionTool, freeze moved items' previews
... to avoid unnecessarily updating their previews while dragging,
and, in particular, to avoid updating the image's GimpImageViewable
size in show-all mode.
app/tools/gimpeditselectiontool.c | 16 ++++++++++++++--
1 file changed, 14 insertions(+), 2 deletions(-)
---
diff --git a/app/tools/gimpeditselectiontool.c b/app/tools/gimpeditselectiontool.c
index 43d430428f..8f931f6137 100644
--- a/app/tools/gimpeditselectiontool.c
+++ b/app/tools/gimpeditselectiontool.c
@@ -417,7 +417,13 @@ gimp_edit_selection_tool_start (GimpTool *parent_tool,
}
for (list = edit_select->live_items; list; list = g_list_next (list))
- gimp_item_start_transform (GIMP_ITEM (list->data), TRUE);
+ {
+ GimpItem *item = list->data;
+
+ gimp_viewable_preview_freeze (GIMP_VIEWABLE (item));
+
+ gimp_item_start_transform (item, TRUE);
+ }
tool_manager_push_tool (display->gimp, tool);
@@ -471,7 +477,13 @@ gimp_edit_selection_tool_button_release (GimpTool *tool,
TRUE);
for (list = edit_select->live_items; list; list = g_list_next (list))
- gimp_item_end_transform (GIMP_ITEM (list->data), TRUE);
+ {
+ GimpItem *item = list->data;
+
+ gimp_item_end_transform (item, TRUE);
+
+ gimp_viewable_preview_thaw (GIMP_VIEWABLE (item));
+ }
gimp_image_undo_group_end (image);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]