/* $Id: keyconfigwindow.hpp,v 1.4 2005/12/18 14:43:44 chfreund Exp $ */ #ifndef _KEYCONFIGWINDOW_HPP_ #define _KEYCONFIGWINDOW_HPP_ #include #include #include "action.h" #include "widget.h" #include "button.h" #include "wopwindow.hpp" class KeyboardConfig; using namespace SDLwidgets; class KeyConfigWindow : public WopWindow, public ActionListener, public ActionWidget { public: enum Action { BACK_PRESSED }; private: std::vector m_labels; std::vector m_values; KeyboardConfig* m_config; WidgetComposite* m_mainContainer; WidgetComposite* m_columnContainer; WidgetComposite* m_container1; WidgetComposite* m_container2; TextButton* m_backButton; int m_selectedKeyIndex; SDL_Color m_normalColor; SDL_Color m_highlightColor; int m_keyFontSize; public: KeyConfigWindow( KeyboardConfig* config, Uint32 width, Uint32 height ); ~KeyConfigWindow() { } void actionPerformed( Uint32 cmd, void* source ); bool handleEvent( SDL_Event* event ); void updateKeys(); private: void addKeys(); }; #endif // _KEYCONFIGWINDOW_HPP_