added sample for menu model
added callback to menu, some tweaks for sample code