WIP still needs some cleanup
Rework window creation handling

Signed-off-by: Simon Busch <morphis@gravedo.de>
Merge branch 'work/window-creation'