diff options
author | 2013-01-18 22:08:23 +0100 | |
---|---|---|
committer | 2013-01-18 22:08:23 +0100 | |
commit | 81cc5f4805643d9e56d973c1468a166513d5c01a (patch) | |
tree | 27caa28e3c84a220c2c87e5fa4cb31fc3faddf07 /ufed-curses.h | |
parent | Fixed Scrollbar, the determination where the first not masked flag (diff) | |
download | ufed-81cc5f4805643d9e56d973c1468a166513d5c01a.tar.gz ufed-81cc5f4805643d9e56d973c1468a166513d5c01a.tar.bz2 ufed-81cc5f4805643d9e56d973c1468a166513d5c01a.zip |
Added knowledge about instaled packages. Further split the internal
representation fro all-in-one to separate description and package
lists for each flag and description.
Currently the packages are not displayed, this has to be added next.
Diffstat (limited to 'ufed-curses.h')
-rw-r--r-- | ufed-curses.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/ufed-curses.h b/ufed-curses.h index 81ee779..fee9e67 100644 --- a/ufed-curses.h +++ b/ufed-curses.h @@ -4,6 +4,29 @@ #include <curses.h> + +#define DEBUG_EXIT 1 +#define DEBUG_TRACE 1 + +#if defined(DEBUG_EXIT) +# define ERROR_EXIT(code, fmt, ...) { \ + fprintf(stderr, "ERROR in %s:%d (%s): \n -> ", \ + __FILE__, __LINE__, __FUNCTION__); \ + fprintf(stderr, fmt, __VA_ARGS__); \ + exit(code); \ +} +#else +# define ERROR_EXIT(code, ...) { exit(code); } +#endif // DEBUG_EXIT +#if defined(DEBUG_TRACE) +# define TRACE { \ + fprintf(stderr, "(TRACE) %s:%d - %s\n", __FILE__, __LINE__, __FUNCTION__); \ +} +#else +# define TRACE +#endif // DEBUG_TRACE + + enum win { Top, Left, List, Input, Scrollbar, Right, Bottom, wCount }; enum mask { show_unmasked, show_both, show_masked }; |