Fix Windows min/max animation on frameless windows

- Frameless windows disappeared or appears when minimized and maximized
on Windows. This commit fixes that.