yay good job! please update ElementaryChanges as well. http://trac.enlightenment.org/e/wiki/ElementaryChanges
Daniel Juyung Seo (SeoZ) 2011/12/20 ChunEon Park <her...@naver.com>: > Log:elementary/hoversel - Elm_Hoversel_Item -> Elm_Object_Item**This may > break your application compilation** > ------------------------------------ > -Regards, Hermet- > > -----Original Message----- > From: "Enlightenment SVN"<no-re...@enlightenment.org> > To: enlightenment-...@lists.sourceforge.net > Cc: > Sent: 11-12-20(화) 10:03:17 > Subject: E SVN: hermet IN trunk/elementary/src: bin examples lib > Log: > elementary/hoversel - Elm_Hoversel_Item -> Elm_Object_Item > > **This may break your application compilation** > > > Author: hermet > Date: 2011-12-19 17:03:17 -0800 (Mon, 19 Dec 2011) > New Revision: 66343 > Trac: http://trac.enlightenment.org/e/changeset/66343 > Modified: > trunk/elementary/src/bin/test_web.c > trunk/elementary/src/examples/hoversel_example_01.c > trunk/elementary/src/lib/Elementary.h.in > trunk/elementary/src/lib/elc_hoversel.c > Modified: trunk/elementary/src/bin/test_web.c > =================================================================== > --- trunk/elementary/src/bin/test_web.c 2011-12-19 21:59:31 UTC (rev 66342) > +++ trunk/elementary/src/bin/test_web.c 2011-12-20 01:03:17 UTC (rev 66343) > @@ -294,8 +294,8 @@ > _zoom_mode_cb(void *data, Evas_Object *obj __UNUSED__, void *event_info) > { > Web_Test *wt = data; > - Elm_Hoversel_Item *it = event_info; > - const char *lbl = elm_hoversel_item_label_get(it); > + Elm_Object_Item *hoversel_it = event_info; > + const char *lbl = elm_hoversel_item_label_get(hoversel_it); > > if (!strcmp(lbl, "Manual")) > elm_web_zoom_mode_set(wt->web, ELM_WEB_ZOOM_MODE_MANUAL); > Modified: trunk/elementary/src/examples/hoversel_example_01.c > =================================================================== > --- trunk/elementary/src/examples/hoversel_example_01.c 2011-12-19 21:59:31 > UTC (rev 66342) > +++ trunk/elementary/src/examples/hoversel_example_01.c 2011-12-20 01:03:17 > UTC (rev 66343) > @@ -16,7 +16,7 @@ > elm_main(int argc, char **argv) > { > Evas_Object *win, *bg, *rect, *hoversel; > - Elm_Hoversel_Item *it; > + Elm_Object_Item *hoversel_it; > > win = elm_win_add(NULL, "hoversel", ELM_WIN_BASIC); > elm_win_title_set(win, "Hoversel"); > @@ -40,9 +40,9 @@ > _print_items, NULL); > elm_hoversel_item_add(hoversel, "Option 2", "home", ELM_ICON_STANDARD, NULL, > NULL); > - it = elm_hoversel_item_add(hoversel, "Clear all items", "close", > - ELM_ICON_STANDARD, _rm_items, NULL); > - evas_object_smart_callback_add(hoversel, "selected", _sel, it); > + hoversel_it = elm_hoversel_item_add(hoversel, "Clear all items", "close", > + ELM_ICON_STANDARD, _rm_items, NULL); > + evas_object_smart_callback_add(hoversel, "selected", _sel, hoversel_it); > evas_object_smart_callback_add(hoversel, "clicked", _add_item, NULL); > > evas_object_resize(hoversel, 180, 30); > @@ -63,10 +63,10 @@ > { > const Eina_List *items = elm_hoversel_items_get(obj); > const Eina_List *l; > - Elm_Hoversel_Item *it; > + Elm_Object_Item *hoversel_it; > > - EINA_LIST_FOREACH(items, l, it) > - printf("%s\n", elm_hoversel_item_label_get(it)); > + EINA_LIST_FOREACH(items, l, hoversel_it) > + printf("%s\n", elm_hoversel_item_label_get(hoversel_it)); > } > > static void > @@ -88,12 +88,13 @@ > { > static int num = 0; > char *str = malloc(sizeof(char) * 10); > - Elm_Hoversel_Item *it; > + Elm_Object_Item *hoversel_it; > > snprintf(str, 10, "item %d", ++num); > > - it = elm_hoversel_item_add(obj, str, NULL, ELM_ICON_NONE, NULL, str); > - elm_hoversel_item_del_cb_set(it, _free); > + hoversel_it = elm_hoversel_item_add(obj, str, NULL, ELM_ICON_NONE, NULL, > + str); > + elm_hoversel_item_del_cb_set(hoversel_it, _free); > } > > static void > Modified: trunk/elementary/src/lib/Elementary.h.in > =================================================================== > --- trunk/elementary/src/lib/Elementary.h.in 2011-12-19 21:59:31 UTC (rev > 66342) > +++ trunk/elementary/src/lib/Elementary.h.in 2011-12-20 01:03:17 UTC (rev > 66343) > @@ -15034,7 +15034,6 @@ > * See @ref tutorial_hoversel for an example. > * @{ > */ > - typedef struct _Elm_Hoversel_Item Elm_Hoversel_Item; /**< Item of > Elm_Hoversel. Sub-type of Elm_Widget_Item */ > > /** > * @brief Add a new Hoversel object > @@ -15196,7 +15195,7 @@ > * @brief Get the list of items within the given hoversel. > * > * @param obj The hoversel object > - * @return Returns a list of Elm_Hoversel_Item* > + * @return Returns a list of Elm_Object_Item* > * > * @see elm_hoversel_item_add() > */ > @@ -15222,12 +15221,12 @@ > * For more information on what @p icon_file and @p icon_type are see the > * @ref Icon "icon documentation". > */ > - EAPI Elm_Hoversel_Item *elm_hoversel_item_add(Evas_Object *obj, const char > *label, const char *icon_file, Elm_Icon_Type icon_type, Evas_Smart_Cb func, > const void *data) EINA_ARG_NONNULL(1); > + EAPI Elm_Object_Item *elm_hoversel_item_add(Evas_Object *obj, const char > *label, const char *icon_file, Elm_Icon_Type icon_type, Evas_Smart_Cb func, > const void *data) EINA_ARG_NONNULL(1); > > /** > * @brief Delete an item from the hoversel > * > - * @param item The item to delete > + * @param it The item to delete > * > * This deletes the item from the hoversel (should not be called while the > * hoversel is active; use elm_hoversel_expanded_get() to check first). > @@ -15235,7 +15234,7 @@ > * @see elm_hoversel_item_add() > * @see elm_hoversel_item_del_cb_set() > */ > - EAPI void elm_hoversel_item_del(Elm_Hoversel_Item *item) > EINA_ARG_NONNULL(1); > + EAPI void elm_hoversel_item_del(Elm_Object_Item *it) EINA_ARG_NONNULL(1); > > /** > * @brief Set the function to be called when an item from the hoversel is > @@ -15245,34 +15244,34 @@ > * @param func The function called > * > * That function will receive these parameters: > - * @li void *item_data > - * @li Evas_Object *the_item_object > - * @li Elm_Hoversel_Item *the_object_struct > + * @li void * item data > + * @li Evas_Object * hoversel object > + * @li Elm_Object_Item * hoversel item > * > * @see elm_hoversel_item_add() > */ > - EAPI void elm_hoversel_item_del_cb_set(Elm_Hoversel_Item *it, Evas_Smart_Cb > func) EINA_ARG_NONNULL(1); > + EAPI void elm_hoversel_item_del_cb_set(Elm_Object_Item *it, Evas_Smart_Cb > func) EINA_ARG_NONNULL(1); > > /** > * @brief This returns the data pointer supplied with elm_hoversel_item_add() > * that will be passed to associated function callbacks. > * > - * @param item The item to get the data from > + * @param it The item to get the data from > * @return The data pointer set with elm_hoversel_item_add() > * > * @see elm_hoversel_item_add() > */ > - EAPI void *elm_hoversel_item_data_get(const Elm_Hoversel_Item *it) > EINA_ARG_NONNULL(1); > + EAPI void *elm_hoversel_item_data_get(const Elm_Object_Item *it) > EINA_ARG_NONNULL(1); > > /** > * @brief This returns the label text of the given hoversel item. > * > - * @param item The item to get the label > + * @param it The item to get the label > * @return The label text of the hoversel item > * > * @see elm_hoversel_item_add() > */ > - EAPI const char *elm_hoversel_item_label_get(const Elm_Hoversel_Item *it) > EINA_ARG_NONNULL(1); > + EAPI const char *elm_hoversel_item_label_get(const Elm_Object_Item *it) > EINA_ARG_NONNULL(1); > > /** > * @brief This sets the icon for the given hoversel item. > @@ -15289,7 +15288,7 @@ > * > * @see elm_hoversel_item_add() > */ > - EAPI void elm_hoversel_item_icon_set(Elm_Hoversel_Item *it, const char > *icon_file, const char *icon_group, Elm_Icon_Type icon_type) > EINA_ARG_NONNULL(1); > + EAPI void elm_hoversel_item_icon_set(Elm_Object_Item *it, const char > *icon_file, const char *icon_group, Elm_Icon_Type icon_type) > EINA_ARG_NONNULL(1); > > /** > * @brief Get the icon object of the hoversel item > @@ -15304,7 +15303,7 @@ > * @see elm_hoversel_item_icon_set() > * @see elm_hoversel_item_add() > */ > - EAPI void elm_hoversel_item_icon_get(const Elm_Hoversel_Item *it, const > char **icon_file, const char **icon_group, Elm_Icon_Type *icon_type) > EINA_ARG_NONNULL(1); > + EAPI void elm_hoversel_item_icon_get(const Elm_Object_Item *it, const char > **icon_file, const char **icon_group, Elm_Icon_Type *icon_type) > EINA_ARG_NONNULL(1); > > /** > * @} > Modified: trunk/elementary/src/lib/elc_hoversel.c > =================================================================== > --- trunk/elementary/src/lib/elc_hoversel.c 2011-12-19 21:59:31 UTC (rev > 66342) > +++ trunk/elementary/src/lib/elc_hoversel.c 2011-12-20 01:03:17 UTC (rev > 66343) > @@ -2,6 +2,7 @@ > #include "elm_priv.h" > > typedef struct _Widget_Data Widget_Data; > +typedef struct _Elm_Hoversel_Item Elm_Hoversel_Item; > > struct _Widget_Data > { > @@ -430,12 +431,12 @@ > EAPI void > elm_hoversel_clear(Evas_Object *obj) > { > - Elm_Hoversel_Item *item; > + Elm_Object_Item *it; > Eina_List *l, *ll; > ELM_CHECK_WIDTYPE(obj, widtype); > Widget_Data *wd = elm_widget_data_get(obj); > if (!wd) return; > - EINA_LIST_FOREACH_SAFE(wd->items, l, ll, item) elm_hoversel_item_del(item); > + EINA_LIST_FOREACH_SAFE(wd->items, l, ll, it) elm_hoversel_item_del(it); > } > > EAPI const Eina_List * > @@ -447,7 +448,7 @@ > return wd->items; > } > > -EAPI Elm_Hoversel_Item * > +EAPI Elm_Object_Item * > elm_hoversel_item_add(Evas_Object *obj, const char *label, const char > *icon_file, Elm_Icon_Type icon_type, Evas_Smart_Cb func, const void *data) > { > ELM_CHECK_WIDTYPE(obj, widtype) NULL; > @@ -461,14 +462,16 @@ > item->icon_type = icon_type; > item->func = func; > item->base.data = data; > - return item; > + return (Elm_Object_Item *) item; > } > > EAPI void > -elm_hoversel_item_del(Elm_Hoversel_Item *item) > +elm_hoversel_item_del(Elm_Object_Item *it) > { > - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(item); > - Widget_Data *wd = elm_widget_data_get(WIDGET(item)); > + ELM_OBJ_ITEM_CHECK_OR_RETURN(it); > + Widget_Data *wd; > + Elm_Hoversel_Item *item = (Elm_Hoversel_Item *) it; > + wd = elm_widget_data_get(WIDGET(item)); > if (!wd) return; > elm_hoversel_hover_end(WIDGET(item)); > wd->items = eina_list_remove(wd->items, item); > @@ -480,39 +483,41 @@ > } > > EAPI void > -elm_hoversel_item_del_cb_set(Elm_Hoversel_Item *item, Evas_Smart_Cb func) > +elm_hoversel_item_del_cb_set(Elm_Object_Item *it, Evas_Smart_Cb func) > { > - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(item); > - elm_widget_item_del_cb_set(item, func); > + ELM_OBJ_ITEM_CHECK_OR_RETURN(it); > + elm_widget_item_del_cb_set(it, func); > } > > EAPI void * > -elm_hoversel_item_data_get(const Elm_Hoversel_Item *item) > +elm_hoversel_item_data_get(const Elm_Object_Item *it) > { > - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(item, NULL); > - return elm_widget_item_data_get(item); > + ELM_OBJ_ITEM_CHECK_OR_RETURN(it, NULL); > + return elm_widget_item_data_get(it); > } > > EAPI const char * > -elm_hoversel_item_label_get(const Elm_Hoversel_Item *item) > +elm_hoversel_item_label_get(const Elm_Object_Item *it) > { > - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(item, NULL); > - return item->label; > + ELM_OBJ_ITEM_CHECK_OR_RETURN(it, NULL); > + return ((Elm_Hoversel_Item *) it)->label; > } > > EAPI void > -elm_hoversel_item_icon_set(Elm_Hoversel_Item *item, const char *icon_file, > const char *icon_group, Elm_Icon_Type icon_type) > +elm_hoversel_item_icon_set(Elm_Object_Item *it, const char *icon_file, const > char *icon_group, Elm_Icon_Type icon_type) > { > - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(item); > + ELM_OBJ_ITEM_CHECK_OR_RETURN(it); > + Elm_Hoversel_Item *item = (Elm_Hoversel_Item *) it; > eina_stringshare_replace(&item->icon_file, icon_file); > eina_stringshare_replace(&item->icon_group, icon_group); > item->icon_type = icon_type; > } > > EAPI void > -elm_hoversel_item_icon_get(const Elm_Hoversel_Item *item, const char > **icon_file, const char **icon_group, Elm_Icon_Type *icon_type) > +elm_hoversel_item_icon_get(const Elm_Object_Item *it, const char > **icon_file, const char **icon_group, Elm_Icon_Type *icon_type) > { > - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(item); > + ELM_OBJ_ITEM_CHECK_OR_RETURN(it); > + Elm_Hoversel_Item *item = (Elm_Hoversel_Item *) it; > if (icon_file) *icon_file = item->icon_file; > if (icon_group) *icon_group = item->icon_group; > if (icon_type) *icon_type = item->icon_type; > ------------------------------------------------------------------------------ > Write once. Port to many. > Get the SDK and tools to simplify cross-platform app development. Create > new or port existing apps to sell to consumers worldwide. Explore the > Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join > http://p.sf.net/sfu/intel-appdev > _______________________________________________ > enlightenment-svn mailing list > enlightenment-...@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/enlightenment-svn > ------------------------------------------------------------------------------ > Write once. Port to many. > Get the SDK and tools to simplify cross-platform app development. Create > new or port existing apps to sell to consumers worldwide. Explore the > Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join > http://p.sf.net/sfu/intel-appdev > _______________________________________________ > enlightenment-devel mailing list > enlightenment-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel ------------------------------------------------------------------------------ Write once. Port to many. Get the SDK and tools to simplify cross-platform app development. Create new or port existing apps to sell to consumers worldwide. Explore the Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join http://p.sf.net/sfu/intel-appdev _______________________________________________ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel