v2: Drop the configure_serial change, it might not be entirely correct: although we won't receive a ConfigureNotify for stack mode only and although it might cause window state updates to be delayed it's not the issue here.
It's incorrect because there might still be some requests and events in-flight, and resetting the serial to 0 will make us consider them as unexpected, and will apply possibly old ConfigureNotify events as if they were used-originated.
We should maybe just not change the serial for such requests, the same is also possibly the case for WM_STATE changes on unmanaged windows where we do the same. It's not been causing any obvious issue so far though, so lets keep it like this for now.