Possible duplicate:
public boolean onKey () is called twice?
I have an EditText field that causes popUp to be viewed using radio buttons. The work of PopUp and RadioGroup is good. But I just understand when pressed or Touch in EditText, onTouchListener is called 2 times. I also understand that the reason for my previous question is the same problem. Here is the EditText;
etOdemeSekli = (EditText)findViewById(R.id.etOdemeSekli);
etOdemeSekli.setOnTouchListener(new OnTouchListener() {
public boolean onTouch(View v, MotionEvent event) {
inflatePopUpOdemeSekli();
Log.d("****","Inflate");
return false;
}
});
and here is the xml for EditText
<EditText
android:layout_weight="1"
android:id="@+id/etOdemeSekli"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:hint="@string/odemeSekliHint"
android:focusableInTouchMode="false">
</EditText>
Because of this double call, the popup is weird. Calling () is not working properly. What could be the reason? This is really very annoying, thanks.
source
share