added action listening to the menu class