Commit b4c7dd8f authored by Jehan's avatar Jehan

app: run gimp_projectable_get_graph() before gegl_node_get_parent()...

... on top-level layers.
There was even a comment for this, but I missed this when I moved some
code to the top of the function in commit b9577a78. Now moving this
call up as well. This appeared to be more of a problem when merging
layers without a GUI (script-fu). I'm guessing the GUI calls this anyway
before.
parent 13b640f8
......@@ -459,6 +459,11 @@ gimp_image_merge_layers (GimpImage *image,
top_layer = merge_list->data;
parent = gimp_layer_get_parent (top_layer);
/* Make sure the image's graph is constructed, so that top-level layers have
* a parent node.
*/
(void) gimp_projectable_get_graph (GIMP_PROJECTABLE (image));
/* Build our graph inside the top-layer's parent node */
source_node = gimp_filter_get_node (GIMP_FILTER (top_layer));
node = gegl_node_get_parent (source_node);
......@@ -597,11 +602,6 @@ gimp_image_merge_layers (GimpImage *image,
gimp_item_set_offset (GIMP_ITEM (merge_layer), x1, y1);
/* Make sure the image's graph is constructed, so that top-level layers have
* a parent node.
*/
(void) gimp_projectable_get_graph (GIMP_PROJECTABLE (image));
offset_node = gegl_node_new_child (node,
"operation", "gegl:translate",
"x", (gdouble) -x1,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment