mirror of
https://github.com/androidx/media.git
synced 2025-04-30 06:46:50 +08:00
Fix bug where PlayerView distorts video when video size is unknown
PiperOrigin-RevId: 541640959 (cherry picked from commit 8d8c514d1220904a8d2df3f9bc3176877df9f553)
This commit is contained in:
parent
3631e1c6f3
commit
e53796fc25
@ -1603,7 +1603,8 @@ public class PlayerView extends FrameLayout implements AdViewProvider {
|
||||
@Override
|
||||
public void onVideoSizeChanged(VideoSize videoSize) {
|
||||
if (videoSize.equals(VideoSize.UNKNOWN)
|
||||
&& (player == null || player.getPlaybackState() == Player.STATE_IDLE)) {
|
||||
|| player == null
|
||||
|| player.getPlaybackState() == Player.STATE_IDLE) {
|
||||
return;
|
||||
}
|
||||
updateAspectRatio();
|
||||
|
Loading…
x
Reference in New Issue
Block a user