From 49308ff2f6ca0d4c640bc584b1b87a3ee6e31e97 Mon Sep 17 00:00:00 2001 From: Maximilian Albert Date: Thu, 13 Dec 2007 20:08:06 +0000 Subject: If necessary, split up perspectives when applying transformations to boxes; moreover, fix crash caused by listening to already destroyed perspectives (bzr r4227) --- src/vanishing-point.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/vanishing-point.cpp') diff --git a/src/vanishing-point.cpp b/src/vanishing-point.cpp index 0a8336102..0b68ff541 100644 --- a/src/vanishing-point.cpp +++ b/src/vanishing-point.cpp @@ -125,11 +125,7 @@ vp_knot_moved_handler (SPKnot *knot, NR::Point const *ppointer, guint state, gpo /* if a box in the VP is unselected, move it to the newly created perspective so that it doesn't get dragged **/ //g_print (" switching box #%d to new perspective.\n", (*i)->my_counter); - persp3d_remove_box (old_persp, *i); - persp3d_add_box (new_persp, *i); - gchar *href = g_strdup_printf("#%s", SP_OBJECT_REPR(new_persp)->attribute("id")); - SP_OBJECT_REPR(*i)->setAttribute("inkscape:perspectiveID", href); - g_free(href); + box3d_switch_perspectives(*i, old_persp, new_persp); } } } -- cgit v1.2.3