Adopt the accessibility state api in progress bar

When the progress changes, instead of sending TYPE_VIEW_SELECTED event,
CONTENT_CHANGE_TYPE_STATE_DESCRIPTION event sent. Developers can
override onInitializeAccessibilityNodeInfo() and call
info.setStateDescription() to provide customized state description.

Bug: 123346875
Test: The default implementation of StateDescriptionFormatter maintains
the current format talkback uses. Also tested on talkback_test to set
customized state description based on progress.
Note: this change should not be merged until CL/275509401 (google3) is merged.

Change-Id: I8f1a0c91c55a498593c360483827ed050656d943
1 file changed