42 #ifndef _MGUI_CTRL_ITEMMANAGER_H 43 #define _MGUI_CTRL_ITEMMANAGER_H 55 typedef struct _mItemManagerRenderer mItemManagerRenderer;
74 typedef int (*
NCS_CB_CMPSTR) (
const char* s1,
const char* s2,
size_t n);
80 #define NCSF_ITMMNG_AUTOSORT (0x01<<NCSF_ITEM_SHIFT) 86 #define NCSF_ITMMNG_FROZEN (0x02<<NCSF_ITEM_SHIFT) 92 #define NCSF_ITMMNG_SHIFT (NCSF_ITEM_SHIFT+2) 95 #define mItemManagerHeader(className) \ 96 mItemHeader(className) \ 97 NCS_CB_CMPITEM itemCmp; \ 101 HITEM pItemHilighted; \ 104 NCS_CB_CMPSTR strCmp; 140 #define mItemManagerClassHeader(clsName, superCls) \ 141 mItemClassHeader(clsName, superCls) \ 142 NCS_CB_CMPITEM (*setItemCmpFunc)(clsName*, NCS_CB_CMPITEM func); \ 143 int (*moveItem)(clsName*, mItem *curItem, int count, mItem* prevItem); \ 144 int (*insertItem)(clsName*, HITEM hItem, HITEM prev, HITEM next, int index, int *pos); \ 145 HITEM (*createItem)(clsName*, HITEM prev, HITEM next, int index, int *pos); \ 146 int (*inItem)(clsName*, int mouseX, int mouseY, HITEM *pRet, POINT *pt); \ 147 NCS_CB_CMPSTR (*setStrCmpFunc)(clsName*, NCS_CB_CMPSTR func); \ 148 NCS_CB_CMPSTR (*getStrCmpFunc)(clsName*); \ 149 int (*getItemYPos)(clsName*, HITEM hItem); \ 150 void (*setAutoSortItem) (clsName*, BOOL sort); \ 151 int (*getTotalHeight)(clsName*); \ 152 int (*adjustItemsHeight)(clsName*, int diff); \ 153 BOOL (*freeze)(clsName*, BOOL lock); \ 154 BOOL (*isFrozen)(clsName*); \ 155 HITEM (*getFirstItem)(clsName*); \ 156 list_t* (*getQueue)(clsName*); \ 157 HITEM (*getListEntry)(list_t* entry); \ 158 int (*isEmpty)(clsName*); \ 159 int (*removeItem)(clsName*, HITEM hItem); \ 160 int (*sortItems)(clsName*, NCS_CB_CMPITEM pfn); \ 161 BOOL (*removeAll)(clsName*); \ 162 int (*indexOf)(clsName*, HITEM hItem); \ 163 int (*setHeight)(clsName*, HITEM hItem, int height); \ 164 int (*getHeight)(clsName*, HITEM hItem); \ 165 HITEM (*getItem)(clsName*, int index); \ 166 HITEM (*getNext)(clsName*, HITEM hItem); \ 167 HITEM (*getPrev)(clsName*, HITEM hItem); \ 168 BOOL (*isSelected)(clsName*, HITEM hItem); \ 169 BOOL (*isEnabled)(clsName*, HITEM hItem); \ 170 BOOL (*enable)(clsName*, HITEM hItem, BOOL enable); \ 171 void (*selectAll)(clsName*); \ 172 void (*deselectAll)(clsName*); \ 173 BOOL (*select)(clsName*, HITEM hItem, BOOL sel); \ 174 HITEM (*hilight)(clsName*, HITEM hItem); \ 175 HITEM (*getHilight)(clsName*); \ 176 BOOL (*isHilight)(clsName*, HITEM hItem); \ 177 int (*getItemCount)(clsName*); \ 178 void (*setAddData)(clsName*, HITEM hItem, DWORD addData); \ 179 void (*setImage)(clsName*, HITEM hItem, DWORD image); \ 180 DWORD (*getAddData)(clsName*, HITEM hItem); \ 181 DWORD (*getImage)(clsName*, HITEM hItem); \ 182 void (*setFlags)(clsName*, HITEM hItem, DWORD flags); \ 183 DWORD (*getFlags)(clsName*, HITEM hItem); \ 184 BOOL (*setText)(clsName*, HITEM hItem, const char* text); \ 185 const char* (*getText)(clsName*, HITEM hItem); \ 186 int (*getTextLen)(clsName*, HITEM hItem); \ 187 BOOL (*getSelection)(clsName*, HITEM *pRet, int count); \ 188 int (*getSelectionCount)(clsName*); 403 struct _mItemManagerClass
The structure of mItem. It is the abstract superclass of all items occur within specific controls...
The virtual function table of mItemManager, which derived from mItemClass.
The structure of mItemManager control, which derived from mItem. It is the abstract superclass of all...