forked from 400plus/400plus
-
Notifications
You must be signed in to change notification settings - Fork 0
/
menupage.h
40 lines (30 loc) · 930 Bytes
/
menupage.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#ifndef MENUPAGE_H_
#define MENUPAGE_H_
#include "menu.h"
typedef struct {
int size;
menuitem_t *data;
} list_item_t;
struct menupage_t {
char *name;
list_item_t items;
menuaction_t actions[MENU_EVENT_COUNT];
int sibilings;
int show_id;
int *ordering;
int highlight;
int highlighted_item;
int current_line;
int current_posn;
};
extern void menupage_initialize(menupage_t *page);
extern void menupage_display(menu_t *menu);
extern void menupage_refresh(menu_t *menu);
extern void menupage_up (menu_t *menu);
extern void menupage_down (menu_t *menu);
extern void menupage_pgup (menu_t *menu);
extern void menupage_pgdown (menu_t *menu);
extern void menupage_drag_drop(menu_t *menu);
extern menuitem_t *get_current_item(menupage_t *page);
extern int get_item_id (menupage_t *page, int item_pos);
#endif /* MENU_H_ */