[access] make access object unfocusable, when accessibility is disabled
authorShinwoo Kim <cinoo.kim@samsung.com>
Mon, 22 Apr 2013 05:18:42 +0000 (14:18 +0900)
committerShinwoo Kim <cinoo.kim@samsung.com>
Mon, 22 Apr 2013 05:18:42 +0000 (14:18 +0900)
legacy/elementary/ChangeLog
legacy/elementary/NEWS
legacy/elementary/src/lib/elm_access.c

index 8b36108..8c00e7f 100644 (file)
 2013-04-18  Shinwoo Kim
 
         * Add elm_access_action(), elm_access_action_cb_set()
+
+2013-04-22  Shinwoo Kim
+
+        * Make access object unfocusable when Aaccessibility is disabled.
index c8c9f56..54a9f05 100644 (file)
@@ -211,6 +211,7 @@ Fixes:
    * Fix the calculation double type number.
    * Fix the policy is not changed when the theme is changed.
    * When entry is disabled, scrolling is also disabled.
+   * Make access object unfocusable when Aaccessibility is disabled.
 
 Removals:
 
index d0b1800..1db4393 100644 (file)
@@ -32,7 +32,7 @@ _elm_access_smart_add(Eo *obj, void *_pd EINA_UNUSED, va_list *list EINA_UNUSED)
 {
    eo_do_super(obj, MY_CLASS, evas_obj_smart_add());
 
-   elm_widget_can_focus_set(obj, EINA_TRUE);
+   elm_widget_can_focus_set(obj, _elm_config->access_mode);
 }
 
 static Eina_Bool
@@ -1294,6 +1294,14 @@ elm_access_external_info_get(const Evas_Object *obj)
 }
 
 static void
+_elm_access_smart_access(Eo *obj, void *_pd EINA_UNUSED, va_list *list)
+{
+   Eina_Bool is_access = va_arg(*list, int);
+
+   elm_widget_can_focus_set(obj, is_access);
+}
+
+static void
 _class_constructor(Eo_Class *klass)
 {
    const Eo_Op_Func_Description func_desc[] = {
@@ -1303,6 +1311,7 @@ _class_constructor(Eo_Class *klass)
 
         EO_OP_FUNC(ELM_WIDGET_ID(ELM_WIDGET_SUB_ID_ON_FOCUS), _elm_access_smart_on_focus),
         EO_OP_FUNC(ELM_WIDGET_ID(ELM_WIDGET_SUB_ID_ACTIVATE), _elm_access_smart_activate),
+        EO_OP_FUNC(ELM_WIDGET_ID(ELM_WIDGET_SUB_ID_ACCESS), _elm_access_smart_access),
 
         EO_OP_FUNC_SENTINEL
    };