Check if there is an active layer if active_layer_only is TRUE

This commit is contained in:
Michael Natterer 2009-08-20 22:41:49 +02:00
parent de409ea52a
commit 0953146be1
1 changed files with 2 additions and 0 deletions

View File

@ -89,6 +89,8 @@ gimp_image_crop (GimpImage *image,
g_return_if_fail (GIMP_IS_IMAGE (image));
g_return_if_fail (GIMP_IS_CONTEXT (context));
g_return_if_fail (active_layer_only == FALSE ||
gimp_image_get_active_layer (image));
previous_width = gimp_image_get_width (image);
previous_height = gimp_image_get_height (image);