42 #ifndef _MGUI_NCSCTRL_ASTLST_H 43 #define _MGUI_NCSCTRL_ASTLST_H 71 #define NCSS_ASTLST_AUTOSORT (0x0001<<NCSS_SWGT_SHIFT) 77 #define NCSS_ASTLST_SHIFT (NCSS_SWGT_SHIFT+1) 79 static inline int _ncs_defcmp_node(
mNode *node1,
mNode *node2)
81 const char* str1 =
_c(node1)->getText(node1);
82 const char* str2 =
_c(node2)->getText(node2);
84 return strcasecmp(str1, str2);
87 #define mAbstractListHeader(clsName)\ 88 mScrollWidgetHeader(clsName) \ 89 NCS_CB_CMPNODE nodeCmp; \ 111 struct _mAbstractList
116 #define mAbstractListClassHeader(clsName, superCls) \ 117 mScrollWidgetClassHeader(clsName, superCls) \ 118 int (*addNode)(clsName*, mNode *node); \ 119 int (*insertNode)(clsName*, mNode *node, mNode *prev,mNode *next, int index);\ 120 int (*removeNode)(clsName*, mNode *node); \ 121 mNode* (*getNode)(clsName*, int index); \ 122 int (*indexOf)(clsName*, mNode *node); \ 123 BOOL (*isFrozen)(clsName*); \ 124 BOOL (*showNode)(clsName*, mNode *node); \ 125 void (*refreshNode)(clsName*, mNode *node, const RECT *rcInv); \ 126 mNode* (*findNode)(clsName*, DWORD info, int type, BOOL recursion, int startIndex); \ 128 BOOL (*setCurSel)(clsName*, int index); \ 129 mNode* (*getCurSel)(clsName*); \ 130 BOOL (*selectNode)(clsName*, mNode *node, BOOL select); \ 132 int (*getRect)(clsName*, mNode *node, RECT *rcNode, BOOL bConv); \ 133 void (*freeze)(clsName*, BOOL locked); \ 134 void (*sortNodes)(clsName*, NCS_CB_CMPNODE func, mNode *parentNode);\ 135 void (*notifyEvent)(clsName*, int eventId, DWORD eventInfo); 213 struct _mAbstractListClass
218 #define mAbstractListRendererHeader(clsName, parentClass) \ 219 mScrollWidgetRendererHeader(clsName, parentClass) 226 struct _mAbstractListRenderer {
278 NCSP_ASTLST_TEXTINDENT,
280 NCSP_ASTLST_IMAGEINDENT,
The virtual function table of mAbstractList, which derived from mScrollWidgetClass.
#define _c(ths)
the marco get the class of a object
The structure of mNode. It is the basic class of all nodes occur within specific controls. For example, a list can contain it.
The structure of mAbstractList renderer, which inheried from mScrollWidgetRenderer.
The structure of mAbstractList, which derived from mScrollWidget. It is the abstract superclass of al...