add listener to current mode menu item to keep it selected, fixes #2545