optimization, only need to call repaint if we actually change the menu