better support for active window