diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2010-05-16 20:29:38 -0300 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2010-05-16 20:29:38 -0300 |
commit | a308f3a868185d4f804fe71d0400e2b058c6d9af (patch) | |
tree | 2c0ff9d6d0aba272060a453056e9c8cfe5c5dbb3 | |
parent | 9d192e118a094087494997ea1c8a2faf39af38c5 (diff) | |
download | linux-3.10-a308f3a868185d4f804fe71d0400e2b058c6d9af.tar.gz linux-3.10-a308f3a868185d4f804fe71d0400e2b058c6d9af.tar.bz2 linux-3.10-a308f3a868185d4f804fe71d0400e2b058c6d9af.zip |
perf tui: Make <- exit menus too
In fact it is now added to the hot key list when newt_form__new is used,
allowing us to remove the explicit assignment in all its users.
The visible change is that <- will exit the menu that pops up when -> is
pressed (and Enter when callchains are not being used).
Suggested-by: Ingo Molnar <mingo@elte.hu>
Cc: Frédéric Weisbecker <fweisbec@gmail.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Tom Zanussi <tzanussi@gmail.com>
LKML-Reference: <new-submission>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
-rw-r--r-- | tools/perf/util/newt.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/tools/perf/util/newt.c b/tools/perf/util/newt.c index 6974431d212..59a63e4405f 100644 --- a/tools/perf/util/newt.c +++ b/tools/perf/util/newt.c @@ -118,6 +118,7 @@ int browser__show_help(const char *format, va_list ap) static void newt_form__set_exit_keys(newtComponent self) { + newtFormAddHotKey(self, NEWT_KEY_LEFT); newtFormAddHotKey(self, NEWT_KEY_ESCAPE); newtFormAddHotKey(self, 'Q'); newtFormAddHotKey(self, 'q'); @@ -323,7 +324,6 @@ static int ui_browser__run(struct ui_browser *self, const char *title, newtFormAddHotKey(self->form, NEWT_KEY_PGDN); newtFormAddHotKey(self->form, NEWT_KEY_HOME); newtFormAddHotKey(self->form, NEWT_KEY_END); - newtFormAddHotKey(self->form, NEWT_KEY_LEFT); if (ui_browser__refresh_entries(self) < 0) return -1; @@ -757,7 +757,6 @@ static int hist_browser__populate(struct hist_browser *self, struct hists *hists newtFormAddHotKey(self->form, 'T'); newtFormAddHotKey(self->form, 't'); newtFormAddHotKey(self->form, NEWT_KEY_RIGHT); - newtFormAddHotKey(self->form, NEWT_KEY_LEFT); newtFormAddComponents(self->form, self->tree, NULL); self->selection = newt__symbol_tree_get_current(self->tree); |