Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(mobile): recover keyboard composers after Android resume #8212

Closedmrmg(GitHub profile, opens in a new tab)wants to merge 6 commits intomain fromrefs/pull/8212/headopened View on GitHub

Showing 13 changed files with 23 additions and 2 deletions (loading 10).

x
0 of 13 viewed, 13 left
1 addition and 1 deletionapps/mobile/modules/t3-terminal/android/src/main/java/expo/modules/t3terminal/T3TerminalModule.ktModified
View file
@@ -54,7 +54,7 @@
view.mutedForegroundColorHex = mutedForegroundColor
​
- Events("onInput", "onResize")
+ Events("onInput", "onResize", "onTerminalFocus")
​
OnViewDestroys { view: T3TerminalView ->
view.cleanup()
21 additions and 0 deletionsapps/mobile/modules/t3-terminal/android/src/main/java/expo/modules/t3terminal/T3TerminalView.ktModified
View file
@@ -12,6 +12,8 @@
import android.view.inputmethod.InputMethodManager
import android.widget.EditText
import android.widget.FrameLayout
+import androidx.core.view.ViewCompat
+import androidx.core.view.WindowInsetsCompat
import expo.modules.kotlin.AppContext
import expo.modules.kotlin.viewevent.EventDispatcher
import expo.modules.kotlin.views.ExpoView
@@ -23,6 +25,7 @@
private val inputView = EditText(context)
private val onInput by EventDispatcher()
private val onResize by EventDispatcher()
+ private val onTerminalFocus by EventDispatcher()
private var terminalHandle = 0L
private var fedBuffer = ""