Android Question IME_Height changed not triggered

panagiotisden2

Active Member
Licensed User
Longtime User
im trying to resize a webview to show a text field inside it while the keyboard is open but this code does not work.
B4X:
Sub IME_HeightChanged(NewHeight As Int, OldHeight As Int)
    WebView1.Height=WebView1.Top-NewHeight

End Sub

also noticed that this code returns nothing to the logs
B4X:
Sub IME_HeightChanged(NewHeight As Int, OldHeight As Int)
    Log(NewHeight)
    Log(OldHeight)

End Sub

to avoid an obvious suggestion i have already added this to activity_create
B4X:
ime.Initialize(Me)
ime.AddHeightChangedEvent

edit:
and i have already added this in manifest editor
B4X:
SetActivityAttribute(Browser, android:windowSoftInputMode, adjustResize|stateHidden)
 

panagiotisden2

Active Member
Licensed User
Longtime User
done.
still i get nothing

edit:
i also forgot to add
B4X:
SetActivityAttribute(Main, android:windowSoftInputMode, adjustResize|stateHidden)
in the manifest editor in the test zip but is does not work either

im testing on a real device
galaxy s5 cm13
 
Last edited:
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…