Turn on highlight only if the accessibility is enabled
authorSung-jae Park <nicesj.park@samsung.com>
Sat, 7 Dec 2013 15:14:55 +0000 (00:14 +0900)
committerSung-jae Park <nicesj.park@samsung.com>
Sat, 7 Dec 2013 15:14:55 +0000 (00:14 +0900)
Change-Id: If538bb36af4d22f21c30661a6cd0620495ace64d

src/script_port.c

index 8982206..4a25bd0 100644 (file)
@@ -98,6 +98,7 @@ struct obj_info {
 static struct {
        char *font_name;
        int font_size;
+       int access_on;
 
        Eina_List *handle_list;
 } s_info = {
@@ -105,6 +106,7 @@ static struct {
        .font_size = -100,
 
        .handle_list = NULL,
+       .access_on = 0,
 };
 
 static inline Evas_Object *find_edje(struct info *handle, const char *id)
@@ -271,7 +273,7 @@ PUBLIC int script_update_text(void *h, Evas *e, const char *id, const char *part
                                goto out;
                        }
 
-                       if (!handle->access_chain) {
+                       if (!handle->access_chain && s_info.access_on) {
                                _elm_access_object_hilight(edje);
                        }
 
@@ -586,7 +588,7 @@ PUBLIC int script_update_access(void *_h, Evas *e, const char *id, const char *p
                        } else {
                                elm_access_info_set(ao, ELM_ACCESS_INFO, text);
 
-                               if (!handle->access_chain) {
+                               if (!handle->access_chain && s_info.access_on) {
                                        _elm_access_object_hilight(edje);
                                }
 
@@ -1716,6 +1718,7 @@ static void access_cb(keynode_t *node, void *user_data)
 
        DbgPrint("ELM CONFIG ACCESS: %d\n", state);
        elm_config_access_set(state);
+       s_info.access_on = state;
 }
 
 static void update_font_cb(void *data)