Reframe swallowed windows if depth doesn't match

X will not allow a window with ParentRelative background to be created
or reparented under a window with mismatching color depth.
Deal with this by destroying the container frame and creating a new one
with the right depth upon swallowing.
Defer destruction of the frame window until after the updated tree has
been rendered to avoid some distracting flickering.

Fixes #3297
This commit is contained in:
Dan Elkouby
2018-06-01 18:55:35 +03:00
parent 26f50898fd
commit 7ac37d8ae4
3 changed files with 39 additions and 6 deletions

View File

@ -49,6 +49,12 @@ void x_reinit(Con *con);
*/
void x_con_kill(Con *con);
/*
* Completely reinitializes the container's frame, without destroying the old window.
*
*/
void x_con_reframe(Con *con);
/**
* Returns true if the client supports the given protocol atom (like WM_DELETE_WINDOW)
*