Fixing GUI. Adding support for several windows