diff options
| -rw-r--r-- | core/java/android/content/LocusId.java | 2 | ||||
| -rw-r--r-- | packages/SettingsLib/res/values-fr/strings.xml | 6 | ||||
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java | 35 |
3 files changed, 25 insertions, 18 deletions
diff --git a/core/java/android/content/LocusId.java b/core/java/android/content/LocusId.java index 283cea00b192..98e71f07407e 100644 --- a/core/java/android/content/LocusId.java +++ b/core/java/android/content/LocusId.java @@ -33,7 +33,7 @@ import java.io.PrintWriter; * by the Android System to correlate state between different subsystems such as content capture, * shortcuts, and notifications. * - * <p>For example, if your app provides an activiy representing a chat between 2 users + * <p>For example, if your app provides an activity representing a chat between 2 users * (say {@code A} and {@code B}, this chat state could be represented by: * * <pre><code> diff --git a/packages/SettingsLib/res/values-fr/strings.xml b/packages/SettingsLib/res/values-fr/strings.xml index ddf2bc0991a4..5f5be97c322c 100644 --- a/packages/SettingsLib/res/values-fr/strings.xml +++ b/packages/SettingsLib/res/values-fr/strings.xml @@ -165,7 +165,7 @@ <string name="tts_lang_not_selected" msgid="7927823081096056147">"Langue non sélectionnée"</string> <string name="tts_default_lang_summary" msgid="9042620014800063470">"Définir la langue utilisée par la synthèse vocale"</string> <string name="tts_play_example_title" msgid="1599468547216481684">"Écouter un échantillon"</string> - <string name="tts_play_example_summary" msgid="634044730710636383">"Lire une courte démonstration de la synthèse vocale"</string> + <string name="tts_play_example_summary" msgid="634044730710636383">"Écoutez une courte démonstration de la synthèse vocale"</string> <string name="tts_install_data_title" msgid="1829942496472751703">"Installer les données vocales"</string> <string name="tts_install_data_summary" msgid="3608874324992243851">"Installer les données nécessaires à la synthèse vocale"</string> <string name="tts_engine_security_warning" msgid="3372432853837988146">"Ce moteur de synthèse vocale est susceptible de collecter tout ce qui sera lu, y compris les données personnelles comme les mots de passe et les numéros de carte de paiement. Il provient du moteur <xliff:g id="TTS_PLUGIN_ENGINE_NAME">%s</xliff:g>. Voulez-vous activer son utilisation ?"</string> @@ -189,8 +189,8 @@ <item msgid="1158955023692670059">"Rapide"</item> <item msgid="5664310435707146591">"Plus rapide"</item> <item msgid="5491266922147715962">"Très rapide"</item> - <item msgid="7659240015901486196">"Rapide"</item> - <item msgid="7147051179282410945">"Très rapide"</item> + <item msgid="7659240015901486196">"Beaucoup plus rapide"</item> + <item msgid="7147051179282410945">"Extrêmement rapide"</item> <item msgid="581904787661470707">"La plus rapide"</item> </string-array> <string name="choose_profile" msgid="343803890897657450">"Sélectionner un profil"</string> diff --git a/packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java b/packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java index f8655cc44d2a..52a2cecec6b1 100644 --- a/packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java +++ b/packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java @@ -3,7 +3,9 @@ package com.android.systemui.qs; import android.content.Context; import android.content.res.ColorStateList; import android.content.res.TypedArray; +import android.graphics.drawable.Animatable2; import android.graphics.drawable.AnimatedVectorDrawable; +import android.graphics.drawable.Drawable; import android.util.AttributeSet; import android.util.Log; import android.view.View; @@ -44,6 +46,24 @@ public class PageIndicator extends ViewGroup { private int mPosition = -1; private boolean mAnimating; + private final Animatable2.AnimationCallback mAnimationCallback = + new Animatable2.AnimationCallback() { + + @Override + public void onAnimationEnd(Drawable drawable) { + super.onAnimationEnd(drawable); + if (DEBUG) Log.d(TAG, "onAnimationEnd - queued: " + mQueuedPositions.size()); + if (drawable instanceof AnimatedVectorDrawable) { + ((AnimatedVectorDrawable) drawable).unregisterAnimationCallback( + mAnimationCallback); + } + mAnimating = false; + if (mQueuedPositions.size() != 0) { + setPosition(mQueuedPositions.remove(0)); + } + } + }; + public PageIndicator(Context context, AttributeSet attrs) { super(context, attrs); @@ -197,10 +217,8 @@ public class PageIndicator extends ViewGroup { final AnimatedVectorDrawable avd = (AnimatedVectorDrawable) getContext().getDrawable(res); imageView.setImageDrawable(avd); avd.forceAnimationOnUI(); + avd.registerAnimationCallback(mAnimationCallback); avd.start(); - // TODO: Figure out how to user an AVD animation callback instead, which doesn't - // seem to be working right now... - postDelayed(mAnimationDone, ANIMATION_DURATION); } private int getTransition(boolean fromB, boolean isMajorAState, boolean isMajor) { @@ -264,15 +282,4 @@ public class PageIndicator extends ViewGroup { getChildAt(i).layout(left, 0, mPageIndicatorWidth + left, mPageIndicatorHeight); } } - - private final Runnable mAnimationDone = new Runnable() { - @Override - public void run() { - if (DEBUG) Log.d(TAG, "onAnimationEnd - queued: " + mQueuedPositions.size()); - mAnimating = false; - if (mQueuedPositions.size() != 0) { - setPosition(mQueuedPositions.remove(0)); - } - } - }; } |