[Smart Selection] Use system locale for Smart Selection
This is to match TextView's behavior, see b/122818072. TextView passed its locale to TextSelection/TextClassification, this locale is from an inner mTextPaint object, TextPaint is a subclass of android.graphics.Paint. The default locale in android.graphics.Paint is set to LocaleList.getAdjustedDefault(). [1] Note that there is still a gap between WebView and TextView since TextView has API to set locale, but WebView doesn't. [1] https://android.googlesource.com/platform/frameworks/base/+/refs/heads/master/graphics/java/android/graphics/Paint.java#491 Bug: b/122818072, 710505 Change-Id: Iaaf07656e7c852f30ac0b5ae76108583fc5105da Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1636311Reviewed-by:Changwan Ryu <changwan@chromium.org> Reviewed-by:
Pedro Amaral <amaralp@chromium.org> Commit-Queue: Shimi Zhang <ctzsm@chromium.org> Cr-Commit-Position: refs/heads/master@{#664866}
Showing
Please register or sign in to comment