List : Focus_next should be executed only when access mode is enabled.
authorWooHyun Jung <wh0705.jung@samsung.com>
Wed, 13 Mar 2013 05:47:31 +0000 (14:47 +0900)
committerWooHyun Jung <wh0705.jung@samsung.com>
Wed, 13 Mar 2013 05:47:31 +0000 (14:47 +0900)
ChangeLog
NEWS
src/lib/elm_list.c

index f5384e2ed36fbdccacb42c70be8d69176a924c8a..38bbf8b57020dd7174f9f056566e8a49df73419d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
 2013-03-11  Tom Hacohen (TAsn)
 
        * Entry: Fixed a bug with text appending.
+
+2013-03-13  WooHyun Jung
+
+        * List : Focus_next should be executed only when access mode is enabled.
diff --git a/NEWS b/NEWS
index 1b0a681b482d593f06999f73099528ae132ffe95..c8649096b3a3e4b7e5a0c00070391e4ac27ddbf2 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -23,6 +23,7 @@ Fixes:
    * Fix scroller acceleration bug. It was accelerated even it's scrolled after finishing the previous scroll. This happens with page scroll enabled.
    * Fix initial value of the spinner on the first mouse move.
    * Entry: Fixed a bug with text appending.
+   * List : Focus_next should be executed only when access mode is enabled.
         
 Elementary 1.7.5
 
index 9f85e096ee0c67e4cbd8e02f868d085dab6c8096..82dfb98a28ead7512c673f49ec0b48f35ae28135 100644 (file)
@@ -1480,6 +1480,19 @@ _elm_list_smart_focus_next(const Evas_Object *obj,
             (obj, items, eina_list_data_get, dir, next);
 }
 
+static void
+_access_hook(Evas_Object *obj, Eina_Bool is_access)
+{
+   ELM_LIST_CHECK(obj);
+   ELM_LIST_DATA_GET(obj, sd);
+
+   if (is_access)
+     ELM_WIDGET_CLASS(ELM_WIDGET_DATA(sd)->api)->focus_next =
+        _elm_list_smart_focus_next;
+   else
+     ELM_WIDGET_CLASS(ELM_WIDGET_DATA(sd)->api)->focus_next = NULL;
+}
+
 static void
 _elm_list_smart_add(Evas_Object *obj)
 {
@@ -1642,12 +1655,16 @@ _elm_list_smart_set_user(Elm_List_Smart_Class *sc)
 
    ELM_WIDGET_CLASS(sc)->sub_object_del = _elm_list_smart_sub_object_del;
    ELM_WIDGET_CLASS(sc)->on_focus = _elm_list_smart_on_focus;
-   ELM_WIDGET_CLASS(sc)->focus_next = _elm_list_smart_focus_next;
+   ELM_WIDGET_CLASS(sc)->focus_next = NULL;
    ELM_WIDGET_CLASS(sc)->focus_direction = NULL;
    ELM_WIDGET_CLASS(sc)->theme = _elm_list_smart_theme;
    ELM_WIDGET_CLASS(sc)->disable = _elm_list_smart_disable;
    ELM_WIDGET_CLASS(sc)->event = _elm_list_smart_event;
    ELM_WIDGET_CLASS(sc)->translate = _elm_list_smart_translate;
+   ELM_WIDGET_CLASS(sc)->access = _access_hook;
+
+   if (_elm_config->access_mode == ELM_ACCESS_MODE_ON)
+     ELM_WIDGET_CLASS(sc)->focus_next = _elm_list_smart_focus_next;
 
    ELM_LAYOUT_CLASS(sc)->sizing_eval = _elm_list_smart_sizing_eval;
 }