AndroidIDEOfficial / AndroidIDE

AndroidIDE is an IDE for Android to develop full featured Android apps.
https://m.androidide.com
GNU General Public License v3.0
2.09k stars 250 forks source link

crashes when a physical keyboard is connected #1782

Closed hasanelfalakiy closed 2 months ago

hasanelfalakiy commented 3 months ago

Issue Checklist

Additional terms

Issue explanation

the application crashes when a physical keyboard is connected, when connected it displays blank then I try to press tab but gboard reappears and gradle reloads

Expected behavior

I want when a physical keyboard is connected, the application display does not change (blank) & the application does not need to reload (gradle)

Version name

Version : v2.7.1-beta (27102) CI Build : true Branch : main Commit : 55bb46b31 Variant : arm64-v8a (release) Build type : OFFICIAL F-Droid Build : false F-Droid Version : null F-Droid Version code : -1 SDK Version : 30 Supported ABIs : [arm64-v8a, armeabi-v7a, armeabi] Manufacturer : vivo Device : vivo1901

Download source

GitHub

Relevant log output

AndroidIDE Crash Report
Version : v2.7.1-beta (27102)
CI Build : true
Branch : main
Commit : 55bb46b31
Variant : arm64-v8a (release)
Build type : OFFICIAL
F-Droid Build : false
F-Droid Version : null
F-Droid Version code : -1
SDK Version : 30
Supported ABIs : [arm64-v8a, armeabi-v7a, armeabi]
Manufacturer : vivo
Device : vivo1901

Stacktrace:
java.lang.IllegalStateException: Activity has been destroyed
    at com.itsaky.androidide.activities.editor.BaseEditorActivity.getBinding(Unknown Source:13)
    at androidx.appcompat.widget.Toolbar$3.prepareBuild(Unknown Source:126)
    at com.itsaky.androidide.utils.ApkInstaller$installApk$1.invoke(SourceFile:44)
    at com.itsaky.androidide.utils.ApkInstaller$installApk$1.invoke(SourceFile:129)
    at com.itsaky.androidide.tasks.TaskExecutorKt$$ExternalSyntheticLambda1.run(Unknown Source:19)
    at android.os.Handler.handleCallback(Handler.java:938)
    at android.os.Handler.dispatchMessage(Handler.java:99)
    at android.os.Looper.loop(Looper.java:257)
    at android.app.ActivityThread.main(ActivityThread.java:8192)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:626)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1015)
BanDroid commented 3 months ago

could you check if you disable soft keyboard when hard keyboard connected in your device settings?

System -> Language and Input -> Physical Keyboard

Screenshot_20240401-050720.png

hasanelfalakiy commented 3 months ago

could you check if you disable soft keyboard when hard keyboard connected in your device settings?

System -> Language and Input -> Physical Keyboard

Screenshot_20240401-050720.png

I've checked, my device doesn't have a physical keyboard setting like that

itsaky commented 2 months ago

This was fixed in 0801e90.