2011-01-11

Eclipse Forms vs. Context Menus

If you are using Eclipse's form toolkit infrastructure, you might run into an problem where you try to install a context menu but it does not appear. If you are using FormToolkit.adapt(Composite) to adapt a custom composite to a form, you must install your menu after adapting it. Otherwise, your menu will be replaced by the parent's menu. This may seem to be reasonable behaviour -- except when the parent widget has no menu at all.