Better native before menu open event on Mac

This is for https://github.com/adobe/brackets/issues/4225.

This fixes callback so it only happens once before menu is opened.

Note this still does not work on main (Apple) menu, Brackets menu, or Window menu (i.e. neither did original solution).

cc: @gruehle