diff options
author | Victor Chang <vichang@google.com> | 2023-12-07 15:54:26 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2023-12-07 15:54:26 +0000 |
commit | bc7df575015a90b5bb45a902201eaf52e71b7b25 (patch) | |
tree | b54a1d263cae369edc0f0dd9a93531d2124647bf | |
parent | eef74ce4edc2b92942412e8589ffee763d55b919 (diff) | |
parent | 28c113d299ac9f608c4a05f6db953f77d732795d (diff) | |
download | base-bc7df575015a90b5bb45a902201eaf52e71b7b25.tar.gz |
Merge "Remove Unicode whitespace before AM/PM in the status bar" into main
-rw-r--r-- | packages/SystemUI/src/com/android/systemui/statusbar/policy/Clock.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/Clock.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/Clock.java index 6875b523a962..ea140cb99d19 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/Clock.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/Clock.java @@ -24,6 +24,7 @@ import android.content.Intent; import android.content.IntentFilter; import android.content.res.TypedArray; import android.graphics.Rect; +import android.icu.lang.UCharacter; import android.icu.text.DateTimePatternGenerator; import android.os.Bundle; import android.os.Handler; @@ -452,7 +453,7 @@ public class Clock extends TextView implements if (a >= 0) { // Move a back so any whitespace before AM/PM is also in the alternate size. final int b = a; - while (a > 0 && Character.isWhitespace(format.charAt(a-1))) { + while (a > 0 && UCharacter.isUWhiteSpace(format.charAt(a - 1))) { a--; } format = format.substring(0, a) + MAGIC1 + format.substring(a, b) |