Commit 52f7746e authored by Michael Natterer's avatar Michael Natterer 😴 Committed by Michael Natterer
Browse files

Make sure the image preview is only invalidated for visible image changes

2007-06-21  Michael Natterer  <mitch@gimp.org>

	Make sure the image preview is only invalidated for visible
	image changes (as it was before the change below).

	* app/core/gimpimage.h (struct GimpImageFlushAccumulator): added
	member "gboolean preview_invalidated".

	* app/core/gimpimage.c (gimp_image_update): set it to TRUE here.

	(gimp_image_real_flush): inavlidate the preview only if
	flush_accum.preview_invalidated is TRUE.


svn path=/trunk/; revision=22817
parent 46070874
2007-06-21 Michael Natterer <mitch@gimp.org>
Make sure the image preview is only invalidated for visible
image changes (as it was before the change below).
* app/core/gimpimage.h (struct GimpImageFlushAccumulator): added
member "gboolean preview_invalidated".
* app/core/gimpimage.c (gimp_image_update): set it to TRUE here.
(gimp_image_real_flush): inavlidate the preview only if
flush_accum.preview_invalidated is TRUE.
2007-06-21 Michael Natterer <mitch@gimp.org>
 
Part one of fix for bug #449141 (fixes the projection but still
......@@ -668,8 +668,9 @@ gimp_image_init (GimpImage *image)
image->preview = NULL;
image->flush_accum.alpha_changed = FALSE;
image->flush_accum.mask_changed = FALSE;
image->flush_accum.alpha_changed = FALSE;
image->flush_accum.mask_changed = FALSE;
image->flush_accum.preview_invalidated = FALSE;
}
static GObject *
......@@ -1136,7 +1137,11 @@ gimp_image_real_flush (GimpImage *image)
image->flush_accum.mask_changed = FALSE;
}
gimp_viewable_invalidate_preview (GIMP_VIEWABLE (image));
if (image->flush_accum.preview_invalidated)
{
gimp_viewable_invalidate_preview (GIMP_VIEWABLE (image));
image->flush_accum.preview_invalidated = FALSE;
}
}
static void
......@@ -1726,6 +1731,8 @@ gimp_image_update (GimpImage *image,
g_signal_emit (image, gimp_image_signals[UPDATE], 0,
x, y, width, height);
image->flush_accum.preview_invalidated = TRUE;
}
void
......
......@@ -82,6 +82,7 @@ struct _GimpImageFlushAccumulator
{
gboolean alpha_changed;
gboolean mask_changed;
gboolean preview_invalidated;
};
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment