00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef _STATUSBAR_H
00023 #define _STATUSBAR_H
00024
00025 #ifdef HAVE_CONFIG_H
00026 # include <config.h>
00027 #endif
00028
00029 #ifdef HAVE_NCURSES_H
00030 # include <ncurses.h>
00031 #else // HAVE_NCURSES_H
00032 # ifdef HAVE_CURSES_H
00033 # include <curses.h>
00034 # else
00035 # error "Neither curses.h nor ncurses.h available"
00036 # endif // HAVE_CURSES_H
00037 #endif // HAVE_NCURSES_H
00038 #include "curswa.h"
00039
00040 #ifdef HAVE_STRING
00041 # include <string>
00042 #endif
00043
00044 #include "basewindow.h"
00045 #include "uiexception.h"
00046
00054 class StatusBar : protected YAPETUI::BaseWindow {
00055 private:
00056 WINDOW* statusbar;
00057 std::string message;
00058
00059 inline StatusBar(const StatusBar&) {}
00060 inline const StatusBar& operator=(const StatusBar&) { return *this; }
00061
00062 protected:
00063 void createWindow() throw(YAPETUI::UIException);
00064
00065 public:
00066 StatusBar() throw(YAPETUI::UIException);
00067 virtual ~StatusBar();
00068
00069 void putMsg(std::string msg) throw(YAPETUI::UIException);
00070 std::string getMsg() const { return message; }
00071 void refresh();
00072
00073 void resize();
00074 };
00075
00076 #endif // _STATUSBAR_H