Feb. 17, 2011
8:15 p.m.
I want to give the thanks to Alain, for the excellent work on PragmaMenuBuilder! Making menus is elegant and straightforward this way! I post here how i'm using them: MyMorph>>mouseDown: aMouseEvent aMouseEvent redButtonPressed ifTrue:[ self click: aMouseEvent ]. aMouseEvent yellowButtonPressed ifTrue:[ self leftClick: aMouseEvent ]. MyMorph>>leftClick: aMouseEvent self menuBuilder menu popUpInWorld MyMorph>>menuBuilder ^ (PragmaMenuBuilder pragmaKeyword: 'tileMenu' model: self) And you can nicely decouple the menu invocation from the menu creation! Thanks! Fernando