Change the contextual menu according to the type of data selected.