aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/ui/browsers/hists.c
diff options
context:
space:
mode:
authorDavid Ahern <dsahern@gmail.com>2011-10-19 13:37:47 -0400
committerArnaldo Carvalho de Melo <acme@redhat.com>2011-10-19 11:31:39 -0400
commite4419b8edb6dead17cbc13a477b953399ee7571c (patch)
tree9b19a005355621f6f9c6003805040b199977272d /tools/perf/util/ui/browsers/hists.c
parentfe46e64c432d355ab1b5245498d9b75f37d71ac3 (diff)
perf hists browser: Do not exit on tab key with single event
TUI help states for multiple event sessions the TAB/UNTAB keys are used to switch events. For single event sessions (e.g., the default) the tab key currently causes the tui to exit. Change that to do nothing since there is not no second event to switch to. Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1319045867-12728-1-git-send-email-dsahern@gmail.com Signed-off-by: David Ahern <dsahern@gmail.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/ui/browsers/hists.c')
-rw-r--r--tools/perf/util/ui/browsers/hists.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/perf/util/ui/browsers/hists.c b/tools/perf/util/ui/browsers/hists.c
index 94e1ab0badb1..d76287513525 100644
--- a/tools/perf/util/ui/browsers/hists.c
+++ b/tools/perf/util/ui/browsers/hists.c
@@ -864,6 +864,8 @@ static int perf_evsel__hists_browse(struct perf_evsel *evsel, int nr_events,
864 switch (key) { 864 switch (key) {
865 case NEWT_KEY_TAB: 865 case NEWT_KEY_TAB:
866 case NEWT_KEY_UNTAB: 866 case NEWT_KEY_UNTAB:
867 if (nr_events == 1)
868 continue;
867 /* 869 /*
868 * Exit the browser, let hists__browser_tree 870 * Exit the browser, let hists__browser_tree
869 * go to the next or previous 871 * go to the next or previous