Merge pull request #826 from stefansaraev/menu-fixes

several menu state fixes. Close #822.