app: In GimpBlendTool, fix the preview for layers with offsets.

This commit is contained in:
Michael Henning
2014-07-22 17:39:58 -04:00
parent dbd1f0500e
commit f7986e391e

View File

@ -877,11 +877,16 @@ gimp_blend_tool_create_graph (GimpBlendTool *blend_tool)
static void static void
gimp_blend_tool_update_preview_coords (GimpBlendTool *blend_tool) gimp_blend_tool_update_preview_coords (GimpBlendTool *blend_tool)
{ {
GimpTool *tool = GIMP_TOOL (blend_tool);
gint off_x, off_y;
gimp_item_get_offset (GIMP_ITEM (tool->drawable), &off_x, &off_y);
gegl_node_set (blend_tool->render_node, gegl_node_set (blend_tool->render_node,
"start_x", blend_tool->start_x, "start_x", blend_tool->start_x - off_x,
"start_y", blend_tool->start_y, "start_y", blend_tool->start_y - off_y,
"end_x", blend_tool->end_x, "end_x", blend_tool->end_x - off_x,
"end_y", blend_tool->end_y, "end_y", blend_tool->end_y - off_y,
NULL); NULL);
} }