yakov pushed a commit to branch master. http://git.enlightenment.org/tools/erigo.git/commit/?id=3430341c8f4a681991fb9a5911d9a2570cb9eb91
commit 3430341c8f4a681991fb9a5911d9a2570cb9eb91 Author: Yakov Goldberg <yako...@samsung.com> Date: Mon Jan 4 18:48:56 2016 +0200 Fix code generation for window's main menu --- src/lib/generator.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/src/lib/generator.c b/src/lib/generator.c index 8eeb5cf..3c7282c 100644 --- a/src/lib/generator.c +++ b/src/lib/generator.c @@ -635,6 +635,24 @@ _wdg_add_generate(Gui_Session *session, const Gui_Widget *wdg, void *data) return EINA_FALSE; } + if (!strcmp(class_id, DB_DEF_MENU_CLASS)) + { + if (strstr(wdg_name_get(wdg), "main_menu")) + { + if (gl_ctx->generate_legacy) + { + eina_strbuf_append_printf(wdg_ctx->buf, " %s = elm_win_main_menu_get(%s);\n", + wdg_name_get(wdg), parent_id); + } + else + { + eina_strbuf_append_printf(wdg_ctx->buf, " eo_do(%s, %s = elm_obj_win_main_menu_get());\n", + parent_id, wdg_name_get(wdg)); + } + goto end; + } + } + /* if there is no property "constructor", it means - using eo constr */ if (!wdg_has_constructors(wdg)) { @@ -708,6 +726,7 @@ _wdg_add_generate(Gui_Session *session, const Gui_Widget *wdg, void *data) eina_strbuf_append_printf(wdg_ctx->pub_widgets_buf, " Eo *%s;\n", wdg_name_get(wdg)); } +end: session_wdg_existence_set(session, wdg, EINA_TRUE); return EINA_TRUE; --