mGNCS API Reference  v1.5.0
A new control set and a new framework for MiniGUI apps
mscrollview.h
Go to the documentation of this file.
1 //
3 // IMPORTANT NOTICE
4 //
5 // The following open source license statement does not apply to any
6 // entity in the Exception List published by FMSoft.
7 //
8 // For more information, please visit:
9 //
10 // https://www.fmsoft.cn/exception-list
11 //
13 
54 #ifndef _MGUI_CTRL_SCRLV_H
55 #define _MGUI_CTRL_SCRLV_H
56 
57 
58 #ifdef __cplusplus
59 extern "C" {
60 #endif /* __cplusplus */
61 
70 typedef struct _NCS_SCRLV_ITEMINFO
71 {
73  int index;
75  int height;
77  DWORD addData;
79 
80 typedef struct _mScrollView mScrollView;
81 typedef struct _mScrollViewClass mScrollViewClass;
82 typedef struct _mScrollViewRenderer mScrollViewRenderer;
83 
88 #define NCSCTRL_SCROLLVIEW NCSCLASSNAME("scrollview")
89 
94 #define NCSS_SCRLV_SHIFT (NCSS_ITEMV_SHIFT)
95 
100 #define NCSS_SCRLV_UPNOTIFY NCSS_ITEMV_UPNOTIFY
101 
106 #define NCSS_SCRLV_LOOP NCSS_ITEMV_LOOP
107 
112 #define NCSS_SCRLV_SORT NCSS_ITEMV_AUTOSORT
113 
114 #define mScrollViewHeader(className) \
115  mItemViewHeader(className)
116 
117 
122 struct _mScrollView
123 {
124  mScrollViewHeader(mScrollView)
125 };
126 
127 #define mScrollViewClassHeader(clsName, parentClass) \
128  mItemViewClassHeader(clsName, parentClass) \
129  HITEM (*addItem)(clsName*, NCS_SCRLV_ITEMINFO *info, int *pos);
130 
140 struct _mScrollViewClass
141 {
142  mScrollViewClassHeader(mScrollView, mItemView)
143 };
144 
145 #define mScrollViewRendererHeader(clsName, parentClass) \
146  mItemViewRendererHeader(clsName, parentClass)
147 
153 struct _mScrollViewRenderer {
154  mScrollViewRendererHeader(mScrollView, mItemView)
155 };
156 
162 {
167 };
168 
174 {
185 };
186 
193 MGNCS_EXPORT extern mScrollViewClass g_stmScrollViewCls;
196 #ifdef __cplusplus
197 }
198 #endif /* __cplusplus */
199 
200 #endif /* _MGUI_CTRL_SCRLV_H */
NCSN_SCRLV_CLICKED
@ NCSN_SCRLV_CLICKED
Definition: mscrollview.h:176
g_stmScrollViewCls
MGNCS_EXPORT mScrollViewClass g_stmScrollViewCls
The instance of mScrollViewClass.
NCS_SCRLV_ITEMINFO
struct _NCS_SCRLV_ITEMINFO NCS_SCRLV_ITEMINFO
NCSP_SCRLV_MAX
@ NCSP_SCRLV_MAX
Definition: mscrollview.h:166
mItemView
The structure of mItemView control, which derived from mScrollWidget. It is the abstract superclass o...
_NCS_SCRLV_ITEMINFO
Definition: mscrollview.h:70
mScrollViewNotify
mScrollViewNotify
The notification code id of mScrollView.
Definition: mscrollview.h:173
mScrollView
The structure of mScrollView control, which derived from mItemView.
NCSN_ITEMV_SELCHANGING
@ NCSN_ITEMV_SELCHANGING
Definition: mitemview.h:590
NCSN_SCRLV_SELCHANGED
@ NCSN_SCRLV_SELCHANGED
Definition: mscrollview.h:178
NCSN_ITEMV_CLICKED
@ NCSN_ITEMV_CLICKED
Definition: mitemview.h:585
_NCS_SCRLV_ITEMINFO::index
int index
Definition: mscrollview.h:73
mScrollViewRenderer
The structure of mScrollView renderer, which inheried from mItemViewRenderer.
mScrollViewClass
The virtual function table of mScrollView, which derived from mItemViewClass.
NCSN_SCRLV_SELCHANGING
@ NCSN_SCRLV_SELCHANGING
Definition: mscrollview.h:180
mScrollViewProp
mScrollViewProp
The properties id of mScrollView.
Definition: mscrollview.h:161
NCSN_ITEMV_SELCHANGED
@ NCSN_ITEMV_SELCHANGED
Definition: mitemview.h:595
_NCS_SCRLV_ITEMINFO::addData
DWORD addData
Definition: mscrollview.h:77
NCSP_ITEMV_MAX
@ NCSP_ITEMV_MAX
Definition: mitemview.h:574
NCSN_SCRLV_MAX
@ NCSN_SCRLV_MAX
Definition: mscrollview.h:184
_NCS_SCRLV_ITEMINFO::height
int height
Definition: mscrollview.h:75
NCSN_ITEMV_MAX
@ NCSN_ITEMV_MAX
Definition: mitemview.h:615