mirror of https://github.com/GNOME/gimp.git
copy the merged layer, not the first one. Preserve the type of the layer
2004-06-02 Michael Natterer <mitch@gimp.org> * app/display/gimpdisplayshell-dnd.c (gimp_display_shell_drop_files): copy the merged layer, not the first one. Preserve the type of the layer to make e.g. dropping an XCF with a single text layer work.
This commit is contained in:
parent
631b5b4d95
commit
4e9c58a589
|
@ -1,3 +1,10 @@
|
|||
2004-06-02 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* app/display/gimpdisplayshell-dnd.c
|
||||
(gimp_display_shell_drop_files): copy the merged layer, not the
|
||||
first one. Preserve the type of the layer to make e.g. dropping an
|
||||
XCF with a single text layer work.
|
||||
|
||||
2004-06-02 Sven Neumann <sven@gimp.org>
|
||||
|
||||
* NEWS
|
||||
|
|
|
@ -296,18 +296,23 @@ gimp_display_shell_drop_files (GtkWidget *widget,
|
|||
gimp_image_undo_disable (new_image);
|
||||
|
||||
if (gimp_container_num_children (new_image->layers) > 1)
|
||||
gimp_image_merge_visible_layers (new_image, context,
|
||||
GIMP_CLIP_TO_IMAGE);
|
||||
|
||||
layer = (GimpLayer *)
|
||||
gimp_container_get_child_by_index (new_image->layers, 0);
|
||||
{
|
||||
layer = gimp_image_merge_visible_layers (new_image, context,
|
||||
GIMP_CLIP_TO_IMAGE);
|
||||
}
|
||||
else
|
||||
{
|
||||
layer = (GimpLayer *)
|
||||
gimp_container_get_child_by_index (new_image->layers, 0);
|
||||
}
|
||||
|
||||
if (layer)
|
||||
{
|
||||
GimpItem *new_item;
|
||||
|
||||
new_item = gimp_item_convert (GIMP_ITEM (layer), gimage,
|
||||
GIMP_TYPE_LAYER, TRUE);
|
||||
G_TYPE_FROM_INSTANCE (layer),
|
||||
TRUE);
|
||||
|
||||
if (new_item)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue