Rework the Voice variant preference to show a dialog with Category and Variant lists.

The original variant list UI resulted in a long, complex list that
was difficult to navigate. This change splits up that list into
more manageable groups.
This commit is contained in:
Reece H. Dunn
2013-09-06 13:10:35 +01:00
parent 596aa025cd
commit c7a1556101
8 changed files with 423 additions and 96 deletions
@@ -60,6 +60,17 @@ public class VoiceVariant {
return ret;
}
public boolean equals(Object o) {
if (o instanceof VoiceVariant) {
VoiceVariant other = (VoiceVariant)o;
if (variant == null || other.variant == null) {
return other.variant == null && variant == null && other.gender == gender && other.age == age;
}
return other.variant.equals(variant) && other.gender == gender && other.age == age;
}
return false;
}
public static VoiceVariant parseVoiceVariant(String value) {
String[] parts = mVariantPattern.split(value);
int age = SpeechSynthesis.AGE_ANY;