P panagiotisden2 Active Member Licensed User Longtime User Dec 4, 2016 #1 im trying to resize a webview to show a text field inside it while the keyboard is open but this code does not work. Code: 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 Code: 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 Code: ime.Initialize(Me) ime.AddHeightChangedEvent edit: and i have already added this in manifest editor Code: SetActivityAttribute(Browser, android:windowSoftInputMode, adjustResize|stateHidden)
im trying to resize a webview to show a text field inside it while the keyboard is open but this code does not work. Code: 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 Code: 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 Code: ime.Initialize(Me) ime.AddHeightChangedEvent edit: and i have already added this in manifest editor Code: SetActivityAttribute(Browser, android:windowSoftInputMode, adjustResize|stateHidden)
Erel B4X founder Staff member Licensed User Longtime User Dec 4, 2016 #2 Is the Activity a full screen activity? If so then it will not work. If not then please try to reproduce it in a small project and upload the project. Upvote 0
Is the Activity a full screen activity? If so then it will not work. If not then please try to reproduce it in a small project and upload the project.
P panagiotisden2 Active Member Licensed User Longtime User Dec 4, 2016 #3 sorry erel forgot to mention. it is not a full screen activity here you go Attachments test.zip test.zip 7.4 KB · Views: 304 Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Dec 4, 2016 #4 You need to call: Code: ime.AddHeightChangedEvent Upvote 0
P panagiotisden2 Active Member Licensed User Longtime User Dec 4, 2016 #5 done. still i get nothing edit: i also forgot to add Code: 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: Dec 4, 2016 Upvote 0
done. still i get nothing edit: i also forgot to add Code: 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
Erel B4X founder Staff member Licensed User Longtime User Dec 4, 2016 #6 The event name is incorrect. Code: IME.Initialize("ime") Upvote 0
P panagiotisden2 Active Member Licensed User Longtime User Dec 4, 2016 #7 Thank you Erel this was the problem Upvote 0