2003-05-16 18:10:10 +00:00
|
|
|
#ifndef __dock_h
|
|
|
|
#define __dock_h
|
|
|
|
|
|
|
|
#include "timer.h"
|
|
|
|
#include "window.h"
|
|
|
|
#include "stacking.h"
|
2003-05-16 19:15:56 +00:00
|
|
|
#include "geom.h"
|
|
|
|
#include "render/render.h"
|
2003-05-16 18:10:10 +00:00
|
|
|
|
|
|
|
#include <glib.h>
|
|
|
|
#include <X11/Xlib.h>
|
|
|
|
#include <X11/Xutil.h>
|
|
|
|
|
|
|
|
typedef enum {
|
|
|
|
DockPos_Floating,
|
|
|
|
DockPos_TopLeft,
|
|
|
|
DockPos_Top,
|
|
|
|
DockPos_TopRight,
|
|
|
|
DockPos_Right,
|
|
|
|
DockPos_BottomRight,
|
|
|
|
DockPos_Bottom,
|
|
|
|
DockPos_BottomLeft,
|
|
|
|
DockPos_Left
|
|
|
|
} DockPosition;
|
|
|
|
|
|
|
|
typedef struct Dock {
|
|
|
|
ObWindow obwin;
|
|
|
|
|
|
|
|
Window frame;
|
2003-06-21 00:42:47 +00:00
|
|
|
RrAppearance *a_frame;
|
2003-05-16 18:10:10 +00:00
|
|
|
|
|
|
|
/* actual position (when not auto-hidden) */
|
|
|
|
int x, y;
|
|
|
|
int w, h;
|
|
|
|
|
|
|
|
gboolean hidden;
|
|
|
|
Timer *hide_timer;
|
|
|
|
|
|
|
|
GList *dock_apps;
|
|
|
|
} Dock;
|
|
|
|
|
|
|
|
typedef struct DockApp {
|
2003-05-16 18:34:29 +00:00
|
|
|
ObWindow obwin;
|
|
|
|
|
2003-05-16 18:10:10 +00:00
|
|
|
int ignore_unmaps;
|
|
|
|
|
|
|
|
Window icon_win;
|
|
|
|
Window win;
|
2003-05-16 20:20:33 +00:00
|
|
|
|
|
|
|
char *name;
|
|
|
|
char *class;
|
|
|
|
|
2003-05-16 18:10:10 +00:00
|
|
|
int x;
|
|
|
|
int y;
|
|
|
|
int w;
|
|
|
|
int h;
|
|
|
|
} DockApp;
|
|
|
|
|
2003-05-16 19:15:56 +00:00
|
|
|
extern Strut dock_strut;
|
|
|
|
|
2003-05-16 18:10:10 +00:00
|
|
|
void dock_startup();
|
|
|
|
void dock_shutdown();
|
|
|
|
|
|
|
|
void dock_configure();
|
|
|
|
void dock_hide(gboolean hide);
|
|
|
|
|
|
|
|
void dock_add(Window win, XWMHints *wmhints);
|
|
|
|
|
|
|
|
void dock_remove_all();
|
|
|
|
void dock_remove(DockApp *app, gboolean reparent);
|
|
|
|
|
|
|
|
void dock_app_drag(DockApp *app, XMotionEvent *e);
|
|
|
|
void dock_app_configure(DockApp *app, int w, int h);
|
|
|
|
|
|
|
|
#endif
|