After a deep refactoring, finally finished to split the window manager