WebView と EditText を同じレイアウトに配置する場合、
layout に XML で、requestFocus を片方だけに記述したり、全く記述しなかったりすると、
表示する Webコンテンツの中に書かれた <input>タグ、入力フィールドをタップしても、
IMEが起動されなかったりする。
WebView の setOnTouchLisner でセットしたリスナも変なことしていないのにである。
したがって、以下のように書いて凌いだ。
<LinearLayout
android:id="@+id/urlLinearLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical" >
<EditText
android:id="@+id/urlEditText"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/urlframe"
android:layout_marginLeft="4dp"
android:layout_marginRight="4dp"
android:layout_marginTop="2dp"
android:layout_marginBottom="2dp"
android:paddingTop="8dp"
android:paddingBottom="8dp"
android:inputType="textUri"
android:imeOptions="actionGo" >
<requestFocus />
</EditText>
</LinearLayout>
<WebView
android:id="@+id/webview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1" >
<requestFocus />
</WebView>