2025-06-27 00:32:57 +08:00
|
|
|
|
#ifndef MYWIN_LIST_H__
|
|
|
|
|
|
#define MYWIN_LIST_H__
|
|
|
|
|
|
|
2025-07-06 18:46:13 +08:00
|
|
|
|
// ҳ<>棬<EFBFBD>̳<EFBFBD><CCB3><EFBFBD>MYWIN<49><4E><EFBFBD><EFBFBD>
|
2025-06-27 00:32:57 +08:00
|
|
|
|
|
2025-07-06 18:46:13 +08:00
|
|
|
|
typedef struct {
|
|
|
|
|
|
WIN_WindowStruct win;
|
|
|
|
|
|
int list_y; // <09>б<EFBFBD><D0B1><EFBFBD>y<EFBFBD><79><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ԭ<EFBFBD><D4AD>
|
|
|
|
|
|
int index;
|
|
|
|
|
|
int itemHeigh;
|
|
|
|
|
|
int itemNum;
|
|
|
|
|
|
char **item;
|
|
|
|
|
|
WIN_ButtonStruct **button;
|
|
|
|
|
|
} WIN_ListStruct;
|
2025-06-27 00:32:57 +08:00
|
|
|
|
|
2025-07-06 18:46:13 +08:00
|
|
|
|
// <20>ڶ<EFBFBD><DAB6>д<EFBFBD><D0B4><EFBFBD>һ<EFBFBD><D2BB><EFBFBD>б<EFBFBD><D0B1><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
WIN_ListStruct *WIN_CreatList(WIN_WindowStruct *base,
|
|
|
|
|
|
void (*msgLoop)(struct _WIN_WindowStruct *win,
|
|
|
|
|
|
WIN_MsgStruct *msg),
|
|
|
|
|
|
int x, int y, int x_size, int y_size);
|
2025-06-27 00:32:57 +08:00
|
|
|
|
|
2025-07-06 18:46:13 +08:00
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD>б<EFBFBD><D0B1><EFBFBD><EFBFBD><EFBFBD>ʾ<EFBFBD><CABE><EFBFBD><EFBFBD>Ŀ
|
|
|
|
|
|
void LIST_SetItem(WIN_ListStruct *list, char **item, int itemNum);
|
2025-06-27 00:32:57 +08:00
|
|
|
|
|
2025-07-06 18:46:13 +08:00
|
|
|
|
// <20><><EFBFBD><EFBFBD>ÿ<EFBFBD><C3BF><EFBFBD><EFBFBD>Ŀ<EFBFBD>ĸ߶<C4B8>
|
|
|
|
|
|
void LIST_SetItemHeight(WIN_ListStruct *list, int height);
|
2025-06-27 00:32:57 +08:00
|
|
|
|
|
2025-07-06 18:46:13 +08:00
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD>б<EFBFBD>Y<EFBFBD>᷽<EFBFBD><E1B7BD><EFBFBD><EFBFBD>ԭ<EFBFBD><D4AD>
|
|
|
|
|
|
void LIST_SetYOrigin(WIN_ListStruct *list, int ori);
|
2025-06-27 00:32:57 +08:00
|
|
|
|
|
2025-07-06 18:46:13 +08:00
|
|
|
|
// <20><><EFBFBD><EFBFBD>Y<EFBFBD>᷽<EFBFBD><E1B7BD><EFBFBD><EFBFBD><EFBFBD>ƶ<EFBFBD><C6B6><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
void LIST_SetYMove(WIN_ListStruct *list, int move);
|
2025-06-27 00:32:57 +08:00
|
|
|
|
|
2025-07-06 18:46:13 +08:00
|
|
|
|
// Ĭ<>ϻ<EFBFBD><CFBB>ƺ<EFBFBD><C6BA><EFBFBD>
|
|
|
|
|
|
void LIST_DefaultPaint(WIN_ListStruct *list);
|
2025-06-27 00:32:57 +08:00
|
|
|
|
|
2025-07-06 18:46:13 +08:00
|
|
|
|
// Ĭ<><C4AC><EFBFBD><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
void LIST_DefaultMsgLoop(WIN_ListStruct *list, WIN_MsgStruct *msg);
|
2025-06-27 00:32:57 +08:00
|
|
|
|
|
|
|
|
|
|
#endif
|