Implement the window::fullscreen_mode event

The fullscreen_mode event is a window with the "change" property set to
"fullscreen_mode". This event should be emitted whenever a window enters
or exits fullscreen mode.

This event can be used to turn off dpms off when a window is fullscreen
or display the fullscreen container name in the status line for
instance.
This commit is contained in:
Tony Crisci
2014-04-28 18:38:06 -04:00
committed by Michael Stapelberg
parent 2f42fe61d9
commit 8146638320
3 changed files with 69 additions and 3 deletions

View File

@ -609,6 +609,9 @@ void con_toggle_fullscreen(Con *con, int fullscreen_mode) {
DLOG("mode now: %d\n", con->fullscreen_mode);
/* Send an ipc window "fullscreen_mode" event */
ipc_send_window_event("fullscreen_mode", con);
/* update _NET_WM_STATE if this container has a window */
/* TODO: when a window is assigned to a container which is already
* fullscreened, this state needs to be pushed to the client, too */