Enable meaningful window state toggling depending on content type, fix dock pan gesture handling