Add new objects to the start of LdDiagram's list.

This way it doesn't have to go through the whole linked list
to find a place for the objects.
This commit is contained in:
Přemysl Eric Janouch 2011-01-05 05:29:52 +01:00
parent b08217f999
commit 63f6feaa0e

View File

@ -886,7 +886,7 @@ on_button_press (GtkWidget *widget, GdkEventButton *event, gpointer user_data)
move_object_to_widget_coords (self, data->object, event->x, event->y);
if (self->priv->diagram)
ld_diagram_insert_object (self->priv->diagram, data->object, -1);
ld_diagram_insert_object (self->priv->diagram, data->object, 0);
/* XXX: "cancel" causes confusion. */
ld_canvas_real_cancel_operation (self);