Tested with Android 1.6(4) and 2.3.3(10).
I've made a minimalistic test application to demonstrate this, all it does is load the xml with:
setContentView(R.layout.main);
and the xml is:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/hello" />
<EditText
android:id="@+id/editText1"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:inputType="none"
android:ems="10" >
</EditText>
The problem:
when setting inputType="none"
the actual input type during execution becomes textMultiLine(0x00020001)
, I've checked it with a debugger.
On the other hand if I use inputType="text"
it works as expected.
Is this a bug in Android?
setInputType(InputType.TYPE_NULL)
– Breastwork