mtimer.h
Go to the documentation of this file.00001
00016 #ifndef _MGUI_NCSCTRL_TIMER_H
00017 #define _MGUI_NCSCTRL_TIMER_H
00018
00019 #ifdef __cplusplus
00020 extern "C"{
00021 #endif
00022
00032 #define NCSCTRL_TIMER NCSCLASSNAME("timer")
00033
00034 typedef struct _mTimerClass mTimerClass;
00035 typedef struct _mTimer mTimer;
00036
00037 #define mTimerClassHeader(clss, superCls) \
00038 mInvsbCompClassHeader(clss, superCls) \
00039 BOOL (*start)(clss *self); \
00040 void (*stop)(clss *self); \
00041 HWND (*getParent)(clss *self);
00042
00061 struct _mTimerClass {
00062 mTimerClassHeader(mTimer, mInvsbComp)
00063 };
00064
00069 MGNCS_EXPORT extern mTimerClass g_stmTimerCls;
00070
00071 #define mTimerHeader(clss) \
00072 mInvsbCompHeader(clss) \
00073 DWORD interval;
00074
00083 struct _mTimer {
00084 mTimerHeader(mTimer)
00085 };
00086
00091 enum ncsTimerProp {
00092 NCSP_TIMER_INTERVAL = NCSP_IVCMPT_MAX + 1,
00093 NCSP_TIMER_MAX
00094 };
00112 typedef BOOL (*NCS_CB_ONTIMER)(mTimer* timer, DWORD total_count);
00113
00116 #ifdef __cplusplus
00117 }
00118 #endif
00119
00120 #endif
00121