Android show softkeyboard with showSoftInput is not working?

后端 未结 12 1993
抹茶落季
抹茶落季 2020-12-28 13:49

I have created a trivial application to test the following functionality. When my activity launches, it needs to be launched with the softkeyboard open.

My code doe

12条回答
  •  孤城傲影
    2020-12-28 14:13

    My code had the toggle in it but not postDelayed. I had tried postDelayed for the showSoftInput without success and I have since tried your suggested solution. I was about to discard it as yet another failed potential solution until I decided to increase the delay time. It works for me all the way down to 200 ms at which point it doesn't work, at least not on the physical phones. So before you poor android developers ditch this answer, try upping the delay for a successful solution. It may pay to add a bit for older slower phones. Thanks heaps, was working on this one for hours.

提交回复
热议问题