Commit 3cfd2a33 authored by Martin Nordholts's avatar Martin Nordholts Committed by Martin Nordholts

Canonically calculate scale to use for zoom-focus calculations so that it

2008-08-28  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_to): Canonically calculate scale to use
	for zoom-focus calculations so that it also works when not in Dot
	by dot-mode.

svn path=/trunk/; revision=26805
parent 2975f815
2008-08-28 Martin Nordholts <martinn@svn.gnome.org>
* app/display/gimpdisplayshell-scale.c
(gimp_display_shell_scale_to): Canonically calculate scale to use
for zoom-focus calculations so that it also works when not in Dot
by dot-mode.
2008-08-28 Martin Nordholts <martinn@svn.gnome.org>
* app/core/gimpimage.[ch]: Make the size-changed-detailed signal
......
......@@ -751,6 +751,7 @@ gimp_display_shell_scale_to (GimpDisplayShell *shell,
gint viewport_x,
gint viewport_y)
{
gdouble scale_x, scale_y;
gdouble image_focus_x, image_focus_y;
gint target_offset_x, target_offset_y;
......@@ -766,8 +767,10 @@ gimp_display_shell_scale_to (GimpDisplayShell *shell,
&image_focus_y,
FALSE);
target_offset_x = scale * image_focus_x - viewport_x;
target_offset_y = scale * image_focus_y - viewport_y;
gimp_display_shell_calculate_scale_x_and_y (shell, scale, &scale_x, &scale_y);
target_offset_x = scale_x * image_focus_x - viewport_x;
target_offset_y = scale_y * image_focus_y - viewport_y;
/* Note that we never come here if we need to
* resize_windows_on_zoom
......
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