aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table
diff options
context:
space:
mode:
authorEttore Perazzoli <ettore@src.gnome.org>2002-03-15 03:18:39 +0800
committerEttore Perazzoli <ettore@src.gnome.org>2002-03-15 03:18:39 +0800
commit87c61411fad4f9f2b14513b3642b5d9a82932703 (patch)
treed89a14db339f33ee883dc4ba2942aa10a5657a20 /widgets/table
parent5d1e1280e55cc1047b719db9b488d0cfeb3bba04 (diff)
downloadgsoc2013-evolution-87c61411fad4f9f2b14513b3642b5d9a82932703.tar
gsoc2013-evolution-87c61411fad4f9f2b14513b3642b5d9a82932703.tar.gz
gsoc2013-evolution-87c61411fad4f9f2b14513b3642b5d9a82932703.tar.bz2
gsoc2013-evolution-87c61411fad4f9f2b14513b3642b5d9a82932703.tar.lz
gsoc2013-evolution-87c61411fad4f9f2b14513b3642b5d9a82932703.tar.xz
gsoc2013-evolution-87c61411fad4f9f2b14513b3642b5d9a82932703.tar.zst
gsoc2013-evolution-87c61411fad4f9f2b14513b3642b5d9a82932703.zip
Don't search if any modifier but SHIFT or LOCK is pressed.
* e-tree.c (item_key_press): Don't search if any modifier but SHIFT or LOCK is pressed. * e-table.c (group_key_press): Don't search if any modifier but SHIFT or LOCK is pressed. svn path=/trunk/; revision=16161
Diffstat (limited to 'widgets/table')
-rw-r--r--widgets/table/e-table.c7
-rw-r--r--widgets/table/e-tree.c3
2 files changed, 6 insertions, 4 deletions
diff --git a/widgets/table/e-table.c b/widgets/table/e-table.c
index a12350da1f..50d0d12e3b 100644
--- a/widgets/table/e-table.c
+++ b/widgets/table/e-table.c
@@ -757,9 +757,10 @@ group_key_press (ETableGroup *etg, int row, int col, GdkEvent *event, ETable *et
e_table_search_backspace (et->search);
break;
default:
- if ((key->keyval >= GDK_a && key->keyval <= GDK_z) ||
- (key->keyval >= GDK_A && key->keyval <= GDK_Z) ||
- (key->keyval >= GDK_0 && key->keyval <= GDK_9)) {
+ if ((key->state & ~(GDK_SHIFT_MASK | GDK_LOCK_MASK)) == 0
+ && ((key->keyval >= GDK_a && key->keyval <= GDK_z) ||
+ (key->keyval >= GDK_A && key->keyval <= GDK_Z) ||
+ (key->keyval >= GDK_0 && key->keyval <= GDK_9))) {
e_table_search_input_character (et->search, key->keyval);
}
gtk_signal_emit (GTK_OBJECT (et),
diff --git a/widgets/table/e-tree.c b/widgets/table/e-tree.c
index aee7061f7a..38133b7e56 100644
--- a/widgets/table/e-tree.c
+++ b/widgets/table/e-tree.c
@@ -861,7 +861,8 @@ item_key_press (ETableItem *eti, int row, int col, GdkEvent *event, ETree *et)
e_table_search_backspace (et->priv->search);
break;
default:
- if ((key->keyval >= GDK_a && key->keyval <= GDK_z) ||
+ if ((key->state & ~(GDK_SHIFT_MASK | GDK_LOCK_MASK)) == 0
+ && (key->keyval >= GDK_a && key->keyval <= GDK_z) ||
(key->keyval >= GDK_A && key->keyval <= GDK_Z) ||
(key->keyval >= GDK_0 && key->keyval <= GDK_9)) {
e_table_search_input_character (et->priv->search, key->keyval);