aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table/e-table-item.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@ximian.com>2001-04-13 08:40:49 +0800
committerChris Lahey <clahey@src.gnome.org>2001-04-13 08:40:49 +0800
commit0f85f30ab1145a7ed3c6ee7b2e2216874dc2074f (patch)
tree65b0c7756268decded8c5f5341c85aaaf6476d8e /widgets/table/e-table-item.c
parenta4f57fbbde67f1423a741b898d51773310a8c696 (diff)
downloadgsoc2013-evolution-0f85f30ab1145a7ed3c6ee7b2e2216874dc2074f.tar.gz
gsoc2013-evolution-0f85f30ab1145a7ed3c6ee7b2e2216874dc2074f.tar.zst
gsoc2013-evolution-0f85f30ab1145a7ed3c6ee7b2e2216874dc2074f.zip
Upped the version number to 0.6.99.0. Upped the so number to 6.
2001-04-12 Christopher James Lahey <clahey@ximian.com> * configure.in: Upped the version number to 0.6.99.0. Upped the so number to 6. * docs/etablexml.txt: Made some updates here. * tests/test-tree-1.c, tests/test-tree-3.c: Added NULL, NULL to the call to e_tree_memory_callbacks_new. From gal/e-table/ChangeLog: 2001-04-12 Christopher James Lahey <clahey@ximian.com> * e-table-item.c (eti_cursor_change): Only move the screen to show the cursor if there are no changes pending. Updated the commented out code for alternating colors a bit. * e-table-model.c, e-table-model.h: Added e_table_model_has_change_pending. * e-tree-memory-callbacks.c, e-tree-memory-callbacks.h: Added has_get_node_by_id and get_node_by_id. * e-tree-model.c, e-tree-model.h: Added e_tree_model_has_get_node_by_id and e_tree_model_get_node_by_id. Added e_tree_model_has_change_pending. * e-tree-selection-model.c: Handle the selection and cursor properly across the tree changing. * e-tree-sorted.c: Implemented has_get_node_by_id and get_node_by_id, and has_changes_pending. * e-tree-table-adapter.c: Implemented has_changes_pending. Fixed an array underflow. svn path=/trunk/; revision=9289
Diffstat (limited to 'widgets/table/e-table-item.c')
-rw-r--r--widgets/table/e-table-item.c28
1 files changed, 21 insertions, 7 deletions
diff --git a/widgets/table/e-table-item.c b/widgets/table/e-table-item.c
index c11a41712e..8f2cee1b20 100644
--- a/widgets/table/e-table-item.c
+++ b/widgets/table/e-table-item.c
@@ -1237,7 +1237,6 @@ eti_draw (GnomeCanvasItem *item, GdkDrawable *drawable, int x, int y, int width,
double i2c [6];
ArtPoint eti_base, eti_base_item, lower_right;
GtkWidget *canvas = GTK_WIDGET(item->canvas);
- GdkColor *background;
int height_extra = eti->horizontal_draw_grid ? 1 : 0;
/*
@@ -1352,6 +1351,9 @@ eti_draw (GnomeCanvasItem *item, GdkDrawable *drawable, int x, int y, int width,
ECellView *ecell_view = eti->cell_views [col];
gboolean col_selected = selected;
ECellFlags flags;
+ gboolean free_background = FALSE;
+ GdkColor *background;
+
switch (eti->cursor_mode) {
case E_CURSOR_SIMPLE:
case E_CURSOR_SPREADSHEET:
@@ -1374,8 +1376,15 @@ eti_draw (GnomeCanvasItem *item, GdkDrawable *drawable, int x, int y, int width,
#endif
background = &canvas->style->base [GTK_STATE_NORMAL];
#if 0
- else
- background = &canvas->style->base [GTK_STATE_SELECTED];
+ else {
+ free_background = TRUE;
+ background = gdk_color_copy (&canvas->style->base [GTK_STATE_NORMAL]);
+ background->red -= 25000;
+ background->green += 25000;
+ background->blue -= 25000;
+
+ gdk_color_alloc (gtk_widget_get_colormap (GTK_WIDGET (canvas)), background);
+ }
#endif
}
@@ -1383,6 +1392,9 @@ eti_draw (GnomeCanvasItem *item, GdkDrawable *drawable, int x, int y, int width,
gdk_draw_rectangle (drawable, eti->fill_gc, TRUE,
xd, yd, ecol->width, height);
+ if (free_background)
+ gdk_color_free (background);
+
flags = col_selected ? E_CELL_SELECTED : 0;
flags |= GTK_WIDGET_HAS_FOCUS(canvas) ? E_CELL_FOCUSED : 0;
switch (ecol->justification) {
@@ -2274,10 +2286,12 @@ eti_cursor_change (ESelectionModel *selection, int row, int col, ETableItem *eti
return;
}
- if (!eti->in_key_press) {
- eti_request_region_show (eti, view_col, view_row, view_col, view_row, DOUBLE_CLICK_TIME + 10);
- } else {
- eti_request_region_show (eti, view_col, view_row, view_col, view_row, 0);
+ if (! e_table_model_has_change_pending (eti->table_model)) {
+ if (!eti->in_key_press) {
+ eti_request_region_show (eti, view_col, view_row, view_col, view_row, DOUBLE_CLICK_TIME + 10);
+ } else {
+ eti_request_region_show (eti, view_col, view_row, view_col, view_row, 0);
+ }
}
e_canvas_item_grab_focus(GNOME_CANVAS_ITEM(eti), FALSE);