Merge "Always create nodes for views backed by an adapter." into mnc-dev
This commit is contained in:
@@ -1556,13 +1556,6 @@ public abstract class AbsListView extends AdapterView<ListAdapter> implements Te
|
|||||||
if (accessibilityId == getAccessibilityViewId()) {
|
if (accessibilityId == getAccessibilityViewId()) {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
// If the data changed the children are invalid since the data model changed.
|
|
||||||
// Hence, we pretend they do not exist. After a layout the children will sync
|
|
||||||
// with the model at which point we notify that the accessibility state changed,
|
|
||||||
// so a service will be able to re-fetch the views.
|
|
||||||
if (mDataChanged) {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
return super.findViewByAccessibilityIdTraversal(accessibilityId);
|
return super.findViewByAccessibilityIdTraversal(accessibilityId);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2408,18 +2401,6 @@ public abstract class AbsListView extends AdapterView<ListAdapter> implements Te
|
|||||||
}
|
}
|
||||||
|
|
||||||
class ListItemAccessibilityDelegate extends AccessibilityDelegate {
|
class ListItemAccessibilityDelegate extends AccessibilityDelegate {
|
||||||
@Override
|
|
||||||
public AccessibilityNodeInfo createAccessibilityNodeInfo(View host) {
|
|
||||||
// If the data changed the children are invalid since the data model changed.
|
|
||||||
// Hence, we pretend they do not exist. After a layout the children will sync
|
|
||||||
// with the model at which point we notify that the accessibility state changed,
|
|
||||||
// so a service will be able to re-fetch the views.
|
|
||||||
if (mDataChanged) {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
return super.createAccessibilityNodeInfo(host);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onInitializeAccessibilityNodeInfo(View host, AccessibilityNodeInfo info) {
|
public void onInitializeAccessibilityNodeInfo(View host, AccessibilityNodeInfo info) {
|
||||||
super.onInitializeAccessibilityNodeInfo(host, info);
|
super.onInitializeAccessibilityNodeInfo(host, info);
|
||||||
|
|||||||
Reference in New Issue
Block a user