Fix subtitle outline width not applying in release builds (#1687)
## Description Fix applying the subtitle outline width in ExoPlayer for release builds The outline width field isn't public, so reflection is used to bypass and modify it. Since proguard/r8 renames all of the classes and fields, this meant the field was no longer found. The fix is to have proguard preserve the necessary field names. ### Related issues Fixes #1681 ### Testing Emulator w/ release build ## Screenshots N/a ## AI or LLM usage None
This commit is contained in:
parent
26124a5348
commit
f74306a12c
2 changed files with 14 additions and 0 deletions
11
app/proguard-rules.pro
vendored
11
app/proguard-rules.pro
vendored
|
|
@ -11,3 +11,14 @@
|
|||
|
||||
# TODO investigate using smaller scope
|
||||
-keep class com.google.common.cache.** { *; }
|
||||
|
||||
# Media3SubtitleOverride uses reflection to access/modify these fields
|
||||
-keep class androidx.media3.ui.SubtitleView {
|
||||
private androidx.media3.ui.SubtitleView$Output output;
|
||||
}
|
||||
-keep class androidx.media3.ui.CanvasSubtitleOutput {
|
||||
private final java.util.List painters;
|
||||
}
|
||||
-keep class androidx.media3.ui.SubtitlePainter {
|
||||
private final float outlineWidth;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue