+ /* The ICCCM spec says we have to withdraw the window to change WM_CLASS. + * Gnome works fine without doing that, but KDE requires it. */ + + ShowWindow( hwnd, SW_HIDE ); + + if ( data->display && data->whole_window ) + set_class_hints( data->display, data->whole_window, hwnd ); + + ShowWindow( hwnd, SW_SHOW );
Ouch, that's not going to work. We don't want to do this through win32 because then the application can see its window being hidden/shown (also, there doesn't seem to be any check here for whether it's already shown?).
Maybe we can check data->mapped and if so use map_window and unmap_window for this?