added menu dialog support to dialog_wrapper