Improved menu disabling at certain times.