Shardul
Shardul

Reputation: 786

Custom Preference Including EditText

I am creating an custom preference which contains an EditText.

The problem is when user clicks the EdiText for input suggestion box opens up and EditText looses focus. When EditText is clicked again for input, no problem occurs until 'blank space' is entered, which results in suggestion box and hence loss of focus.

What I mean by suggestion box is the box which pops up when entering text in EditText

Suggestion Box on EditText

Upvotes: 1

Views: 973

Answers (2)

Tyndare
Tyndare

Reputation: 21

Another solution that worked for me: In AndroidMenifest.xml add android:windowSoftInputMode="adjustPan" in the activity.

Found here: http://www.mail-archive.com/[email protected]/msg132688.html

Upvotes: 2

Vikas Patidar
Vikas Patidar

Reputation: 43349

You can disable Auto Suggestion by using android:inputType="textFilter" attribute in your XML file.

Upvotes: 2

Related Questions