00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #ifndef __COMPONENT_H
00019 #define __COMPONENT_H
00020
00021 #ifdef __cplusplus
00022 extern "C"
00023 {
00024 #include "common/ktypes.h"
00025 #include "common/stdlib.h"
00026 #include "gui/graphics.h"
00027 #include "common/string.h"
00028 }
00029 #else
00030 #include "common/ktypes.h"
00031 #include "common/stdlib.h"
00032 #include "gui/graphics.h"
00033 #include "common/string.h"
00034 #endif
00035
00036 #define WIND_TYPE 1
00037 #define FRM_TYPE 2
00038
00039
00040 #define DISABLED 1
00041
00042
00043
00044 #define BUT_TYPE 1
00045 #define TEXT_TYPE 2
00046 #define TEXTAREA_TYPE 3
00047 #define LABEL_TYPE 4
00048 #define SCROLLBAR 5
00049 #define FOLDERVIEW_TYPE 20
00050
00051 #define BORDER_WIDTH 2
00052 #define BORDER_HEIGHT 2
00053 #define TITLE_HEIGHT 20
00054
00055 #define ST_SHIFT 0x1
00056 #define ST_CAPS (0x1<<1)
00057 #define ST_CNTL (0x1<<2)
00058 #define ST_ALT (0x1<<3)
00059
00060
00061 class component
00062 {
00063 public:
00064 DW type;
00065 DW id, parent_id,alias_id;
00066 DW x, y, width, height;
00067 void *cnt_ptr;
00068 DB cnt_type;
00069 DD style;
00070
00071 void comp_init(DW _type,DW _id,DW _parent_id,DW _cnt_type,void *_cnt_ptr,DW _alias_id,DW _x,DW _y,DW _width,DW _height,DD _style);
00072 void activate();
00073 void deactivate();
00074 };
00075
00076 #endif