aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@ximian.com>2001-10-07 01:43:47 +0800
committerChris Lahey <clahey@src.gnome.org>2001-10-07 01:43:47 +0800
commit90daf11b95d56e9100f5b5fcaaeb42494ed83e5f (patch)
treee25f5d871ef954f736b3830cd9358424c03401ad /widgets/table
parent3b74bfce983c7dd121bd2a66c2b760dee0ee1625 (diff)
downloadgsoc2013-evolution-90daf11b95d56e9100f5b5fcaaeb42494ed83e5f.tar
gsoc2013-evolution-90daf11b95d56e9100f5b5fcaaeb42494ed83e5f.tar.gz
gsoc2013-evolution-90daf11b95d56e9100f5b5fcaaeb42494ed83e5f.tar.bz2
gsoc2013-evolution-90daf11b95d56e9100f5b5fcaaeb42494ed83e5f.tar.lz
gsoc2013-evolution-90daf11b95d56e9100f5b5fcaaeb42494ed83e5f.tar.xz
gsoc2013-evolution-90daf11b95d56e9100f5b5fcaaeb42494ed83e5f.tar.zst
gsoc2013-evolution-90daf11b95d56e9100f5b5fcaaeb42494ed83e5f.zip
Check that cell views are realized before doing anything here. Fixes
2001-10-06 Christopher James Lahey <clahey@ximian.com> * e-table-item.c (eti_show_cursor, eti_check_cursor_bounds): Check that cell views are realized before doing anything here. Fixes Ximian bug #11919. (eti_check_cursor_on_screen): If the cursor values are all set to -1, don't do anything. svn path=/trunk/; revision=13488
Diffstat (limited to 'widgets/table')
-rw-r--r--widgets/table/e-table-item.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/widgets/table/e-table-item.c b/widgets/table/e-table-item.c
index fd51a0407a..dbf4716c5c 100644
--- a/widgets/table/e-table-item.c
+++ b/widgets/table/e-table-item.c
@@ -770,6 +770,9 @@ eti_show_cursor (ETableItem *eti, int delay)
{
int cursor_row;
+ if (!((GTK_OBJECT_FLAGS(eti) & GNOME_CANVAS_ITEM_REALIZED) && eti->cell_views_realized))
+ return;
+
gtk_object_get(GTK_OBJECT(eti->selection),
"cursor_row", &cursor_row,
NULL);
@@ -786,6 +789,12 @@ eti_show_cursor (ETableItem *eti, int delay)
static void
eti_check_cursor_on_screen (ETableItem *eti)
{
+ if (eti->cursor_x1 == -1 ||
+ eti->cursor_y1 == -1 ||
+ eti->cursor_x2 == -1 ||
+ eti->cursor_y2 == -1)
+ return;
+
eti->cursor_on_screen = e_canvas_item_area_shown (GNOME_CANVAS_ITEM(eti),
eti->cursor_x1,
eti->cursor_y1,
@@ -800,6 +809,9 @@ eti_check_cursor_bounds (ETableItem *eti)
{
int x1, y1, x2, y2;
int cursor_row;
+
+ if (!((GTK_OBJECT_FLAGS(eti) & GNOME_CANVAS_ITEM_REALIZED) && eti->cell_views_realized))
+ return;
gtk_object_get(GTK_OBJECT(eti->selection),
"cursor_row", &cursor_row,