May 22, 2026
1:38 p.m.
KWin deletes WM_STATE property from a window when entering WithdrawnState. Please see X11Window::exportMappingState() in the KWin source code. So when get_window_wm_state() fails, -1 is returned before this patch. Since -1 is not a valid WM_STATE, it might cause Wine to expect an invalid value. We also can't simply ignore the invalid -1 because we might be expecting the WM_STATE property notify event to change to the desired state. Treating missing WM_STATE property as WithdrawnState seems like the best way to go. Help fix RiME(493200) sometimes fails to restore from Alt+Tab. -- v2: https://gitlab.winehq.org/wine/wine/-/merge_requests/10949