IJ1Helper: use MenuPaths instead of Strings

We can not parse the menu structure from the String created by a
MenuPath. Even checking for MenuPath separators is insufficient, as it
will require us to trim the menu entry labels.

We can not trim because then we will remove the whitespace that is
critical in differentiating commands in ImageJ 1.x.

Also it is fragile to use the String parsing so let's just use the
MenuPath and MenuEntry elements that are readily available.