improve menu behaviour