mirror of
https://github.com/samsonjs/media.git
synced 2026-04-01 10:35:48 +00:00
Update SubtitleWebView to use center alignment by default
This mimics the behaviour of SubtitleTextView for cues that don't have alignment set. PiperOrigin-RevId: 309389392
This commit is contained in:
parent
0774ee1da9
commit
222231dd8e
1 changed files with 3 additions and 4 deletions
|
|
@ -318,17 +318,16 @@ import java.util.List;
|
|||
|
||||
private static String convertAlignmentToCss(@Nullable Layout.Alignment alignment) {
|
||||
if (alignment == null) {
|
||||
return "unset";
|
||||
return "center";
|
||||
}
|
||||
switch (alignment) {
|
||||
case ALIGN_NORMAL:
|
||||
return "start";
|
||||
case ALIGN_CENTER:
|
||||
return "center";
|
||||
case ALIGN_OPPOSITE:
|
||||
return "end";
|
||||
case ALIGN_CENTER:
|
||||
default:
|
||||
return "unset";
|
||||
return "center";
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue