Fixed previously opened menus not closing.