aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@ximian.com>2001-03-25 16:10:23 +0800
committerChris Lahey <clahey@src.gnome.org>2001-03-25 16:10:23 +0800
commit2ed07fe856571d969c17c944e1fdb16740252b95 (patch)
tree94f9ff527bf8fd9cb61259cb7bdf48e5e7dfac64 /widgets/table
parent0f80005685978681896ccf1df105a74c217a1efc (diff)
downloadgsoc2013-evolution-2ed07fe856571d969c17c944e1fdb16740252b95.tar.gz
gsoc2013-evolution-2ed07fe856571d969c17c944e1fdb16740252b95.tar.zst
gsoc2013-evolution-2ed07fe856571d969c17c944e1fdb16740252b95.zip
Added '=' and '-' as tree node expand and collapse
2001-03-25 Christopher James Lahey <clahey@ximian.com> * e-tree.c (item_key_press): Added '=' and '-' as tree node expand and collapse svn path=/trunk/; revision=8923
Diffstat (limited to 'widgets/table')
-rw-r--r--widgets/table/e-tree.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/widgets/table/e-tree.c b/widgets/table/e-tree.c
index 5f34e89fee..ba394d3f71 100644
--- a/widgets/table/e-tree.c
+++ b/widgets/table/e-tree.c
@@ -372,11 +372,9 @@ static gint
item_key_press (ETableItem *eti, int row, int col, GdkEvent *event, ETree *et)
{
int return_val = 0;
- ETreePath path = e_tree_table_adapter_node_at_row(et->etta, row);
GdkEventKey *key = (GdkEventKey *) event;
GdkEventButton click;
-
- path = e_tree_sorted_view_to_model_path(et->sorted, path);
+ ETreePath path;
switch (key->keyval) {
case GDK_Page_Down:
@@ -416,7 +414,17 @@ item_key_press (ETableItem *eti, int row, int col, GdkEvent *event, ETree *et)
(GdkEvent *) &click);
return_val = 1;
break;
+ case '=':
+ path = e_tree_table_adapter_node_at_row(et->etta, row);
+ e_tree_table_adapter_node_set_expanded (et->etta, path, TRUE);
+ break;
+ case '-':
+ path = e_tree_table_adapter_node_at_row(et->etta, row);
+ e_tree_table_adapter_node_set_expanded (et->etta, path, FALSE);
+ break;
default:
+ path = e_tree_table_adapter_node_at_row(et->etta, row);
+ path = e_tree_sorted_view_to_model_path(et->sorted, path);
gtk_signal_emit (GTK_OBJECT (et),
et_signals [KEY_PRESS],
row, path, col, event, &return_val);