Map newly created window in handle_new_window

A window might be mapped before we had the chance to start managing it.
So check to see if we should map a window after we call fill_win on it.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui
2019-04-19 21:10:38 +01:00
parent 58944f36ce
commit 0753eaacf8
3 changed files with 19 additions and 11 deletions

View File

@ -418,7 +418,7 @@ struct win *add_win_above(session_t *ps, xcb_window_t id, xcb_window_t below);
struct win *add_win_top(session_t *ps, xcb_window_t id);
/// Query the Xorg for information about window `win`
/// `win` pointer might become invalid after this function returns
void fill_win(session_t *ps, struct win *win);
struct win *fill_win(session_t *ps, struct win *win);
/// Unmap or destroy a window
void unmap_win(session_t *ps, struct managed_win **, bool destroy);
/// Destroy an unmanaged window