abort early if the values are all setup already. Fixes bug #164281.

2005-05-06  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_by_values): abort early if the values are
	all setup already. Fixes bug #164281.
This commit is contained in:
Sven Neumann 2005-05-06 13:11:53 +00:00 committed by Sven Neumann
parent 260bf6e8ba
commit f3c0a28de8
2 changed files with 13 additions and 3 deletions

View File

@ -1,3 +1,9 @@
2005-05-06 Sven Neumann <sven@gimp.org>
* app/display/gimpdisplayshell-scale.c
(gimp_display_shell_scale_by_values): abort early if the values are
all setup already. Fixes bug #164281.
2005-05-06 Sven Neumann <sven@gimp.org>
* app/composite/gimp-composite-sse2.c

View File

@ -504,11 +504,15 @@ gimp_display_shell_scale_by_values (GimpDisplayShell *shell,
gint offset_y,
gboolean resize_window)
{
Gimp *gimp;
g_return_if_fail (GIMP_IS_DISPLAY_SHELL (shell));
gimp = shell->gdisp->gimage->gimp;
/* Abort early if the values are all setup already. We don't
* want to inadvertently resize the window (bug #164281).
*/
if (shell->scale == scale &&
shell->offset_x == offset_x &&
shell->offset_y == offset_y)
return;
/* freeze the active tool */
gimp_display_shell_pause (shell);