While doing this, drop the get_mdi_zorder implementation that really should come from the window manager side. Dropping this saves some 500 lines.