return it->base.view;
}
+static void
+_item_clone(Evas_Object *obj, Elm_Menu_Item *parent, Elm_Menu_Item *item)
+{
+ Elm_Menu_Item *new_item, *subitem;
+ Eina_List *iter;
+
+ if (item->separator)
+ new_item = elm_menu_item_separator_add(obj, parent);
+ else
+ new_item = elm_menu_item_add(obj, parent, item->icon_str, item->label, item->func, item->base.data);
+ elm_menu_item_disabled_set(new_item, item->disabled);
+
+ EINA_LIST_FOREACH(item->submenu.items, iter, subitem)
+ _item_clone(obj, new_item, subitem);
+}
+
+void
+elm_menu_clone(Evas_Object *from_menu, Evas_Object *to_menu, Elm_Menu_Item *parent)
+{
+ ELM_CHECK_WIDTYPE(from_menu, widtype);
+ ELM_CHECK_WIDTYPE(to_menu, widtype);
+ Widget_Data *from_wd = elm_widget_data_get(from_menu);
+ Eina_List *iter;
+ Elm_Menu_Item *item;
+
+ if (!from_wd) return;
+ EINA_LIST_FOREACH(from_wd->items, iter, item)
+ _item_clone(to_menu, parent, item);
+}
+
/**
* Add an item at the end
*
void elm_cursor_theme(Elm_Cursor *cur);
void elm_object_sub_cursor_set(Evas_Object *eventarea, Evas_Object *owner, const char *cursor);
+void elm_menu_clone(Evas_Object *from_menu, Evas_Object *to_menu, Elm_Menu_Item *parent);
+
Eina_Bool _elm_dangerous_call_check(const char *call);
Evas_Object *_elm_scroller_edje_object_get(Evas_Object *obj);
item = elm_menu_item_add(menu, NULL, it->icon_str, it->label,
it->func, it->base.data);
elm_menu_item_disabled_set(item, it->disabled);
+ if (it->o_menu) elm_menu_clone(it->o_menu, menu, item);
}
evas_object_hide(it->base.view);
}