]> Dogcows Code - chaz/openbox/blob - openbox/focus.h
dont need client.h in this header
[chaz/openbox] / openbox / focus.h
1 #ifndef __focus_h
2 #define __focus_h
3
4 #include <X11/Xlib.h>
5 #include <glib.h>
6
7 struct _ObClient;
8
9 /*! The window which gets focus when nothing else will be focused */
10 extern Window focus_backup;
11
12 /*! The client which is currently focused */
13 extern struct _ObClient *focus_client;
14
15 /*! The recent focus order on each desktop */
16 extern GList **focus_order;
17
18 void focus_startup();
19 void focus_shutdown();
20
21 /*! Specify which client is currently focused, this doesn't actually
22 send focus anywhere, its called by the Focus event handlers */
23 void focus_set_client(struct _ObClient *client);
24
25 typedef enum {
26 Fallback_Desktop, /* switching desktops */
27 Fallback_Unfocusing, /* forcefully remove focus from the current window */
28 Fallback_NoFocus /* nothing has focus for some reason */
29 } FallbackType;
30
31 /*! Call this when you need to focus something! */
32 void focus_fallback(FallbackType type);
33
34 /*! Cycle focus amongst windows
35 Returns the _ObClient to which focus has been cycled, or NULL if none. */
36 struct _ObClient *focus_cycle(gboolean forward, gboolean linear, gboolean done,
37 gboolean cancel);
38
39 /*! Add a new client into the focus order */
40 void focus_order_add_new(struct _ObClient *c);
41
42 /*! Remove a client from the focus order */
43 void focus_order_remove(struct _ObClient *c);
44
45 /*! Move a client to the top of the focus order */
46 void focus_order_to_top(struct _ObClient *c);
47
48 /*! Move a client to the bottom of the focus order (keeps iconic windows at the
49 very bottom always though). */
50 void focus_order_to_bottom(struct _ObClient *c);
51
52 #endif
This page took 0.035739 seconds and 4 git commands to generate.