mirror of https://github.com/GNOME/gimp.git
app: in gimp_filter_tool_get_drawable_area(), don't return empty area
In gimp_filter_tool_get_drawable_area(), when the image mask doesn't intersect the drawable, return a minimal area, instead of an empty/invalid area.
This commit is contained in:
parent
30429e30e2
commit
428ee0e2ad
|
@ -1801,11 +1801,17 @@ gimp_filter_tool_get_drawable_area (GimpFilterTool *filter_tool,
|
|||
switch (options->region)
|
||||
{
|
||||
case GIMP_FILTER_REGION_SELECTION:
|
||||
gimp_item_mask_intersect (GIMP_ITEM (drawable),
|
||||
if (! gimp_item_mask_intersect (GIMP_ITEM (drawable),
|
||||
&drawable_area->x,
|
||||
&drawable_area->y,
|
||||
&drawable_area->width,
|
||||
&drawable_area->height);
|
||||
&drawable_area->height))
|
||||
{
|
||||
drawable_area->x = 0;
|
||||
drawable_area->y = 0;
|
||||
drawable_area->width = 1;
|
||||
drawable_area->height = 1;
|
||||
}
|
||||
break;
|
||||
|
||||
case GIMP_FILTER_REGION_DRAWABLE:
|
||||
|
|
Loading…
Reference in New Issue