]> Pileus Git - wmpus/blobdiff - sys.h
Add TYPE_TOOLBAR instead of hiding them in sys
[wmpus] / sys.h
diff --git a/sys.h b/sys.h
index db18800c0724e20903652046744ce64bf83d1431..adc0247590c6470b74e1769607542d492b1dd748 100644 (file)
--- a/sys.h
+++ b/sys.h
@@ -35,15 +35,24 @@ typedef enum {
        ST_CLOSE, // close the window
 } state_t;
 
+/* Window types */
+typedef enum {
+       TYPE_NORMAL,
+       TYPE_DIALOG,
+       TYPE_TOOLBAR,
+} type_t;
+
 /* Basic window type */
 typedef struct win_sys win_sys_t;
 typedef struct win_wm  win_wm_t;
-typedef struct {
+typedef struct win {
        int x, y, z;
        int w, h;
-       state_t    state;
-       win_sys_t *sys;
-       win_wm_t  *wm;
+       state_t state;
+       type_t  type;
+       struct win *parent;
+       win_sys_t  *sys;
+       win_wm_t   *wm;
 } win_t;
 
 /* Generic key codes, also used for some other events