When I click an input text field (input type="text")
in my WebView, the field shows soft keyboard but the cursor is not showing.
I can type in texts, but no cursor...
When that happens, Logcat says "W/IInputConnectionWrapper﹕ showStatusIcon on inactive InputConnection" or "W/IInputConnectionWrapper﹕ getTextBeforeCursor on inactive InputConnection".
I tried to override
my WebView making onCheckIsTextEditor() return true;
, but nothing works.
Please help.
I solved this problem by setting focusable to the WebView's enclosing view.
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:focusable="true"
android:focusableInTouchMode="true">
<WebView
android:id="@+id/web_view"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
<include
android:id="@+id/progress_bar"
layout="@layout/progress_bar"/>
</FrameLayout>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With