perf top: Move toggling event logic into hists browser
authorNamhyung Kim <namhyung@kernel.org>
Sun, 21 Jun 2015 03:41:16 +0000 (12:41 +0900)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 22 Jun 2015 14:21:11 +0000 (11:21 -0300)
commit13d1e536b14ec2d404319a25e681a3287ca084ad
treecf7cc84f01311c333525b0fda2cad1610a59219d
parenta9a3cd900fbbcbf837d65653105e7bfc583ced09
perf top: Move toggling event logic into hists browser

Current 'f' key action to enable/disable events won't work if there're
more than one event since perf_evsel_menu__run() doesn't return the key.
So move it to the hists browser loop so that it can be processed as like
other key action, and it's more natural to handle it there IMHO.

Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1434858076-6533-1-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-top.c
tools/perf/ui/browsers/hists.c