aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/ui/browser.h
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2011-10-13 07:52:46 -0400
committerArnaldo Carvalho de Melo <acme@redhat.com>2011-10-13 07:52:46 -0400
commit3af6e33867b3814a73c3f3ba991a13d7304ad23a (patch)
tree28f0f4071736faca07252439a0037e27f0895a53 /tools/perf/util/ui/browser.h
parent33e27312aeb05798572ccc456a76321125e8d7cb (diff)
perf ui browser: Handle SIGWINCH
To do that we needed to stop using newtForm, as we don't want libnewt to catch the xterm resize signal. Remove some more newt calls and instead use the underlying libslang directly. In time tools/perf will use just libslang. Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/n/tip-h1824yjiru5n2ivz4bseizwj@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/ui/browser.h')
-rw-r--r--tools/perf/util/ui/browser.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/perf/util/ui/browser.h b/tools/perf/util/ui/browser.h
index d42be43ac0e8..37d56bfe8fe3 100644
--- a/tools/perf/util/ui/browser.h
+++ b/tools/perf/util/ui/browser.h
@@ -2,7 +2,6 @@
2#define _PERF_UI_BROWSER_H_ 1 2#define _PERF_UI_BROWSER_H_ 1
3 3
4#include <stdbool.h> 4#include <stdbool.h>
5#include <newt.h>
6#include <sys/types.h> 5#include <sys/types.h>
7#include "../types.h" 6#include "../types.h"
8 7
@@ -13,11 +12,12 @@
13#define HE_COLORSET_CODE 54 12#define HE_COLORSET_CODE 54
14 13
15struct ui_browser { 14struct ui_browser {
16 newtComponent form, sb;
17 u64 index, top_idx; 15 u64 index, top_idx;
18 void *top, *entries; 16 void *top, *entries;
19 u16 y, x, width, height; 17 u16 y, x, width, height;
20 void *priv; 18 void *priv;
19 const char *title;
20 char *helpline;
21 unsigned int (*refresh)(struct ui_browser *self); 21 unsigned int (*refresh)(struct ui_browser *self);
22 void (*write)(struct ui_browser *self, void *entry, int row); 22 void (*write)(struct ui_browser *self, void *entry, int row);
23 void (*seek)(struct ui_browser *self, off_t offset, int whence); 23 void (*seek)(struct ui_browser *self, off_t offset, int whence);
@@ -40,7 +40,7 @@ int ui_browser__show(struct ui_browser *self, const char *title,
40 const char *helpline, ...); 40 const char *helpline, ...);
41void ui_browser__hide(struct ui_browser *self); 41void ui_browser__hide(struct ui_browser *self);
42int ui_browser__refresh(struct ui_browser *self); 42int ui_browser__refresh(struct ui_browser *self);
43int ui_browser__run(struct ui_browser *self); 43int ui_browser__run(struct ui_browser *browser, int delay_secs);
44void ui_browser__update_nr_entries(struct ui_browser *browser, u32 nr_entries); 44void ui_browser__update_nr_entries(struct ui_browser *browser, u32 nr_entries);
45 45
46void ui_browser__rb_tree_seek(struct ui_browser *self, off_t offset, int whence); 46void ui_browser__rb_tree_seek(struct ui_browser *self, off_t offset, int whence);