I'm trying to send a custom accessibility event using a code similar to this one
AccessibilityManager manager = (AccessibilityManager) context
.getSystemService(Context.ACCESSIBILITY_SERVICE);
if (manager.isEnabled()) {
AccessibilityEvent e = AccessibilityEvent.obtain();
e.setEventType(AccessibilityEvent.TYPE_ANNOUNCEMENT);
e.setClassName(getClass().getName());
e.setPackageName(context.getPackageName());
e.getText().add("some text");
manager.sendAccessibilityEvent(e);
}
It's a message for an async event and I don't want the message to interrupt another one, but to play after the current message end being read by Talkback.
Any ideas?