[gimp] Bug 792686 - Colormap widget not updated when adding entry
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] Bug 792686 - Colormap widget not updated when adding entry
- Date: Mon, 19 Mar 2018 23:56:09 +0000 (UTC)
commit 28d9e43f5366a12a86d666a071c490c841d40743
Author: Michael Natterer <mitch gimp org>
Date: Tue Mar 20 00:53:57 2018 +0100
Bug 792686 - Colormap widget not updated when adding entry
gimp_image_add_colormap_entry(): increment private->n_colors *before*
calling gimp_image_colormap_set_palette_entry() so it actually adds an
entry.
app/core/gimpimage-colormap.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/app/core/gimpimage-colormap.c b/app/core/gimpimage-colormap.c
index 6b53d6c..7a4b147 100644
--- a/app/core/gimpimage-colormap.c
+++ b/app/core/gimpimage-colormap.c
@@ -326,11 +326,11 @@ gimp_image_add_colormap_entry (GimpImage *image,
&private->colormap[private->n_colors * 3 + 1],
&private->colormap[private->n_colors * 3 + 2]);
+ private->n_colors++;
+
if (private->palette)
gimp_image_colormap_set_palette_entry (image, private->n_colors - 1);
- private->n_colors++;
-
gimp_image_colormap_changed (image, -1);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]