![Arnaldo Carvalho de Melo](/assets/img/avatar_default.png)
To remove direct access to libslang functions, with the immediate goal of implementing horizontal scrolling at the ui_browser level, but also because we may at some point want to implement ui_browser with other UIs in addition to the current libslang implementation. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Borislav Petkov <bp@suse.de> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/n/tip-w0niblabqrkecs4o0eogfy6c@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
33 lines
928 B
C
33 lines
928 B
C
#ifndef _PERF_UI_SLANG_H_
|
|
#define _PERF_UI_SLANG_H_ 1
|
|
/*
|
|
* slang versions <= 2.0.6 have a "#if HAVE_LONG_LONG" that breaks
|
|
* the build if it isn't defined. Use the equivalent one that glibc
|
|
* has on features.h.
|
|
*/
|
|
#include <features.h>
|
|
#ifndef HAVE_LONG_LONG
|
|
#define HAVE_LONG_LONG __GLIBC_HAVE_LONG_LONG
|
|
#endif
|
|
#include <slang.h>
|
|
|
|
#if SLANG_VERSION < 20104
|
|
#define slsmg_printf(msg, args...) \
|
|
SLsmg_printf((char *)(msg), ##args)
|
|
#define slsmg_vprintf(msg, vargs) \
|
|
SLsmg_vprintf((char *)(msg), vargs)
|
|
#define slsmg_write_nstring(msg, len) \
|
|
SLsmg_write_nstring((char *)(msg), len)
|
|
#define sltt_set_color(obj, name, fg, bg) \
|
|
SLtt_set_color(obj,(char *)(name), (char *)(fg), (char *)(bg))
|
|
#else
|
|
#define slsmg_printf SLsmg_printf
|
|
#define slsmg_vprintf SLsmg_vprintf
|
|
#define slsmg_write_nstring SLsmg_write_nstring
|
|
#define sltt_set_color SLtt_set_color
|
|
#endif
|
|
|
|
#define SL_KEY_UNTAB 0x1000
|
|
|
|
#endif /* _PERF_UI_SLANG_H_ */
|