elementary/naviframe - added obj parameters to insert_before, insert_after APis to...
authorhermet <hermet@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Wed, 7 Mar 2012 16:52:22 +0000 (16:52 +0000)
committerhermet <hermet@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Wed, 7 Mar 2012 16:52:22 +0000 (16:52 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/elementary@69003 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/elc_naviframe.c
src/lib/elc_naviframe.h

index f69b4e8..b586583 100644 (file)
@@ -1160,18 +1160,20 @@ elm_naviframe_item_push(Evas_Object *obj,
 }
 
 EAPI Elm_Object_Item *
-elm_naviframe_item_insert_before(Elm_Object_Item *before,
+elm_naviframe_item_insert_before(Evas_Object *obj,
+                                 Elm_Object_Item *before,
                                  const char *title_label,
                                  Evas_Object *prev_btn,
                                  Evas_Object *next_btn,
                                  Evas_Object *content,
                                  const char *item_style)
 {
+   ELM_CHECK_WIDTYPE(obj, widtype) NULL;
    ELM_OBJ_ITEM_CHECK_OR_RETURN(before, NULL);
    Elm_Naviframe_Item *it;
    Widget_Data *wd;
 
-   wd = elm_widget_data_get(WIDGET(before));
+   wd = elm_widget_data_get(obj);
    if (!wd) return NULL;
 
    it = _item_new(WIDGET(before), title_label, prev_btn, next_btn, content,
@@ -1187,18 +1189,20 @@ elm_naviframe_item_insert_before(Elm_Object_Item *before,
 }
 
 EAPI Elm_Object_Item *
-elm_naviframe_item_insert_after(Elm_Object_Item *after,
+elm_naviframe_item_insert_after(Evas_Object *obj,
+                                Elm_Object_Item *after,
                                 const char *title_label,
                                 Evas_Object *prev_btn,
                                 Evas_Object *next_btn,
                                 Evas_Object *content,
                                 const char *item_style)
 {
+   ELM_CHECK_WIDTYPE(obj, widtype) NULL;
    ELM_OBJ_ITEM_CHECK_OR_RETURN(after, NULL);
    Elm_Naviframe_Item *it;
    Widget_Data *wd;
 
-   wd = elm_widget_data_get(WIDGET(after));
+   wd = elm_widget_data_get(obj);
    if (!wd) return NULL;
 
    it = _item_new(WIDGET(after), title_label, prev_btn, next_btn, content,
index ab8efb6..d43d209 100644 (file)
@@ -113,6 +113,7 @@ EAPI Elm_Object_Item *elm_naviframe_item_push(Evas_Object *obj, const char *titl
 /**
  * @brief Insert a new item into the naviframe before item @p before.
  *
+ * @param obj The naviframe object
  * @param before The naviframe item to insert before.
  * @param title_label The label in the title area. The name of the title
  *        label part is "elm.text.title"
@@ -139,11 +140,12 @@ EAPI Elm_Object_Item *elm_naviframe_item_push(Evas_Object *obj, const char *titl
  *
  * @ingroup Naviframe
  */
-EAPI Elm_Object_Item *elm_naviframe_item_insert_before(Elm_Object_Item *before, const char *title_label, Evas_Object *prev_btn, Evas_Object *next_btn, Evas_Object *content, const char *item_style);
+EAPI Elm_Object_Item *elm_naviframe_item_insert_before(Evas_Object *obj, Elm_Object_Item *before, const char *title_label, Evas_Object *prev_btn, Evas_Object *next_btn, Evas_Object *content, const char *item_style);
 
 /**
  * @brief Insert a new item into the naviframe after item @p after.
  *
+ * @param obj The naviframe object
  * @param after The naviframe item to insert after.
  * @param title_label The label in the title area. The name of the title
  *        label part is "elm.text.title"
@@ -170,7 +172,7 @@ EAPI Elm_Object_Item *elm_naviframe_item_insert_before(Elm_Object_Item *before,
  *
  * @ingroup Naviframe
  */
-EAPI Elm_Object_Item *elm_naviframe_item_insert_after(Elm_Object_Item *after, const char *title_label, Evas_Object *prev_btn, Evas_Object *next_btn, Evas_Object *content, const char *item_style);
+EAPI Elm_Object_Item *elm_naviframe_item_insert_after(Evas_Object *obj, Elm_Object_Item *after, const char *title_label, Evas_Object *prev_btn, Evas_Object *next_btn, Evas_Object *content, const char *item_style);
 
 /**
  * @brief Pop an item that is on top of the stack