enable/disable edit menu item based on whether an edit action is possible or not

Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>