Make sure all group layers' projections switch to GEGL with the main projection
This commit is contained in:
parent
1403db11ef
commit
6934a0d2eb
2 changed files with 19 additions and 0 deletions
|
|
@ -30,6 +30,7 @@
|
|||
#include "core/gimp.h"
|
||||
#include "core/gimpcontext.h"
|
||||
#include "core/gimpimage.h"
|
||||
#include "core/gimpgrouplayer.h"
|
||||
#include "core/gimpprojection.h"
|
||||
|
||||
#include "display/gimpdisplay.h"
|
||||
|
|
@ -690,6 +691,8 @@ view_use_gegl_cmd_callback (GtkAction *action,
|
|||
GimpImage *image;
|
||||
GimpDisplay *display;
|
||||
GimpDisplayShell *shell;
|
||||
GList *layers;
|
||||
GList *list;
|
||||
gboolean active;
|
||||
return_if_no_image (image, data);
|
||||
return_if_no_display (display, data);
|
||||
|
|
@ -699,6 +702,19 @@ view_use_gegl_cmd_callback (GtkAction *action,
|
|||
active = gtk_toggle_action_get_active (GTK_TOGGLE_ACTION (action));
|
||||
|
||||
image->projection->use_gegl = active;
|
||||
|
||||
layers = gimp_image_get_layer_list (image);
|
||||
|
||||
for (list = layers; list; list = g_list_next (list))
|
||||
{
|
||||
GimpLayer *layer = list->data;
|
||||
|
||||
if (GIMP_IS_GROUP_LAYER (layer))
|
||||
GIMP_GROUP_LAYER (layer)->projection->use_gegl = active;
|
||||
}
|
||||
|
||||
g_list_free (layers);
|
||||
|
||||
gimp_image_update (image, 0, 0, image->width, image->height);
|
||||
gimp_image_flush (image);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -592,6 +592,9 @@ gimp_group_layer_new (GimpImage *image)
|
|||
gimp_image_base_type_with_alpha (image),
|
||||
_("Group Layer"));
|
||||
|
||||
if (gimp_image_get_projection (image)->use_gegl)
|
||||
group->projection->use_gegl = TRUE;
|
||||
|
||||
return GIMP_LAYER (group);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue