Android soft keyboard reverts to default keyboard on orientation change -


i'm building android soft keyboard , can't seem fix bug - have arabic , qwerty keyboard , when rotate device on qwerty keyboard (or arabic shift), it's if program has "restarted" , becomes arabic keyboard without shift.

the onsaveinstancestate(bundle savedinstancestate) not work because application not extend activity inputmethodservice.

i put following in android manifest

android:configchanges="keyboard|keyboardhidden|orientation" android:windowsoftinputmode="stateunchanged|adjustresize"> 

i tried using

    @override     public void onconfigurationchanged(configuration newconfig) {         super.onconfigurationchanged(newconfig);          log.i(mydebug, "config changed " + currentkeyboard.equals(qwerty));      } 

however, currentkeyboard.equals(qwerty)) results false , made sure true before orientation change.

any appreciated.

i think applications fault. if application restarting on orientation changes, input connection being torn down , rebuilt new edit text. means keyboard see new connection , start in default state. test this, write test app turns off restarts on configuration change , see if still happens keyboards in app.


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -