Introduce cache mechanism for LocaleList.

Setting the LocaleList to the native Paint object is not a lightweight
operation since it needs to propagate a string object to the native code
which then needs to parse it for making minikin language list.

To avoid performance regressions, cache the minikin language ID in
android.graphics.Paint and send the LocaleList with cached ID
instead of a string the next time native code is called.

BUG: 25122318
Change-Id: Ib5ce8bcff8a1c0a2b1a1c3d1868ea8be5a0e642f
5 files changed