Fixes for multiwindow refactoring, Windows target

These are fixes for compile time errors when compiling for Windows with MinGW.