00001
00002
00003
00004
00005
00006 #ifndef CHECK_BOX_H_133040844
00007 #define CHECK_BOX_H_133040844
00008 #include "base_control.h"
00009 #include "events.h"
00010 #include <string>
00011
00012 namespace crs {
00013
00014 class check_events: public window_events {
00015
00016 };
00017
00018 class check_box: public focused_ctrl, public styled_ctrl {
00019 private:
00020 bool mChecked;
00021 std::string mCaption;
00022 const bool &getChecked();
00023 void setChecked( const bool &Checked );
00024 public:
00025 check_box( base_control *Parent, check_events *Events, const std::string Caption, const bool Checked,
00026 const unsigned int Left, const unsigned int Top, const unsigned int Width,
00027 style::styles Style = style::rect, chtype clb='[', chtype crb=']' );
00028 virtual void draw();
00029 virtual bool keyPress( const int key );
00030 property< check_box, read_write, bool > checked;
00031 };
00032
00033 }
00034
00035 #endif
00036