Fix for bug when showing a menu.