File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed
app/src/main/java/com/lagradost/cloudstream3 Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -313,6 +313,8 @@ object CommonActivity {
313313 }
314314
315315 fun onUserLeaveHint (act : Activity ? ) {
316+ // On Android 12 and later we use setAutoEnterEnabled() instead.
317+ if (Build .VERSION .SDK_INT >= Build .VERSION_CODES .S ) return
316318 if (canEnterPipMode && canShowPipMode) {
317319 act?.enterPIPMode()
318320 }
Original file line number Diff line number Diff line change @@ -55,6 +55,7 @@ import com.lagradost.cloudstream3.utils.EpisodeSkip
5555import com.lagradost.cloudstream3.utils.UIHelper
5656import com.lagradost.cloudstream3.utils.UIHelper.hideSystemUI
5757import com.lagradost.cloudstream3.utils.UIHelper.popCurrentPage
58+ import com.lagradost.cloudstream3.utils.UIHelper.shouldShowPIPMode
5859import java.net.SocketTimeoutException
5960
6061enum class PlayerResize (@StringRes val nameRes : Int ) {
@@ -196,7 +197,7 @@ abstract class AbstractPlayerFragment(
196197 activity?.let { act ->
197198 PlayerPipHelper .updatePIPModeActions(
198199 act,
199- isPlayingRightNow ,
200+ act.shouldShowPIPMode(canEnterPipMode) ,
200201 player.getAspectRatio()
201202 )
202203 }
You can’t perform that action at this time.
0 commit comments