mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-20 21:35:59 +00:00
Merge origin/main into feat/malibridge-v25
This commit is contained in:
commit
a2a5f84711
132 files changed
+7212
-156
No files matched your search
@@ -1588,6 +1588,22 @@ class FrontEndActivity : ComponentActivity() {
|
||||
startSession(Intent(this, SessionActivity::class.java).putExtra(SessionActivity.EXTRA_STEAMVR, steamVr), steamSession = true)
|
||||
}
|
||||
|
||||
@Suppress("OVERRIDE_DEPRECATION")
|
||||
override fun startActivityForResult(intent: Intent, requestCode: Int, options: Bundle?) {
|
||||
val outside = com.droiddeck.launcher.ui.DualScreenPanel.shownOn >= 0 &&
|
||||
com.droiddeck.launcher.ui.DualScreenPanel.opensOutside(packageName, intent.component?.packageName ?: intent.`package` ?: intent.resolveActivity(packageManager)?.packageName)
|
||||
if (outside) {
|
||||
com.droiddeck.launcher.ui.DualScreenPanel.yieldTo(taskId, true)
|
||||
window.decorView.postDelayed({ if (hasWindowFocus()) com.droiddeck.launcher.ui.DualScreenPanel.yieldTo(taskId, false) }, 1500)
|
||||
}
|
||||
try {
|
||||
super.startActivityForResult(intent, requestCode, options)
|
||||
} catch (e: RuntimeException) {
|
||||
if (outside) com.droiddeck.launcher.ui.DualScreenPanel.yieldTo(taskId, false)
|
||||
throw e
|
||||
}
|
||||
}
|
||||
|
||||
override fun onWindowFocusChanged(hasFocus: Boolean) {
|
||||
super.onWindowFocusChanged(hasFocus)
|
||||
if (hasFocus) {
|
||||
|
||||
Reference in new issue
Block a user