[dia] [transform] Recalculate layer extents in layer_replace_object_with_list()
- From: Hans Breuer <hans src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [dia] [transform] Recalculate layer extents in layer_replace_object_with_list()
- Date: Sat, 26 Apr 2014 17:17:32 +0000 (UTC)
commit 52dc31db0c3c07101d95512fd53e73e6ac5b53ea
Author: Hans Breuer <hans breuer org>
Date: Fri Apr 25 12:08:51 2014 +0200
[transform] Recalculate layer extents in layer_replace_object_with_list()
Currently this function is only used when un-grouping objects. Formerly
this was an operation never changing the extents because a group had
the same bounding box as it's joined objects. Now with groups with
transformation the objects position and size might change. But even
without the transformation this extra call should cause no harm except
for some extra CPU cycles.
lib/layer.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/lib/layer.c b/lib/layer.c
index 9f63c5f..7723ed9 100644
--- a/lib/layer.c
+++ b/lib/layer.c
@@ -622,6 +622,10 @@ layer_replace_object_with_list(Layer *layer, DiaObject *remove_obj,
il = g_list_next(il);
}
g_list_free_1(list);
+
+ /* with transformed groups the list and the single object are not necessarily
+ * of the same size */
+ layer_update_extents (layer);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]