OSDN Git Service

Announce chronometers with time-unit words.
authorDan Sandler <dsandler@android.com>
Fri, 5 Jun 2015 20:52:22 +0000 (16:52 -0400)
committerDan Sandler <dsandler@android.com>
Fri, 5 Jun 2015 21:19:12 +0000 (17:19 -0400)
commita79a747ca006d78b969f85227670f36572fde042
tree26a8ee4a4d5500655448ee0dc4cbb004f65234f2
parentb0a5e78fc06aeb67ac1f55832c9ceef5f92a0807
Announce chronometers with time-unit words.

Instead of just using the visible representation for
accessibility, for which "00:15" is announced as "zero
fifteen", we now say "fifteen seconds".

Similarly,

  00:00 - "0 seconds"
  01:00 - "1 minute"
  02:05 - "2 minutes 5 seconds"
  1:00:00 - "1 hour"
  2:00:02 - "2 hours 2 seconds"
  2:01:02 - "2 hours 1 minute 2 seconds"
  -5 - "5 seconds" (what are we, Mission Control?)

Adapted from similar code in
  packages/apps/InCallUI/src/com/android/incallui/InCallDateUtils.java

Bug: 19418509
Change-Id: I54188ef25a7a205bb5bab42663a3da357ac853ef
core/java/android/widget/Chronometer.java