atspi: use last appended relation information 97/138197/2 accepted/tizen/3.0/common/20170717.111106 accepted/tizen/3.0/ivi/20170717.085754 accepted/tizen/3.0/mobile/20170717.085625 accepted/tizen/3.0/tv/20170717.085724 accepted/tizen/3.0/wearable/20170717.085734 submit/tizen_3.0/20170714.105032
authorShinwoo Kim <cinoo.kim@samsung.com>
Tue, 11 Jul 2017 11:30:16 +0000 (20:30 +0900)
committerGerrit Code Review <gerrit@review.ap-northeast-2.compute.internal>
Fri, 14 Jul 2017 01:31:19 +0000 (01:31 +0000)
So far, the screen reader has used the first relation information.
So application should remove appended relation information, before appending
relation information newly. This is hard to use in some point of view.
The application used *append API as *set API.
So using last appended relation information makes more sense.

Change-Id: Id7c3e7dc02acc0a883eb7e55b3892461aee259a3

src/lib/elm_atspi_bridge.c

index 060fb6f9a4e1cba027ebb424160286c7e7c4c672..75a7e5b833f91df9cb0b7d4649539dc6c78f4f53 100644 (file)
@@ -4782,7 +4782,11 @@ static void *_get_object_in_relation_by_type_impl(struct accessibility_navigatio
        Eina_List *l;
        EINA_LIST_FOREACH(relations, l, rel)
          {
-           if (rel->type == expected_relation_type) return rel->objects ? rel->objects->data : NULL;
+           if (rel->type == expected_relation_type)
+             {
+                Eina_List *last = eina_list_last(rel->objects);
+                return eina_list_data_get(last);
+             }
          }
      }
    return NULL;