diff -r 909fe96e5659 -r 102fc0b8fe3e ui/qt/menu.cpp --- a/ui/qt/menu.cpp Sun Jan 24 22:20:47 2016 +0100 +++ b/ui/qt/menu.cpp Mon Jan 25 16:36:31 2016 +0100 @@ -339,13 +339,12 @@ void UiContextMenuHandler::contextMenuEvent(const QPoint & pos) { menu->popup(widget->mapToGlobal(pos)); } - -void ui_contextmenu(UiObject *obj) { +UIMENU ui_contextmenu(UiObject *obj) { UiContainer *ct = uic_get_current_container(obj); - ui_contextmenu_w(obj, ct->current); + return ui_contextmenu_w(obj, ct->current); } -void ui_contextmenu_w(UiObject *obj, UIWIDGET widget) { +UIMENU ui_contextmenu_w(UiObject *obj, UIWIDGET widget) { UiContainer *ct = uic_get_current_container(obj); QMenu *menu = new QMenu(widget); @@ -359,6 +358,12 @@ SLOT(contextMenuEvent(QPoint))); ct->menu = menu; + + return menu; +} + +void ui_contextmenu_popup(UIMENU menu) { + } void ui_widget_menuitem(UiObject *obj, char *label, ui_callback f, void *userdata) {