perf ui browser: Fixup cleaning unused lines at the bottom

Now that we can have extra title lines we should use ui_browser->rows
and not ->height when drawing lines, as well as adding
ui_browser->extra_title_lines to browser->y when cleaning unused lines
at the bottom, otherwise we end up clobbering with spaces the last line
just shown by ui_browser->refresh() routine.

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jin Yao <yao.jin@linux.intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Wang Nan <wangnan0@huawei.com>
Fixes: ef9ff601 ("perf ui browser: Move the extra title lines from the hists browser")
Link: https://lkml.kernel.org/n/tip-dfcpokt1pm5ixm8n9pxwtstz@git.kernel.orgSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent e726c851
...@@ -343,8 +343,8 @@ static int __ui_browser__refresh(struct ui_browser *browser) ...@@ -343,8 +343,8 @@ static int __ui_browser__refresh(struct ui_browser *browser)
else else
width += 1; width += 1;
SLsmg_fill_region(browser->y + row, browser->x, SLsmg_fill_region(browser->y + row + browser->extra_title_lines, browser->x,
browser->height - row, width, ' '); browser->rows - row, width, ' ');
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment