00001 #ifndef _RADIO_BUTTON_H_ 00002 #define _RADIO_BUTTON_H_ 00003 00004 #include <nds.h> 00005 #include "button.h" 00006 00007 namespace WoopsiUI { 00008 00009 class RadioButtonGroup; 00010 00018 class RadioButton : public Button { 00019 00020 public: 00024 enum RadioButtonState { 00025 RADIO_BUTTON_STATE_OFF = 0, 00026 RADIO_BUTTON_STATE_ON = 1, 00027 RADIO_BUTTON_STATE_MU = 2 00028 }; 00029 00038 RadioButton(s16 x, s16 y, u16 width, u16 height, FontBase* font = NULL); 00039 00046 virtual void draw(Rect clipRect); 00047 00054 virtual bool click(s16 x, s16 y); 00055 00060 virtual inline RadioButtonState getState() { return _state; } 00061 00066 virtual void setState(RadioButtonState state); 00067 00068 protected: 00069 RadioButtonState _state; 00074 virtual inline ~RadioButton() { }; 00075 00079 inline RadioButton(const RadioButton& radioButton) : Button(radioButton) { }; 00080 }; 00081 } 00082 00083 #endif