diff options
Diffstat (limited to 'tools')
-rw-r--r-- | tools/perf/util/ui/browsers/annotate.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/tools/perf/util/ui/browsers/annotate.c b/tools/perf/util/ui/browsers/annotate.c index 295a9c93f945..76caae95df39 100644 --- a/tools/perf/util/ui/browsers/annotate.c +++ b/tools/perf/util/ui/browsers/annotate.c | |||
@@ -69,14 +69,17 @@ static void annotate_browser__write(struct ui_browser *self, void *entry, int ro | |||
69 | if (!self->navkeypressed) | 69 | if (!self->navkeypressed) |
70 | width += 1; | 70 | width += 1; |
71 | 71 | ||
72 | if (!ab->hide_src_code && ol->offset != -1) | ||
73 | if (!current_entry || (self->use_navkeypressed && | ||
74 | !self->navkeypressed)) | ||
75 | ui_browser__set_color(self, HE_COLORSET_CODE); | ||
76 | |||
72 | if (!*ol->line) | 77 | if (!*ol->line) |
73 | slsmg_write_nstring(" ", width - 18); | 78 | slsmg_write_nstring(" ", width - 18); |
74 | else | 79 | else |
75 | slsmg_write_nstring(ol->line, width - 18); | 80 | slsmg_write_nstring(ol->line, width - 18); |
76 | 81 | ||
77 | if (!current_entry) | 82 | if (current_entry) |
78 | ui_browser__set_color(self, HE_COLORSET_CODE); | ||
79 | else | ||
80 | ab->selection = ol; | 83 | ab->selection = ol; |
81 | } | 84 | } |
82 | 85 | ||