2afabd060e15342c0ba622cb08f5be61a328e566 |
|
17-May-2017 |
Seigo Nonaka <nona@google.com> |
Introduce fetch strategy and timeout attribute. This CL makes developer to be able to choose the fetching strategy. Since the font inflation happens on UI thread, it is not a good idea to block until the font fetch finishes. On the other hand, it may be also bad if the fetch happens asynchronously and refresh the display once it finishes. This blinks the contents. Blocking fetching and timeout works as follows: - First, check the local cache and use it if it is available. - Request the font to the font provider and wait until it finishes or timeout happens. - If timeout happens, use default typeface instead. Asynchronous fetching works as follows: - First, check the local cache and use it if it is available. - Request the font to the font provider and use default typeface during initial inflation. - When the fetch finishes, refresh the TextView. We can't add automated tests for resources xml for provider fonts since it requires the static certificates. Bug: 38340183 Test: ./gradlew support-compat:connectedAndroidTest on API 16, 17, 18, 19, 21, 23, 25, 26 Test: ./gradlew support-appcompat-v7:connectedAndroidTest on API 16, 17, 18, 19, 21, 23, 25, 26 Test: ./gradlew support-emoji:connectedDebugAndroidTest on API 16, 17, 18, 19, 21, 23, 25, 26 Change-Id: Iec9d953f1a762a020f3556055f0eda868e6f2641
/frameworks/support/compat/java/android/support/v4/content/res/FontResourcesParserCompat.java
|
5a9990a015200eea35fd20497c17a19e318c8ffa |
|
09-May-2017 |
Seigo Nonaka <nona@google.com> |
Refactoring DownloadableFont - FontResourcesParserCompat cleanup - Remove getFileName in FontResourceEntry which is used by nobody. - ProviderResourceEntry is actually the same with FontRequest. Keep FontRequest object intead. Bug: 37493347 Test: ./gradlew support-compat:connectedDebugAndroidTest on API 16, 17, 18, 19, 21, 22, 23, 25, O Change-Id: Id7ea5a55c8a2485f95f6c5e39e192da268589c77
/frameworks/support/compat/java/android/support/v4/content/res/FontResourcesParserCompat.java
|
13c4e42077841f98fef6ff1087fe3d1fb7a4b53a |
|
07-Apr-2017 |
Clara Bayarri <clarabayarri@google.com> |
Supportlib downloadable fonts in xml Test: ./gradlew support-compat:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.v4.content.res.FontResourcesParserCompatTest ./gradlew support-compat:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.v4.content.res.ResourcesCompatTest Bug: 35381428 Change-Id: I0771e7179540e00e83c40b725140cad76f816cdd
/frameworks/support/compat/java/android/support/v4/content/res/FontResourcesParserCompat.java
|
543fd2946ded1593b28553879e74ca4393eddd2e |
|
24-Mar-2017 |
Clara Bayarri <clarabayarri@google.com> |
Supportlib Fonts in XML This change adds support for the new font resources type in support library, making its use possible pre-O. Test: ./gradlew support-compat:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.v4.content.res.FontResourcesParserCompatTest ./gradlew support-compat:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.v4.content.res.ResourcesCompatTest ./gradlew support-appcompat-v7:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.v7.widget.AppCompatTextViewTest Bug: 35382184 Change-Id: Ide32ae4e914b3dc73756016d24059ead25ca7e68
/frameworks/support/compat/java/android/support/v4/content/res/FontResourcesParserCompat.java
|
d679cb8cd83198de9d1fd67b5058d834d2daaae4 |
|
19-Apr-2017 |
Clara Bayarri <clarabayarri@google.com> |
Revert "Supportlib Fonts in XML" This reverts commit 617be7af1f752cfaaf566e627ff6ea797623f2c3. Reason for revert: <INSERT REASONING HERE> Change-Id: Iacaef0423aa43cc5473042b6d61f2664afaf9cf6
/frameworks/support/compat/java/android/support/v4/content/res/FontResourcesParserCompat.java
|
617be7af1f752cfaaf566e627ff6ea797623f2c3 |
|
24-Mar-2017 |
Clara Bayarri <clarabayarri@google.com> |
Supportlib Fonts in XML This change adds support for the new font resources type in support library, making its use possible pre-O. Test: ./gradlew support-compat:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.v4.content.res.FontResourcesParserCompatTest ./gradlew support-compat:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.v4.content.res.ResourcesCompatTest ./gradlew support-appcompat-v7:connectedCheck --info --daemon -Pandroid.testInstrumentationRunnerArguments.class=android.support.v7.widget.AppCompatTextViewTest Bug: 35382184 Change-Id: If67cf830c8c2d8875da73318d02db391421dfdfa
/frameworks/support/compat/java/android/support/v4/content/res/FontResourcesParserCompat.java
|