summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChinmaya <chinmaya@chinmaya-VirtualBox.(none)>2014-07-07 12:30:21 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2014-07-07 12:30:21 +0900
commit05b40f52d896b49e35a88b06b28507878da1600d (patch)
tree8171e572471ce329db2bdca382ab4427fd06c2c7
parentaef8aeb9b8d0187f8c01a507b93b128fe88410a3 (diff)
Gengrid: In reorder & sd->horizontal mode, the condition must be checked for item_loop_enable set or not. Also added a check button to enable reorder mode in gengrid 2.
Summary: The bug was there when reorder mode and sd->horizontal mode is enabled but item_loop_enable is not set, then also the loop was occuring with right key event. Test Plan: elementary_test -to "gengrid 2" Reviewers: raster, seoz, eagleeye, SanghyeonLee CC: seoz Differential Revision: https://phab.enlightenment.org/D1121
-rw-r--r--src/bin/test_gengrid.c6
-rw-r--r--src/lib/elm_gengrid.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/src/bin/test_gengrid.c b/src/bin/test_gengrid.c
index 847b66d87..ba69f37fa 100644
--- a/src/bin/test_gengrid.c
+++ b/src/bin/test_gengrid.c
@@ -829,6 +829,12 @@ test_gengrid2(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_
829 evas_object_show(bt); 829 evas_object_show(bt);
830 830
831 ck = elm_check_add(win); 831 ck = elm_check_add(win);
832 elm_object_text_set(ck, "Reorder mode enable");
833 evas_object_smart_callback_add(ck, "changed", reorder_mode_cb, grid);
834 elm_box_pack_end(hbx, ck);
835 evas_object_show(ck);
836
837 ck = elm_check_add(win);
832 elm_object_text_set(ck, "Horizontal Mode"); 838 elm_object_text_set(ck, "Horizontal Mode");
833 evas_object_smart_callback_add(ck, "changed", _horizontal_grid, grid); 839 evas_object_smart_callback_add(ck, "changed", _horizontal_grid, grid);
834 elm_box_pack_end(hbx, ck); 840 elm_box_pack_end(hbx, ck);
diff --git a/src/lib/elm_gengrid.c b/src/lib/elm_gengrid.c
index b97e6ee51..b44f316a2 100644
--- a/src/lib/elm_gengrid.c
+++ b/src/lib/elm_gengrid.c
@@ -2428,7 +2428,7 @@ _key_action_move(Evas_Object *obj, const char *params)
2428 if (_item_horizontal_loop(obj, ELM_FOCUS_LEFT)) 2428 if (_item_horizontal_loop(obj, ELM_FOCUS_LEFT))
2429 return EINA_TRUE; 2429 return EINA_TRUE;
2430 } 2430 }
2431 else 2431 else if (sd->item_loop_enable)
2432 { 2432 {
2433 if (_item_horizontal_loop(obj, ELM_FOCUS_UP)) 2433 if (_item_horizontal_loop(obj, ELM_FOCUS_UP))
2434 return EINA_TRUE; 2434 return EINA_TRUE;