aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/misc
diff options
context:
space:
mode:
authorChris Toshok <toshok@ximian.com>2003-02-17 10:58:09 +0800
committerChris Toshok <toshok@src.gnome.org>2003-02-17 10:58:09 +0800
commit0f7100a65c102ee23ae4066ce790f315a68c6adb (patch)
treed96b1c25be987ca37b843806e6890388c2ae9cc4 /widgets/misc
parentbaa50a5c8934d74573914b6425a5457f420fba93 (diff)
downloadgsoc2013-evolution-0f7100a65c102ee23ae4066ce790f315a68c6adb.tar.gz
gsoc2013-evolution-0f7100a65c102ee23ae4066ce790f315a68c6adb.tar.zst
gsoc2013-evolution-0f7100a65c102ee23ae4066ce790f315a68c6adb.zip
make this actually work: destroy the canvas item, memmove stuff around,
2003-02-16 Chris Toshok <toshok@ximian.com> * gal/widgets/e-reflow.c (item_removed): make this actually work: destroy the canvas item, memmove stuff around, change reflow->count, etc, etc. svn path=/trunk/; revision=19918
Diffstat (limited to 'widgets/misc')
-rw-r--r--widgets/misc/e-reflow.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/widgets/misc/e-reflow.c b/widgets/misc/e-reflow.c
index 70b1f4a470..8754c5a042 100644
--- a/widgets/misc/e-reflow.c
+++ b/widgets/misc/e-reflow.c
@@ -334,6 +334,14 @@ item_removed (EReflowModel *model, int i, EReflow *reflow)
if (i < 0 || i >= reflow->count)
return;
+ if (reflow->items[i])
+ gtk_object_destroy (GTK_OBJECT (reflow->items[i]));
+
+ memmove (reflow->heights + i, reflow->heights + i + 1, (reflow->count - i - 1) * sizeof (int));
+ memmove (reflow->items + i, reflow->items + i + 1, (reflow->count - i - 1) * sizeof (GnomeCanvasItem *));
+
+ reflow->count --;
+
sorted = e_sorter_model_to_sorted (E_SORTER (reflow->sorter), i);
for (c = reflow->column_count - 1; c >= 0; c--) {
int start_of_column = reflow->columns[c];
@@ -347,6 +355,10 @@ item_removed (EReflowModel *model, int i, EReflow *reflow)
break;
}
}
+
+ e_sorter_array_set_count (reflow->sorter, reflow->count);
+
+ e_selection_model_simple_delete_rows (E_SELECTION_MODEL_SIMPLE (reflow->selection), i, 1);
}
static void
d>2015-01-112-228/+31 * Update devel/doxygen to 1.8.9antoine2014-12-312-13/+7 * Update to version 0.9.1pawel2014-12-162-5/+3 * Cleanup plistantoine2014-11-221-8/+0 * Update the default version of GCC in the Ports Collection from GCC 4.7.4gerald2014-09-111-0/+1 * net/nmsg: fix build for FreeBSD 8.xwg2014-08-181-0/+7 * net/nmsg: update to 0.9.0wg2014-08-175-38/+10 * Update devel/doxygen to 1.8.7antoine2014-08-102-3/+1 * Add new port net/nmsgmarino2014-08-07