fullscreen flash crash bug

This commit is contained in:
Sean Pringle
2013-10-01 12:39:38 +10:00
parent 76e13ad393
commit a803468635
2 changed files with 7 additions and 2 deletions

View File

@@ -105,8 +105,12 @@ void action_focus_monitor(void *data, int num, client *cli)
void action_fullscreen(void *data, int num, client *cli) void action_fullscreen(void *data, int num, client *cli)
{ {
if (!cli) return; if (!cli) return;
if (cli->full && GETPROP_LONG(cli->window, atoms[XOAT_SPOT], &cli->spot, 1));
else SETPROP_LONG(cli->window, atoms[XOAT_SPOT], &cli->spot, 1); unsigned long spot;
if (cli->full && GETPROP_LONG(cli->window, atoms[XOAT_SPOT], &spot, 1))
cli->spot = spot;
SETPROP_LONG(cli->window, atoms[XOAT_SPOT], &cli->spot, 1);
client_toggle_state(cli, atoms[_NET_WM_STATE_FULLSCREEN]); client_toggle_state(cli, atoms[_NET_WM_STATE_FULLSCREEN]);
client_place_spot(cli, cli->full ? SPOT1: cli->spot, cli->monitor, 1); client_place_spot(cli, cli->full ? SPOT1: cli->spot, cli->monitor, 1);
client_update_border(cli); client_update_border(cli);

1
xoat.c
View File

@@ -197,6 +197,7 @@ int oops(Display *d, XErrorEvent *ee)
if (ee->error_code == BadWindow if (ee->error_code == BadWindow
|| (ee->request_code == X_SetInputFocus && ee->error_code == BadMatch) || (ee->request_code == X_SetInputFocus && ee->error_code == BadMatch)
|| (ee->request_code == X_ConfigureWindow && ee->error_code == BadMatch) || (ee->request_code == X_ConfigureWindow && ee->error_code == BadMatch)
|| (ee->request_code == X_ConfigureWindow && ee->error_code == BadValue)
|| (ee->request_code == X_GrabButton && ee->error_code == BadAccess) || (ee->request_code == X_GrabButton && ee->error_code == BadAccess)
|| (ee->request_code == X_GrabKey && ee->error_code == BadAccess) || (ee->request_code == X_GrabKey && ee->error_code == BadAccess)
) return 0; ) return 0;