2 * vim:ts=4:sw=4:expandtab
4 * i3 - an improved dynamic tiling window manager
5 * © 2009 Michael Stapelberg and contributors (see also: LICENSE)
7 * handlers.c: Small handlers for various events (keypresses, focus changes,
15 #include <xcb/randr.h>
17 extern int randr_base;
19 extern int shape_base;
22 * Adds the given sequence to the list of events which are ignored.
23 * If this ignore should only affect a specific response_type, pass
24 * response_type, otherwise, pass -1.
26 * Every ignored sequence number gets garbage collected after 5 seconds.
29 void add_ignore_event(const int sequence, const int response_type);
32 * Checks if the given sequence is ignored and returns true if so.
35 bool event_is_ignored(const int sequence, const int response_type);
38 * Takes an xcb_generic_event_t and calls the appropriate handler, based on the
42 void handle_event(int type, xcb_generic_event_t *event);
45 * Sets the appropriate atoms for the property handlers after the atoms were
49 void property_handlers_init(void);
53 * Configuration notifies are only handled because we need to set up ignore
54 * for the following enter notify events
57 int handle_configure_event(void *prophs, xcb_connection_t *conn, xcb_configure_notify_event_t *event);
62 * Handles _NET_WM_WINDOW_TYPE changes
65 int handle_window_type(void *data, xcb_connection_t *conn, uint8_t state,
66 xcb_window_t window, xcb_atom_t atom,
67 xcb_get_property_reply_t *property);