aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table/e-table-item.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@ximian.com>2002-04-30 07:17:14 +0800
committerChris Lahey <clahey@src.gnome.org>2002-04-30 07:17:14 +0800
commitf1cdb504e8a763113c629d806656eec6b7eca48e (patch)
treedce4fc2be01581a76a3b1cf46d9110d421f38b21 /widgets/table/e-table-item.c
parentfb0dde8aee1e2464c1c18949134ae67717f324bf (diff)
downloadgsoc2013-evolution-f1cdb504e8a763113c629d806656eec6b7eca48e.tar
gsoc2013-evolution-f1cdb504e8a763113c629d806656eec6b7eca48e.tar.gz
gsoc2013-evolution-f1cdb504e8a763113c629d806656eec6b7eca48e.tar.bz2
gsoc2013-evolution-f1cdb504e8a763113c629d806656eec6b7eca48e.tar.lz
gsoc2013-evolution-f1cdb504e8a763113c629d806656eec6b7eca48e.tar.xz
gsoc2013-evolution-f1cdb504e8a763113c629d806656eec6b7eca48e.tar.zst
gsoc2013-evolution-f1cdb504e8a763113c629d806656eec6b7eca48e.zip
From gal/e-table/ChangeLog:
2002-04-29 Christopher James Lahey <clahey@ximian.com> * e-table-item.c (eti_cursor_change): Redraw a row that is no longer the cursor even if this item isn't getting the new cursor. svn path=/trunk/; revision=16642
Diffstat (limited to 'widgets/table/e-table-item.c')
-rw-r--r--widgets/table/e-table-item.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/widgets/table/e-table-item.c b/widgets/table/e-table-item.c
index b647d1b1bd..d92a174f45 100644
--- a/widgets/table/e-table-item.c
+++ b/widgets/table/e-table-item.c
@@ -1195,7 +1195,8 @@ static void
e_table_item_redraw_row (ETableItem *eti,
int row)
{
- e_table_item_redraw_range (eti, 0, row, eti->cols - 1, row);
+ if (row != -1)
+ e_table_item_redraw_range (eti, 0, row, eti->cols - 1, row);
}
static void
@@ -2988,6 +2989,9 @@ eti_cursor_change (ESelectionModel *selection, int row, int col, ETableItem *eti
view_row = model_to_view_row(eti, row);
view_col = model_to_view_col(eti, col);
+ if (eti->old_cursor_row != -1 && view_row != eti->old_cursor_row)
+ e_table_item_redraw_row (eti, eti->old_cursor_row);
+
if (view_row == -1 || view_col == -1) {
e_table_item_leave_edit_(eti);
eti->old_cursor_row = -1;
@@ -3007,13 +3011,9 @@ eti_cursor_change (ESelectionModel *selection, int row, int col, ETableItem *eti
e_table_item_leave_edit_(eti);
gtk_signal_emit (GTK_OBJECT (eti), eti_signals [CURSOR_CHANGE],
view_row);
- if (eti->old_cursor_row != -1) {
- e_table_item_redraw_row (eti, eti->old_cursor_row);
- e_table_item_redraw_row (eti, view_row);
- } else {
- eti->needs_redraw = TRUE;
- gnome_canvas_item_request_update(GNOME_CANVAS_ITEM(eti));
- }
+
+ e_table_item_redraw_row (eti, view_row);
+
eti->old_cursor_row = view_row;
}