Don't put checkmarks in the Filters menu. Don't let the Filters menu and the Switch Tree menu listen for each other's click events.
whitespace
Factor out menu-hiding in preparation for fixing bug 965666.