|
|
@ -3,6 +3,7 @@ |
|
|
|
|
|
|
|
|
package org.yuzu.yuzu_emu.activities |
|
|
package org.yuzu.yuzu_emu.activities |
|
|
|
|
|
|
|
|
|
|
|
import android.annotation.SuppressLint |
|
|
import android.app.Activity |
|
|
import android.app.Activity |
|
|
import android.app.PendingIntent |
|
|
import android.app.PendingIntent |
|
|
import android.app.PictureInPictureParams |
|
|
import android.app.PictureInPictureParams |
|
|
@ -397,6 +398,7 @@ class EmulationActivity : AppCompatActivity(), SensorEventListener { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@SuppressLint("UnspecifiedRegisterReceiverFlag") |
|
|
override fun onPictureInPictureModeChanged( |
|
|
override fun onPictureInPictureModeChanged( |
|
|
isInPictureInPictureMode: Boolean, |
|
|
isInPictureInPictureMode: Boolean, |
|
|
newConfig: Configuration |
|
|
newConfig: Configuration |
|
|
@ -409,8 +411,12 @@ class EmulationActivity : AppCompatActivity(), SensorEventListener { |
|
|
addAction(actionMute) |
|
|
addAction(actionMute) |
|
|
addAction(actionUnmute) |
|
|
addAction(actionUnmute) |
|
|
}.also { |
|
|
}.also { |
|
|
|
|
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) { |
|
|
|
|
|
registerReceiver(pictureInPictureReceiver, it, RECEIVER_EXPORTED) |
|
|
|
|
|
} else { |
|
|
registerReceiver(pictureInPictureReceiver, it) |
|
|
registerReceiver(pictureInPictureReceiver, it) |
|
|
} |
|
|
} |
|
|
|
|
|
} |
|
|
} else { |
|
|
} else { |
|
|
try { |
|
|
try { |
|
|
unregisterReceiver(pictureInPictureReceiver) |
|
|
unregisterReceiver(pictureInPictureReceiver) |
|
|
|