From: discomfitor Date: Sat, 22 Oct 2011 00:26:21 +0000 (+0000) Subject: deprecate all genlist/gengrid functions related to 64281 X-Git-Tag: REL_F_I9500_20120323_1~17^2~1531 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=fc0a954bba40e736c3cca1fb33645a05d6d63b47;p=framework%2Fuifw%2Felementary.git deprecate all genlist/gengrid functions related to 64281 git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/elementary@64282 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/src/bin/test_cursor.c b/src/bin/test_cursor.c index ef539c7..f14b80c 100644 --- a/src/bin/test_cursor.c +++ b/src/bin/test_cursor.c @@ -46,7 +46,7 @@ static void glt_exp(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info) { Elm_Genlist_Item *it = event_info; - Evas_Object *gl = elm_genlist_item_genlist_get(it); + Evas_Object *gl = elm_gen_item_widget_get(it); int val = (int)(long)elm_genlist_item_data_get(it); Elm_Genlist_Item *it1, *it2, *it3; diff --git a/src/bin/test_genlist.c b/src/bin/test_genlist.c index 7224fa7..05e14a4 100644 --- a/src/bin/test_genlist.c +++ b/src/bin/test_genlist.c @@ -296,13 +296,13 @@ my_gl_update_all(void *data, Evas_Object *obj __UNUSED__, void *event_info __UNU { Evas_Object *gl = data; int i = 0; - Elm_Genlist_Item *it = elm_genlist_first_item_get(gl); + Elm_Genlist_Item *it = elm_gen_first_item_get(gl); while (it) { elm_genlist_item_update(it); printf("%i\n", i); i++; - it = elm_genlist_item_next_get(it); + it = elm_gen_item_next_get(it); } } @@ -310,7 +310,7 @@ static void my_gl_first(void *data, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__) { Evas_Object *gl = data; - Elm_Genlist_Item *gli = elm_genlist_first_item_get(gl); + Elm_Genlist_Item *gli = elm_gen_first_item_get(gl); if (!gli) return; elm_genlist_item_show(gli); elm_gen_item_selected_set(gli, 1); @@ -320,7 +320,7 @@ static void my_gl_last(void *data, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__) { Evas_Object *gl = data; - Elm_Genlist_Item *gli = elm_genlist_last_item_get(gl); + Elm_Genlist_Item *gli = elm_gen_last_item_get(gl); if (!gli) return; elm_genlist_item_show(gli); elm_gen_item_selected_set(gli, 1); @@ -943,7 +943,7 @@ test_genlist5(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_in evas_object_show(bx); gl = elm_genlist_add(win); - elm_genlist_always_select_mode_set(gl, 1); + elm_gen_always_select_mode_set(gl, 1); evas_object_size_hint_align_set(gl, EVAS_HINT_FILL, EVAS_HINT_FILL); evas_object_size_hint_weight_set(gl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); evas_object_show(gl); @@ -1036,7 +1036,7 @@ static void gl4_exp(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info) { Elm_Genlist_Item *it = event_info; - Evas_Object *gl = elm_genlist_item_genlist_get(it); + Evas_Object *gl = elm_gen_item_widget_get(it); int val = (int)(long)elm_genlist_item_data_get(it); val *= 10; elm_genlist_item_append(gl, &itc4, @@ -1519,7 +1519,7 @@ static void gl9_exp(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info) { Elm_Genlist_Item *it = event_info; - Evas_Object *gl = elm_genlist_item_genlist_get(it); + Evas_Object *gl = elm_gen_item_widget_get(it); int val = (int)(long)elm_genlist_item_data_get(it); val *= 10; elm_genlist_item_append(gl, &itc1, diff --git a/src/bin/test_tooltip.c b/src/bin/test_tooltip.c index 2210fcf..dc1d822 100644 --- a/src/bin/test_tooltip.c +++ b/src/bin/test_tooltip.c @@ -52,7 +52,7 @@ gltt_exp(void *data __UNUSED__, void *event_info) { Elm_Genlist_Item *it = event_info; - Evas_Object *gl = elm_genlist_item_genlist_get(it); + Evas_Object *gl = elm_gen_item_widget_get(it); int val = (int)(long)elm_genlist_item_data_get(it); Elm_Genlist_Item *it1, *it2, *it3; diff --git a/src/edje_externals/elm_gengrid.c b/src/edje_externals/elm_gengrid.c index 6c3bf07..6130740 100644 --- a/src/edje_externals/elm_gengrid.c +++ b/src/edje_externals/elm_gengrid.c @@ -43,32 +43,32 @@ external_gengrid_state_set(void *data __UNUSED__, Evas_Object *obj, const void * if (p->multi_exists) elm_gengrid_multi_select_set(obj, p->multi); if (p->no_select_exists) - elm_gengrid_no_select_mode_set (obj, p->no_select); + elm_gen_no_select_mode_set (obj, p->no_select); if (p->always_select_exists) - elm_gengrid_always_select_mode_set (obj, p->always_select); + elm_gen_always_select_mode_set (obj, p->always_select); if (p->h_bounce_exists) { Eina_Bool h_bounce, v_bounce; - elm_gengrid_bounce_get(obj, &h_bounce, &v_bounce); - elm_gengrid_bounce_set(obj, p->h_bounce, v_bounce); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_set(obj, p->h_bounce, v_bounce); } if (p->v_bounce_exists) { Eina_Bool h_bounce, v_bounce; - elm_gengrid_bounce_get(obj, &h_bounce, &v_bounce); - elm_gengrid_bounce_set(obj, h_bounce, p->v_bounce); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_set(obj, h_bounce, p->v_bounce); } if (p->h_pagerel_exists) { double h_pagerel, v_pagerel; - elm_gengrid_page_relative_get(obj, &h_pagerel, &v_pagerel); - elm_gengrid_page_relative_set(obj, h_pagerel, p->v_pagerel); + elm_gen_page_relative_get(obj, &h_pagerel, &v_pagerel); + elm_gen_page_relative_set(obj, h_pagerel, p->v_pagerel); } if (p->v_pagerel_exists) { double h_pagerel, v_pagerel; - elm_gengrid_page_relative_get(obj, &h_pagerel, &v_pagerel); - elm_gengrid_page_relative_set(obj, p->h_pagerel, v_pagerel); + elm_gen_page_relative_get(obj, &h_pagerel, &v_pagerel); + elm_gen_page_relative_set(obj, p->h_pagerel, v_pagerel); } if (p->h_itemsize_exists) { @@ -112,7 +112,7 @@ external_gengrid_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E { if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { - elm_gengrid_no_select_mode_set(obj, param->i); + elm_gen_no_select_mode_set(obj, param->i); return EINA_TRUE; } } @@ -120,7 +120,7 @@ external_gengrid_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E { if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { - elm_gengrid_always_select_mode_set(obj, param->i); + elm_gen_always_select_mode_set(obj, param->i); return EINA_TRUE; } } @@ -129,8 +129,8 @@ external_gengrid_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { Eina_Bool h_bounce, v_bounce; - elm_gengrid_bounce_get(obj, &h_bounce, &v_bounce); - elm_gengrid_bounce_set(obj, param->i, v_bounce); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_set(obj, param->i, v_bounce); return EINA_TRUE; } } @@ -139,8 +139,8 @@ external_gengrid_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { Eina_Bool h_bounce, v_bounce; - elm_gengrid_bounce_get(obj, &h_bounce, &v_bounce); - elm_gengrid_bounce_set(obj, h_bounce, param->i); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_set(obj, h_bounce, param->i); return EINA_TRUE; } } @@ -149,8 +149,8 @@ external_gengrid_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_DOUBLE) { double h_pagerel, v_pagerel; - elm_gengrid_page_relative_get(obj, &h_pagerel, &v_pagerel); - elm_gengrid_page_relative_set(obj, param->d, v_pagerel); + elm_gen_page_relative_get(obj, &h_pagerel, &v_pagerel); + elm_gen_page_relative_set(obj, param->d, v_pagerel); return EINA_TRUE; } } @@ -159,8 +159,8 @@ external_gengrid_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_DOUBLE) { double h_pagerel, v_pagerel; - elm_gengrid_page_relative_get(obj, &h_pagerel, &v_pagerel); - elm_gengrid_page_relative_set(obj, h_pagerel, param->d); + elm_gen_page_relative_get(obj, &h_pagerel, &v_pagerel); + elm_gen_page_relative_set(obj, h_pagerel, param->d); return EINA_TRUE; } } @@ -229,7 +229,7 @@ external_gengrid_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E { if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { - param->i = elm_gengrid_no_select_mode_get(obj); + param->i = elm_gen_no_select_mode_get(obj); return EINA_TRUE; } } @@ -237,7 +237,7 @@ external_gengrid_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E { if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { - param->i = elm_gengrid_always_select_mode_get(obj); + param->i = elm_gen_always_select_mode_get(obj); return EINA_TRUE; } } @@ -246,7 +246,7 @@ external_gengrid_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { Eina_Bool h_bounce, v_bounce; - elm_gengrid_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); param->i = h_bounce; return EINA_TRUE; } @@ -256,7 +256,7 @@ external_gengrid_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { Eina_Bool h_bounce, v_bounce; - elm_gengrid_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); param->i = v_bounce; return EINA_TRUE; } @@ -266,7 +266,7 @@ external_gengrid_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_DOUBLE) { double h_pagerel, v_pagerel; - elm_gengrid_page_relative_get(obj, &h_pagerel, &v_pagerel); + elm_gen_page_relative_get(obj, &h_pagerel, &v_pagerel); param->d = h_pagerel; return EINA_TRUE; } @@ -276,7 +276,7 @@ external_gengrid_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_DOUBLE) { double h_pagerel, v_pagerel; - elm_gengrid_page_relative_get(obj, &h_pagerel, &v_pagerel); + elm_gen_page_relative_get(obj, &h_pagerel, &v_pagerel); param->d = v_pagerel; return EINA_TRUE; } diff --git a/src/edje_externals/elm_genlist.c b/src/edje_externals/elm_genlist.c index 75fb908..e2f5e56 100644 --- a/src/edje_externals/elm_genlist.c +++ b/src/edje_externals/elm_genlist.c @@ -58,24 +58,24 @@ external_genlist_state_set(void *data __UNUSED__, Evas_Object *obj, const void * if (p->multi_exists) elm_genlist_multi_select_set(obj, p->multi); if (p->always_select_exists) - elm_genlist_always_select_mode_set(obj, p->always_select); + elm_gen_always_select_mode_set(obj, p->always_select); if (p->no_select_exists) - elm_genlist_no_select_mode_set(obj, p->no_select); + elm_gen_no_select_mode_set(obj, p->no_select); if (p->compress_exists) elm_genlist_compress_mode_set(obj, p->compress); if (p->homogeneous_exists) elm_genlist_homogeneous_set(obj, p->homogeneous); if ((p->h_bounce_exists) && (p->v_bounce_exists)) - elm_genlist_bounce_set(obj, p->h_bounce, p->v_bounce); + elm_gen_bounce_set(obj, p->h_bounce, p->v_bounce); else if ((p->h_bounce_exists) || (p->v_bounce_exists)) { Eina_Bool h_bounce, v_bounce; - elm_genlist_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); if (p->h_bounce_exists) - elm_genlist_bounce_set(obj, p->h_bounce, v_bounce); + elm_gen_bounce_set(obj, p->h_bounce, v_bounce); else - elm_genlist_bounce_set(obj, h_bounce, p->v_bounce); + elm_gen_bounce_set(obj, h_bounce, p->v_bounce); } } @@ -105,7 +105,7 @@ external_genlist_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E { if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { - elm_genlist_always_select_mode_set(obj, param->i); + elm_gen_always_select_mode_set(obj, param->i); return EINA_TRUE; } } @@ -113,7 +113,7 @@ external_genlist_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E { if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { - elm_genlist_no_select_mode_set(obj, param->i); + elm_gen_no_select_mode_set(obj, param->i); return EINA_TRUE; } } @@ -138,8 +138,8 @@ external_genlist_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { Eina_Bool h_bounce, v_bounce; - elm_genlist_bounce_get(obj, &h_bounce, &v_bounce); - elm_genlist_bounce_set(obj, param->i, v_bounce); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_set(obj, param->i, v_bounce); return EINA_TRUE; } } @@ -148,8 +148,8 @@ external_genlist_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { Eina_Bool h_bounce, v_bounce; - elm_genlist_bounce_get(obj, &h_bounce, &v_bounce); - elm_genlist_bounce_set(obj, h_bounce, param->i); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_set(obj, h_bounce, param->i); return EINA_TRUE; } } @@ -188,7 +188,7 @@ external_genlist_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E { if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { - param->i = elm_genlist_always_select_mode_get(obj); + param->i = elm_gen_always_select_mode_get(obj); return EINA_TRUE; } } @@ -196,7 +196,7 @@ external_genlist_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E { if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { - param->i = elm_genlist_no_select_mode_get(obj); + param->i = elm_gen_no_select_mode_get(obj); return EINA_TRUE; } } @@ -221,7 +221,7 @@ external_genlist_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { Eina_Bool h_bounce, v_bounce; - elm_genlist_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); param->i = h_bounce; return EINA_TRUE; } @@ -231,7 +231,7 @@ external_genlist_param_get(void *data __UNUSED__, const Evas_Object *obj, Edje_E if (param->type == EDJE_EXTERNAL_PARAM_TYPE_BOOL) { Eina_Bool h_bounce, v_bounce; - elm_genlist_bounce_get(obj, &h_bounce, &v_bounce); + elm_gen_bounce_get(obj, &h_bounce, &v_bounce); param->i = v_bounce; return EINA_TRUE; } diff --git a/src/lib/Elementary.h.in b/src/lib/Elementary.h.in index fc80c3c..b8f0016 100644 --- a/src/lib/Elementary.h.in +++ b/src/lib/Elementary.h.in @@ -7940,7 +7940,7 @@ extern "C" { EAPI Elm_Gen_Item *elm_gen_last_item_get(const Evas_Object *obj); EAPI Elm_Gen_Item *elm_gen_item_next_get(const Elm_Gen_Item *it); EAPI Elm_Gen_Item *elm_gen_item_prev_get(const Elm_Gen_Item *it); - EAPI Evas_Object *elm_gen_item_gen_get(const Elm_Gen_Item *it); + EAPI Evas_Object *elm_gen_item_widget_get(const Elm_Gen_Item *it); /** * @defgroup Gengrid Gengrid (Generic grid) @@ -8463,7 +8463,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI void elm_gengrid_always_select_mode_set(Evas_Object *obj, Eina_Bool always_select) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_always_select_mode_set(Evas_Object *obj, Eina_Bool always_select) EINA_ARG_NONNULL(1); /** * Get whether items on a given gengrid widget have their selection @@ -8478,7 +8478,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI Eina_Bool elm_gengrid_always_select_mode_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Eina_Bool elm_gengrid_always_select_mode_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); /** * Set whether items on a given gengrid widget can be selected or not. @@ -8496,7 +8496,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI void elm_gengrid_no_select_mode_set(Evas_Object *obj, Eina_Bool no_select) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_no_select_mode_set(Evas_Object *obj, Eina_Bool no_select) EINA_ARG_NONNULL(1); /** * Get whether items on a given gengrid widget can be selected or @@ -8510,7 +8510,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI Eina_Bool elm_gengrid_no_select_mode_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Eina_Bool elm_gengrid_no_select_mode_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); /** * Enable or disable multi-selection in a given gengrid widget @@ -8568,7 +8568,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI void elm_gengrid_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce) EINA_ARG_NONNULL(1); /** * Get whether bouncing effects are enabled or disabled, for a @@ -8584,7 +8584,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI void elm_gengrid_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce) EINA_ARG_NONNULL(1); /** * Set a given gengrid widget's scrolling page size, relative to @@ -8618,7 +8618,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI void elm_gengrid_page_relative_set(Evas_Object *obj, double h_pagerel, double v_pagerel) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_page_relative_set(Evas_Object *obj, double h_pagerel, double v_pagerel) EINA_ARG_NONNULL(1); /** * Get a given gengrid widget's scrolling page size, relative to @@ -8634,7 +8634,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI void elm_gengrid_page_relative_get(const Evas_Object *obj, double *h_pagerel, double *v_pagerel) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_page_relative_get(const Evas_Object *obj, double *h_pagerel, double *v_pagerel) EINA_ARG_NONNULL(1); /** * Set a given gengrid widget's scrolling page size @@ -8662,7 +8662,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI void elm_gengrid_page_size_set(Evas_Object *obj, Evas_Coord h_pagesize, Evas_Coord v_pagesize) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_page_size_set(Evas_Object *obj, Evas_Coord h_pagesize, Evas_Coord v_pagesize) EINA_ARG_NONNULL(1); /** * @brief Get gengrid current page number. @@ -8680,7 +8680,7 @@ extern "C" { * @see elm_gengrid_page_show() * @see elm_gengrid_page_brint_in() */ - EAPI void elm_gengrid_current_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_current_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber) EINA_ARG_NONNULL(1); /** * @brief Get scroll last page number. @@ -8696,7 +8696,7 @@ extern "C" { * @see elm_gengrid_page_show() * @see elm_gengrid_page_brint_in() */ - EAPI void elm_gengrid_last_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_last_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber) EINA_ARG_NONNULL(1); /** * Show a specific virtual region within the gengrid content object by page number. @@ -8720,7 +8720,7 @@ extern "C" { * * @see elm_gengrid_page_bring_in() */ - EAPI void elm_gengrid_page_show(const Evas_Object *obj, int h_pagenumber, int v_pagenumber) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_page_show(const Evas_Object *obj, int h_pagenumber, int v_pagenumber) EINA_ARG_NONNULL(1); /** * Show a specific virtual region within the gengrid content object by page number. @@ -8744,7 +8744,7 @@ extern "C" { * * @see elm_gengrid_page_show() */ - EAPI void elm_gengrid_page_bring_in(const Evas_Object *obj, int h_pagenumber, int v_pagenumber) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_gengrid_page_bring_in(const Evas_Object *obj, int h_pagenumber, int v_pagenumber) EINA_ARG_NONNULL(1); /** * Set for what direction a given gengrid widget will expand while @@ -8796,7 +8796,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI Elm_Gengrid_Item *elm_gengrid_first_item_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Elm_Gengrid_Item *elm_gengrid_first_item_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); /** * Get the last item in a given gengrid widget @@ -8812,7 +8812,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI Elm_Gengrid_Item *elm_gengrid_last_item_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Elm_Gengrid_Item *elm_gengrid_last_item_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); /** * Get the @b next item in a gengrid widget's internal list of items, @@ -8829,7 +8829,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI Elm_Gengrid_Item *elm_gengrid_item_next_get(const Elm_Gengrid_Item *item) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Elm_Gengrid_Item *elm_gengrid_item_next_get(const Elm_Gengrid_Item *item) EINA_ARG_NONNULL(1); /** * Get the @b previous item in a gengrid widget's internal list of items, @@ -8846,7 +8846,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI Elm_Gengrid_Item *elm_gengrid_item_prev_get(const Elm_Gengrid_Item *item) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Elm_Gengrid_Item *elm_gengrid_item_prev_get(const Elm_Gengrid_Item *item) EINA_ARG_NONNULL(1); /** * Get the gengrid object's handle which contains a given gengrid @@ -8859,7 +8859,7 @@ extern "C" { * * @ingroup Gengrid */ - EAPI Evas_Object *elm_gengrid_item_gengrid_get(const Elm_Gengrid_Item *item) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Evas_Object *elm_gengrid_item_gengrid_get(const Elm_Gengrid_Item *item) EINA_ARG_NONNULL(1); /** * Remove a gengrid item from the its parent, deleting it. @@ -18289,7 +18289,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI void elm_genlist_always_select_mode_set(Evas_Object *obj, Eina_Bool always_select) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_genlist_always_select_mode_set(Evas_Object *obj, Eina_Bool always_select) EINA_ARG_NONNULL(1); /** * Get the always select mode. * @@ -18301,7 +18301,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI Eina_Bool elm_genlist_always_select_mode_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Eina_Bool elm_genlist_always_select_mode_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); /** * Enable/disable the no select mode. * @@ -18316,7 +18316,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI void elm_genlist_no_select_mode_set(Evas_Object *obj, Eina_Bool no_select) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_genlist_no_select_mode_set(Evas_Object *obj, Eina_Bool no_select) EINA_ARG_NONNULL(1); /** * Gets whether the no select mode is enabled. * @@ -18328,7 +18328,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI Eina_Bool elm_genlist_no_select_mode_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Eina_Bool elm_genlist_no_select_mode_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); /** * Enable/disable compress mode. * @@ -18410,7 +18410,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI void elm_genlist_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_genlist_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce) EINA_ARG_NONNULL(1); /** * Get whether the horizontal and vertical bouncing effect is enabled. * @@ -18424,7 +18424,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI void elm_genlist_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI void elm_genlist_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce) EINA_ARG_NONNULL(1); /** * Enable/disable homogenous mode. * @@ -18742,7 +18742,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI Elm_Genlist_Item *elm_genlist_first_item_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Elm_Genlist_Item *elm_genlist_first_item_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); /** * Get the last item in the genlist * @@ -18752,7 +18752,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI Elm_Genlist_Item *elm_genlist_last_item_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Elm_Genlist_Item *elm_genlist_last_item_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); /** * Set the scrollbar policy * @@ -18800,7 +18800,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI Elm_Genlist_Item *elm_genlist_item_next_get(const Elm_Genlist_Item *item) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Elm_Genlist_Item *elm_genlist_item_next_get(const Elm_Genlist_Item *item) EINA_ARG_NONNULL(1); /** * Get the @b previous item in a genlist widget's internal list of items, * given a handle to one of those items. @@ -18816,7 +18816,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI Elm_Genlist_Item *elm_genlist_item_prev_get(const Elm_Genlist_Item *item) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Elm_Genlist_Item *elm_genlist_item_prev_get(const Elm_Genlist_Item *item) EINA_ARG_NONNULL(1); /** * Get the genlist object's handle which contains a given genlist * item @@ -18828,7 +18828,7 @@ extern "C" { * * @ingroup Genlist */ - EAPI Evas_Object *elm_genlist_item_genlist_get(const Elm_Genlist_Item *item) EINA_ARG_NONNULL(1); + EINA_DEPRECATED EAPI Evas_Object *elm_genlist_item_genlist_get(const Elm_Genlist_Item *item) EINA_ARG_NONNULL(1); /** * Get the parent item of the given item * diff --git a/src/lib/elm_gen.c b/src/lib/elm_gen.c index e585818..0d66974 100644 --- a/src/lib/elm_gen.c +++ b/src/lib/elm_gen.c @@ -724,7 +724,7 @@ elm_gen_item_prev_get(const Elm_Gen_Item *it) } EAPI Evas_Object * -elm_gen_item_gen_get(const Elm_Gen_Item *it) +elm_gen_item_widget_get(const Elm_Gen_Item *it) { ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(it, NULL); return WIDGET(it); diff --git a/src/lib/elm_gengrid.c b/src/lib/elm_gengrid.c index 04a4e71..b189b5d 100644 --- a/src/lib/elm_gengrid.c +++ b/src/lib/elm_gengrid.c @@ -280,14 +280,14 @@ _event_hook(Evas_Object *obj, } else if ((!strcmp(ev->keyname, "Home")) || (!strcmp(ev->keyname, "KP_Home"))) { - it = elm_gengrid_first_item_get(obj); + it = elm_gen_first_item_get(obj); elm_gengrid_item_bring_in(it); ev->event_flags |= EVAS_EVENT_FLAG_ON_HOLD; return EINA_TRUE; } else if ((!strcmp(ev->keyname, "End")) || (!strcmp(ev->keyname, "KP_End"))) { - it = elm_gengrid_last_item_get(obj); + it = elm_gen_last_item_get(obj); elm_gengrid_item_bring_in(it); ev->event_flags |= EVAS_EVENT_FLAG_ON_HOLD; return EINA_TRUE; @@ -361,7 +361,7 @@ _item_multi_select_left(Widget_Data *wd) { if (!wd->selected) return EINA_FALSE; - Elm_Gen_Item *prev = elm_gengrid_item_prev_get(wd->last_selected_item); + Elm_Gen_Item *prev = elm_gen_item_prev_get(wd->last_selected_item); if (!prev) return EINA_TRUE; if (elm_gen_item_selected_get(prev)) { @@ -383,7 +383,7 @@ _item_multi_select_right(Widget_Data *wd) { if (!wd->selected) return EINA_FALSE; - Elm_Gen_Item *next = elm_gengrid_item_next_get(wd->last_selected_item); + Elm_Gen_Item *next = elm_gen_item_next_get(wd->last_selected_item); if (!next) return EINA_TRUE; if (elm_gen_item_selected_get(next)) { @@ -444,13 +444,13 @@ _item_single_select_up(Widget_Data *wd) elm_gengrid_item_show(prev); return EINA_TRUE; } - else prev = elm_gengrid_item_prev_get(wd->last_selected_item); + else prev = elm_gen_item_prev_get(wd->last_selected_item); if (!prev) return EINA_FALSE; for (i = 1; i < wd->nmax; i++) { - Elm_Gen_Item *tmp = elm_gengrid_item_prev_get(prev); + Elm_Gen_Item *tmp = elm_gen_item_prev_get(prev); if (!tmp) return EINA_FALSE; prev = tmp; } @@ -478,13 +478,13 @@ _item_single_select_down(Widget_Data *wd) elm_gengrid_item_show(next); return EINA_TRUE; } - else next = elm_gengrid_item_next_get(wd->last_selected_item); + else next = elm_gen_item_next_get(wd->last_selected_item); if (!next) return EINA_FALSE; for (i = 1; i < wd->nmax; i++) { - Elm_Gen_Item *tmp = elm_gengrid_item_next_get(next); + Elm_Gen_Item *tmp = elm_gen_item_next_get(next); if (!tmp) return EINA_FALSE; next = tmp; } @@ -506,7 +506,7 @@ _item_single_select_left(Widget_Data *wd) while ((prev) && (prev->delete_me)) prev = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(prev)->prev); } - else prev = elm_gengrid_item_prev_get(wd->last_selected_item); + else prev = elm_gen_item_prev_get(wd->last_selected_item); if (!prev) return EINA_FALSE; @@ -527,7 +527,7 @@ _item_single_select_right(Widget_Data *wd) while ((next) && (next->delete_me)) next = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(next)->next); } - else next = elm_gengrid_item_next_get(wd->last_selected_item); + else next = elm_gen_item_next_get(wd->last_selected_item); if (!next) return EINA_FALSE; @@ -2558,38 +2558,26 @@ EAPI void elm_gengrid_always_select_mode_set(Evas_Object *obj, Eina_Bool always_select) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - wd->always_select = always_select; + elm_gen_always_select_mode_set(obj, always_select); } EAPI Eina_Bool elm_gengrid_always_select_mode_get(const Evas_Object *obj) { - ELM_CHECK_WIDTYPE(obj, widtype) EINA_FALSE; - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return EINA_FALSE; - return wd->always_select; + return elm_gen_always_select_mode_get(obj); } EAPI void elm_gengrid_no_select_mode_set(Evas_Object *obj, Eina_Bool no_select) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - wd->no_select = no_select; + elm_gen_no_select_mode_set(obj, no_select); } EAPI Eina_Bool elm_gengrid_no_select_mode_get(const Evas_Object *obj) { - ELM_CHECK_WIDTYPE(obj, widtype) EINA_FALSE; - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return EINA_FALSE; - return wd->no_select; + return elm_gen_no_select_mode_get(obj); } EAPI void @@ -2597,12 +2585,7 @@ elm_gengrid_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - elm_smart_scroller_bounce_allow_set(wd->scr, h_bounce, v_bounce); - wd->h_bounce = h_bounce; - wd->v_bounce = v_bounce; + elm_gen_bounce_set(obj, h_bounce, v_bounce); } EAPI void @@ -2610,11 +2593,7 @@ elm_gengrid_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - if (h_bounce) *h_bounce = wd->h_bounce; - if (v_bounce) *v_bounce = wd->v_bounce; + return elm_gen_bounce_get(obj, h_bounce, v_bounce); } EAPI void @@ -2622,26 +2601,13 @@ elm_gengrid_page_relative_set(Evas_Object *obj, double h_pagerel, double v_pagerel) { - Evas_Coord pagesize_h; - Evas_Coord pagesize_v; - - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - - elm_smart_scroller_paging_get(wd->scr, NULL, NULL, &pagesize_h, &pagesize_v); - elm_smart_scroller_paging_set(wd->scr, h_pagerel, v_pagerel, pagesize_h, - pagesize_v); + elm_gen_page_relative_set(obj, h_pagerel, v_pagerel); } EAPI void elm_gengrid_page_relative_get(const Evas_Object *obj, double *h_pagerel, double *v_pagerel) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - - elm_smart_scroller_paging_get(wd->scr, h_pagerel, v_pagerel, NULL, NULL); + elm_gen_page_relative_get(obj, h_pagerel, v_pagerel); } EAPI void @@ -2649,112 +2615,61 @@ elm_gengrid_page_size_set(Evas_Object *obj, Evas_Coord h_pagesize, Evas_Coord v_pagesize) { - double pagerel_h; - double pagerel_v; - - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - elm_smart_scroller_paging_get(wd->scr, &pagerel_h, &pagerel_v, NULL, NULL); - elm_smart_scroller_paging_set(wd->scr, pagerel_h, pagerel_v, h_pagesize, - v_pagesize); + elm_gen_page_size_set(obj, h_pagesize, v_pagesize); } EAPI void elm_gengrid_current_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - if (wd->scr) - elm_smart_scroller_current_page_get(wd->scr, h_pagenumber, v_pagenumber); + elm_gen_current_page_get(obj, h_pagenumber, v_pagenumber); } EAPI void elm_gengrid_last_page_get(const Evas_Object *obj, int *h_pagenumber, int *v_pagenumber) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - if (wd->scr) - elm_smart_scroller_last_page_get(wd->scr, h_pagenumber, v_pagenumber); + elm_gen_last_page_get(obj, h_pagenumber, v_pagenumber); } EAPI void elm_gengrid_page_show(const Evas_Object *obj, int h_pagenumber, int v_pagenumber) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - if (wd->scr) - elm_smart_scroller_page_show(wd->scr, h_pagenumber, v_pagenumber); + elm_gen_page_show(obj, h_pagenumber, v_pagenumber); } EAPI void elm_gengrid_page_bring_in(const Evas_Object *obj, int h_pagenumber, int v_pagenumber) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - if (wd->scr) - elm_smart_scroller_page_bring_in(wd->scr, h_pagenumber, v_pagenumber); + elm_gen_page_bring_in(obj, h_pagenumber, v_pagenumber); } EAPI Elm_Gen_Item * elm_gengrid_first_item_get(const Evas_Object *obj) { - ELM_CHECK_WIDTYPE(obj, widtype) NULL; - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return NULL; - if (!wd->items) return NULL; - Elm_Gen_Item *it = ELM_GEN_ITEM_FROM_INLIST(wd->items); - while ((it) && (it->delete_me)) - it = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(it)->next); - return it; + return elm_gen_first_item_get(obj); } EAPI Elm_Gen_Item * elm_gengrid_last_item_get(const Evas_Object *obj) { - ELM_CHECK_WIDTYPE(obj, widtype) NULL; - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return NULL; - if (!wd->items) return NULL; - Elm_Gen_Item *it = ELM_GEN_ITEM_FROM_INLIST(wd->items->last); - while ((it) && (it->delete_me)) - it = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(it)->prev); - return it; + return elm_gen_last_item_get(obj); } EAPI Elm_Gen_Item * elm_gengrid_item_next_get(const Elm_Gen_Item *it) { - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(it, NULL); - while (it) - { - it = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(it)->next); - if ((it) && (!it->delete_me)) break; - } - return (Elm_Gen_Item *)it; + return elm_gen_item_next_get(it); } EAPI Elm_Gen_Item * elm_gengrid_item_prev_get(const Elm_Gen_Item *it) { - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(it, NULL); - while (it) - { - it = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(it)->prev); - if ((it) && (!it->delete_me)) break; - } - return (Elm_Gen_Item *)it; + return elm_gen_item_prev_get(it); } EAPI Evas_Object * elm_gengrid_item_gengrid_get(const Elm_Gen_Item *it) { - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(it, NULL); - return WIDGET(it); + return elm_gen_item_widget_get(it); } EAPI void diff --git a/src/lib/elm_genlist.c b/src/lib/elm_genlist.c index 3a86a41..01520b1 100644 --- a/src/lib/elm_genlist.c +++ b/src/lib/elm_genlist.c @@ -359,14 +359,14 @@ _event_hook(Evas_Object *obj, } else if ((!strcmp(ev->keyname, "Home")) || (!strcmp(ev->keyname, "KP_Home"))) { - it = elm_genlist_first_item_get(obj); + it = elm_gen_first_item_get(obj); elm_genlist_item_bring_in(it); ev->event_flags |= EVAS_EVENT_FLAG_ON_HOLD; return EINA_TRUE; } else if ((!strcmp(ev->keyname, "End")) || (!strcmp(ev->keyname, "KP_End"))) { - it = elm_genlist_last_item_get(obj); + it = elm_gen_last_item_get(obj); elm_genlist_item_bring_in(it); ev->event_flags |= EVAS_EVENT_FLAG_ON_HOLD; return EINA_TRUE; @@ -429,7 +429,7 @@ _item_multi_select_up(Widget_Data *wd) if (!wd->selected) return EINA_FALSE; if (!wd->multi) return EINA_FALSE; - Elm_Gen_Item *prev = elm_genlist_item_prev_get(wd->last_selected_item); + Elm_Gen_Item *prev = elm_gen_item_prev_get(wd->last_selected_item); if (!prev) return EINA_TRUE; if (elm_gen_item_selected_get(prev)) @@ -452,7 +452,7 @@ _item_multi_select_down(Widget_Data *wd) if (!wd->selected) return EINA_FALSE; if (!wd->multi) return EINA_FALSE; - Elm_Gen_Item *next = elm_genlist_item_next_get(wd->last_selected_item); + Elm_Gen_Item *next = elm_gen_item_next_get(wd->last_selected_item); if (!next) return EINA_TRUE; if (elm_gen_item_selected_get(next)) @@ -479,7 +479,7 @@ _item_single_select_up(Widget_Data *wd) while ((prev) && (prev->delete_me)) prev = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(prev)->prev); } - else prev = elm_genlist_item_prev_get(wd->last_selected_item); + else prev = elm_gen_item_prev_get(wd->last_selected_item); if (!prev) return EINA_FALSE; @@ -500,7 +500,7 @@ _item_single_select_down(Widget_Data *wd) while ((next) && (next->delete_me)) next = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(next)->next); } - else next = elm_genlist_item_next_get(wd->last_selected_item); + else next = elm_gen_item_next_get(wd->last_selected_item); if (!next) return EINA_FALSE; @@ -3799,58 +3799,31 @@ elm_genlist_at_xy_item_get(const Evas_Object *obj, EAPI Elm_Gen_Item * elm_genlist_first_item_get(const Evas_Object *obj) { - ELM_CHECK_WIDTYPE(obj, widtype) NULL; - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return NULL; - if (!wd->items) return NULL; - Elm_Gen_Item *it = ELM_GEN_ITEM_FROM_INLIST(wd->items); - while ((it) && (it->delete_me)) - it = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(it)->next); - return it; + return elm_gen_first_item_get(obj); } EAPI Elm_Gen_Item * elm_genlist_last_item_get(const Evas_Object *obj) { - ELM_CHECK_WIDTYPE(obj, widtype) NULL; - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return NULL; - if (!wd->items) return NULL; - Elm_Gen_Item *it = ELM_GEN_ITEM_FROM_INLIST(wd->items->last); - while ((it) && (it->delete_me)) - it = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(it)->prev); - return it; + return elm_gen_last_item_get(obj); } EAPI Elm_Gen_Item * elm_genlist_item_next_get(const Elm_Gen_Item *it) { - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(it, NULL); - while (it) - { - it = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(it)->next); - if ((it) && (!it->delete_me)) break; - } - return (Elm_Gen_Item *)it; + return elm_gen_item_next_get(it); } EAPI Elm_Gen_Item * elm_genlist_item_prev_get(const Elm_Gen_Item *it) { - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(it, NULL); - while (it) - { - it = ELM_GEN_ITEM_FROM_INLIST(EINA_INLIST_GET(it)->prev); - if ((it) && (!it->delete_me)) break; - } - return (Elm_Gen_Item *)it; + return elm_gen_item_prev_get(it); } EAPI Evas_Object * elm_genlist_item_genlist_get(const Elm_Gen_Item *it) { - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(it, NULL); - return WIDGET(it); + return elm_gen_item_widget_get(it); } EAPI Elm_Gen_Item * @@ -3883,8 +3856,7 @@ elm_genlist_item_selected_set(Elm_Gen_Item *it, EAPI Eina_Bool elm_genlist_item_selected_get(const Elm_Gen_Item *it) { - ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(it, EINA_FALSE); - return it->selected; + return elm_gen_item_selected_get(it); } EAPI void @@ -4443,38 +4415,26 @@ EAPI void elm_genlist_always_select_mode_set(Evas_Object *obj, Eina_Bool always_select) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - wd->always_select = always_select; + elm_gen_always_select_mode_set(obj, always_select); } EAPI Eina_Bool elm_genlist_always_select_mode_get(const Evas_Object *obj) { - ELM_CHECK_WIDTYPE(obj, widtype) EINA_FALSE; - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return EINA_FALSE; - return wd->always_select; + return elm_gen_always_select_mode_get(obj); } EAPI void elm_genlist_no_select_mode_set(Evas_Object *obj, Eina_Bool no_select) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - wd->no_select = no_select; + elm_gen_no_select_mode_set(obj, no_select); } EAPI Eina_Bool elm_genlist_no_select_mode_get(const Evas_Object *obj) { - ELM_CHECK_WIDTYPE(obj, widtype) EINA_FALSE; - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return EINA_FALSE; - return wd->no_select; + return elm_gen_no_select_mode_get(obj); } EAPI void @@ -4526,12 +4486,7 @@ elm_genlist_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - elm_smart_scroller_bounce_allow_set(wd->scr, h_bounce, v_bounce); - wd->h_bounce = h_bounce; - wd->v_bounce = v_bounce; + elm_gen_bounce_set(obj, h_bounce, v_bounce); } EAPI void @@ -4539,11 +4494,7 @@ elm_genlist_bounce_get(const Evas_Object *obj, Eina_Bool *h_bounce, Eina_Bool *v_bounce) { - ELM_CHECK_WIDTYPE(obj, widtype); - Widget_Data *wd = elm_widget_data_get(obj); - if (!wd) return; - if (h_bounce) *h_bounce = wd->h_bounce; - if (v_bounce) *v_bounce = wd->v_bounce; + elm_gen_bounce_get(obj, h_bounce, v_bounce); } EAPI void