x11: Unload effects before destroying Workspace and Compositor
Effects can hold references to closed windows, which can cause problems after the workspace is destroyed.
This change makes ApplicationX11 unload effects before destroying the Workspace and the Compositor similar to how it's done in main_wayland.