package defpackage;

import android.widget.FrameLayout;
import android.widget.ImageButton;
import androidx.lifecycle.s;
import androidx.media3.exoplayer.ExoPlayer;
import com.strmr.ps.R;
import com.strmr.ps.ui.player.VideoPlayerActivity;
import com.strmr.ps.ui.player.a;

/* JADX INFO: loaded from: classes3.dex */
public final /* synthetic */ class aha implements qq3 {
    public final /* synthetic */ int a;
    public final /* synthetic */ VideoPlayerActivity b;

    public /* synthetic */ aha(VideoPlayerActivity videoPlayerActivity, int i) {
        this.a = i;
        this.b = videoPlayerActivity;
    }

    @Override // defpackage.qq3
    public final Object invoke() {
        boolean z;
        int i = this.a;
        int i2 = R.drawable.ic_play;
        e6a e6aVar = e6a.a;
        VideoPlayerActivity videoPlayerActivity = this.b;
        switch (i) {
            case 0:
                FrameLayout frameLayout = videoPlayerActivity.Y;
                if (frameLayout == null) {
                    cr4.n("adjustmentBarContainer");
                    throw null;
                }
                frameLayout.setVisibility(8);
                videoPlayerActivity.Z = null;
                wj0.c(s.a(videoPlayerActivity), null, null, new sha(videoPlayerActivity, null), 3);
                return e6aVar;
            case 1:
                long[] jArr = VideoPlayerActivity.R0;
                videoPlayerActivity.bt();
                a aVar = videoPlayerActivity.Z;
                if (aVar != null) {
                    ExoPlayer exoPlayer = videoPlayerActivity.bm;
                    z = exoPlayer != null && exoPlayer.isPlaying();
                    aVar.n = z;
                    ImageButton imageButton = aVar.h;
                    if (imageButton != null) {
                        if (z) {
                            i2 = R.drawable.ic_pause;
                        }
                        imageButton.setImageResource(i2);
                    }
                }
                return e6aVar;
            case 2:
                FrameLayout frameLayout2 = videoPlayerActivity.Y;
                if (frameLayout2 == null) {
                    cr4.n("adjustmentBarContainer");
                    throw null;
                }
                frameLayout2.setVisibility(8);
                videoPlayerActivity.Z = null;
                return e6aVar;
            case 3:
                long[] jArr2 = VideoPlayerActivity.R0;
                videoPlayerActivity.bt();
                a aVar2 = videoPlayerActivity.Z;
                if (aVar2 != null) {
                    ExoPlayer exoPlayer2 = videoPlayerActivity.bm;
                    z = exoPlayer2 != null && exoPlayer2.isPlaying();
                    aVar2.n = z;
                    ImageButton imageButton2 = aVar2.h;
                    if (imageButton2 != null) {
                        if (z) {
                            i2 = R.drawable.ic_pause;
                        }
                        imageButton2.setImageResource(i2);
                    }
                }
                return e6aVar;
            default:
                long[] jArr3 = VideoPlayerActivity.R0;
                videoPlayerActivity.bt();
                a aVar3 = videoPlayerActivity.Z;
                if (aVar3 != null) {
                    ExoPlayer exoPlayer3 = videoPlayerActivity.bm;
                    z = exoPlayer3 != null && exoPlayer3.isPlaying();
                    aVar3.n = z;
                    ImageButton imageButton3 = aVar3.h;
                    if (imageButton3 != null) {
                        if (z) {
                            i2 = R.drawable.ic_pause;
                        }
                        imageButton3.setImageResource(i2);
                    }
                }
                return e6aVar;
        }
    }
}
