Commit-ID: b66ecd97c1866f9a869643a5b69a984d5ce8f8f1 Gitweb: http://git.kernel.org/tip/b66ecd97c1866f9a869643a5b69a984d5ce8f8f1 Author: Arnaldo Carvalho de Melo <acme@xxxxxxxxxx> AuthorDate: Thu, 15 Jul 2010 07:24:30 -0300 Committer: Arnaldo Carvalho de Melo <acme@xxxxxxxxxx> CommitDate: Sat, 17 Jul 2010 15:44:57 -0300 perf ui: Make ui_browser__run exit on unhandled hot keys Right now ENTER doesn't always exits the newt tree widget, as it is used for expanding/collapsing branches, but with the new tree widget being developed we need to regain control to handle it, expanding/collapsing branches. In fact its really up to the ui_browser user to state what extra keys should stop ui_browser__run, and it should handle just the ones needed for basic browsing. Cc: Frederic Weisbecker <fweisbec@xxxxxxxxx> Cc: Mike Galbraith <efault@xxxxxx> Cc: Peter Zijlstra <peterz@xxxxxxxxxxxxx> Cc: Stephane Eranian <eranian@xxxxxxxxxx> Signed-off-by: Arnaldo Carvalho de Melo <acme@xxxxxxxxxx> --- tools/perf/util/newt.c | 6 +----- 1 files changed, 1 insertions(+), 5 deletions(-) diff --git a/tools/perf/util/newt.c b/tools/perf/util/newt.c index 932f124..7979003 100644 --- a/tools/perf/util/newt.c +++ b/tools/perf/util/newt.c @@ -498,12 +498,8 @@ static int ui_browser__run(struct ui_browser *self, struct newtExitStruct *es) self->first_visible_entry_idx = self->index - offset; self->seek(self, -offset, SEEK_END); break; - case NEWT_KEY_RIGHT: - case NEWT_KEY_LEFT: - case NEWT_KEY_TAB: - return es->u.key; default: - continue; + return es->u.key; } if (ui_browser__refresh_entries(self) < 0) return -1; -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html