* move room listing related stuff into its own file
[citadel.git] / webcit / roomops.h
1
2 #define VIRTUAL_MY_FLOOR -1
3
4 /*
5  * \brief This struct holds a list of rooms for \\\<G\\\>oto operations.
6  */
7 struct march {
8         struct march *next;       /* pointer to next in linked list */
9         char march_name[128];     /* name of room */
10         int march_floor;          /* floor number of room */
11         int march_order;          /* sequence in which we are to visit this room */
12 };
13
14 /* *
15  * \brief       This struct holds a list of rooms for client display.
16  *              It is a binary tree.
17  */
18 struct roomlisting {
19         struct roomlisting *lnext;      /* pointer to 'left' tree node */
20         struct roomlisting *rnext;      /* pointer to 'right' tree node */
21         char rlname[128];               /* name of room */
22         unsigned rlflags;               /* room flags */
23         int rlfloor;                    /* the floor it resides on */
24         int rlorder;                    /* room listing order */
25 };
26
27
28
29
30
31 typedef struct _floor {
32         long ID;
33         StrBuf *Name;
34         long NRooms;
35 } floor;
36
37 /**
38  * \brief  Data structure for roomlist-to-folderlist conversion 
39  */
40 struct __ofolder {
41         int floor;      /* which floor is it on */
42         char room[SIZ]; /* which roomname ??? */
43         char name[SIZ]; /* which is its own name??? */
44         int hasnewmsgs; /* are there unread messages inside */
45         int is_mailbox; /* is it a mailbox?  */
46         int selectable; /* can we select it ??? */
47         int view;       /* whats its default view? inbox/calendar.... */
48         int num_rooms;  /* If this is a floor, how many rooms does it have */
49 };
50
51
52
53 /**
54  * \brief  Data structure for roomlist-to-folderlist conversion 
55  */
56 typedef struct _folder {
57         StrBuf *name;   /* which is its own name??? */
58         int QRFlags;    /* roomflags */
59         int floorid;      /* which floor is it on */
60
61
62         int listorder; /* todo */
63
64         StrBuf *ACL;    /* access Control list... */
65
66         int view;       /* whats its default view? inbox/calendar.... */
67         int defview;
68         int lastchange; /* todo... */
69
70
71
72
73         const floor *Floor;   /* pint to the floor we're on.. */
74         StrBuf *room;   /* which roomname ??? */
75
76
77         int hasnewmsgs; /* are there unread messages inside */
78         int is_mailbox; /* is it a mailbox?  */
79         int selectable; /* can we select it ??? */
80         int num_rooms;  /* If this is a floor, how many rooms does it have */
81
82 }folder;
83