WRT patch 1, a fullscreen window is supposed to become manage. It doesn't currently happen with emulated mode when the emulated window rect is less than native mode fullscreen. So the window stays unmanaged, in this state it is on top of everything and is impossible to switch out (override_redirect window attribute is responsible for that).
WRT patch 2, sync_window_style() is needed to change override_redirect window attribute after window is made manage. It will be called in the course of unmapping and conseqeunt window mapping sequence, but the state transitions happening before that are broken with override_redirect not reset, the (absent) expected states on the way are absent.