Genlist: Test case added in Genlist Focus example.

Summary:
Added test case to enable/disable mouse wheel. Mouse Wheel is
used to scroll the genlist up/down.

Signed-off-by: Umesh Tanwar <umesh.tanwar@samsung.com>

Test Plan: elementary_test -> Genlist Focus -> Wheel Disabled

Reviewers: raster, Hermet, cedric

Subscribers: sachin.dev, singh.amitesh, SanghyeonLee, eagleeye

Differential Revision: https://phab.enlightenment.org/D2757
This commit is contained in:
Umesh Tanwar 2015-06-25 13:24:21 +09:00 committed by ChunEon Park
parent 50fa3bfe7c
commit ddbea82857
1 changed files with 15 additions and 0 deletions

View File

@ -4273,6 +4273,13 @@ _gl_first_item_focus_on_first_focus_in_cb(void *data EINA_UNUSED, Evas_Object *o
{
elm_config_first_item_focus_on_first_focusin_set(elm_check_state_get(obj));
}
static void
_gl_wheel_disabled_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
elm_scroller_wheel_disabled_set(data, elm_check_state_get(obj));
}
static Eina_Bool
_focus_timer_cb(void *data)
{
@ -4493,6 +4500,14 @@ _test_genlist_focus_option_panel_create(Evas_Object *win, Evas_Object *bx,
elm_box_pack_end(bx_opt, chk);
evas_object_show(chk);
chk = elm_check_add(bx_opt);
elm_object_text_set(chk, "Wheel Disabled");
elm_check_state_set(chk, elm_scroller_wheel_disabled_get(gl));
evas_object_size_hint_weight_set(chk, EVAS_HINT_EXPAND, 0.0);
evas_object_smart_callback_add(chk, "changed", _gl_wheel_disabled_cb, gl);
elm_box_pack_end(bx_opt, chk);
evas_object_show(chk);
// Focus Autoscroll Mode
fr = _focus_autoscroll_mode_frame_create(bx);
elm_box_pack_end(bx, fr);