app: fix buffer copying offsets in gimp_clone_motion()

so it works again at the image's borders.
This commit is contained in:
Michael Natterer 2012-03-30 23:42:23 +02:00
parent 7181402a62
commit 2c4a59c1e5
1 changed files with 8 additions and 4 deletions

View File

@ -175,17 +175,21 @@ gimp_clone_motion (GimpSourceCore *source_core,
dest_buffer =
gegl_buffer_linear_new_from_data (temp_buf_get_data (paint_area),
gimp_drawable_get_format_with_alpha (drawable),
GIMP_GEGL_RECT (paint_area_offset_x, paint_area_offset_y,
paint_area_width, paint_area_height),
GIMP_GEGL_RECT (0, 0,
paint_area->width,
paint_area->height),
paint_area->width *
paint_area->bytes,
NULL, NULL);
gegl_buffer_copy (src_buffer,
GIMP_GEGL_RECT (0, 0,
paint_area_width, paint_area_height),
paint_area_width,
paint_area_height),
dest_buffer,
NULL);
GIMP_GEGL_RECT (paint_area_offset_x,
paint_area_offset_y,
0, 0));
g_object_unref (dest_buffer);
}