performCompletion on AutoCompleteTextView

by oliver » Sat, 31 Jan 2009 01:48:49 GMT


Sponsored Links
 hi,
i'm having a problem when using the performCompletion method on an
AutoCompleteTextView.
when i start typing the suggestions work fine (an entry is
highlighted). as soon as i type enough characters so that no match is
possible anymore, the suggestion list disappears (which is ok).
when i know delete some characters so the suggestion list appears
again nothing will be selected (even though it will still narrow down
it's hits the more characters i type again)
now the problem:  in an onKey listener i check if the suggestions are
showing (isPopupShowing) and if so i try to call performCompletion.
now the AutoCompleteListener finds out that nothing is selected and
replaces my content with "".

does anybody know of a way
- how to re-enable the selection on the suggestion list ?
- or how to find out if anything is selected at all? in that case i
would not call the performCompletion method

thnx!

--~--~---------~--~----~------------~-------~--~----~



performCompletion on AutoCompleteTextView

by oliver » Sat, 31 Jan 2009 01:52:26 GMT


 hi,
i'm having a problem when using the performCompletion method on an
AutoCompleteTextView.
when i start typing the suggestions work fine (an entry is
highlighted). as soon as i type enough characters so that no match is
possible anymore, the suggestion list disappears (which is ok).
when i know delete some characters so the suggestion list appears
again nothing will be selected (even though it will still narrow down
it's hits the more characters i type again)
now the problem:  in an onKey listener i check if the suggestions are
showing (isPopupShowing) and if so i try to call performCompletion.
now the AutoCompleteListener finds out that nothing is selected and
replaces my content with "".

does anybody know of a way
- how to re-enable the selection on the suggestion list ?
- or how to find out if anything is selected at all? in that case i
would not call the performCompletion method

thnx!

--~--~---------~--~----~------------~-------~--~----~


Sponsored Links


performCompletion on AutoCompleteTextView

by Romain Guy » Sat, 31 Jan 2009 01:55:08 GMT


 This will all be fixed in cupcake. But why do you need to call
performCompletion() yourself? There is no reason to do so.






-- 
Romain Guy
Android framework engineer
romain...@android.com

Note: please don't send private questions to me, as I don't have time
to provide private support.  All such questions should be posted on
public forums, where I and others can see and answer them

--~--~---------~--~----~------------~-------~--~----~



performCompletion on AutoCompleteTextView

by oliver » Sat, 31 Jan 2009 05:55:40 GMT


 thanks for your answer. good to hear it's gonna be fixed in cupcake.
the reason i call performCompletion() is i also want to react to
certain key events. a key event does not trigger the completion by
itself.

cheers,
oliver





--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. When save image, how to specify image name?

did u try TITLE





--~--~---------~--~----~------------~-------~--~----~

2. Save TextView/ScrollView Data

I am putting text into a TextView that is inside of a ScrollView (so
that they can scroll through the text) via the "append" command and
HTTP posts.  When I switch views from vertical to horizontal (or vice-
versa), all of the text in the TextView/ScrollView goes away, the data
is not saved.  Is there a way I can save this data, or do I have to re-
download it every time the user switches the screen back and forth?  I
haven't been able to figure this out yet.  Thanks for any help you can
give!
--~--~---------~--~----~------------~-------~--~----~

3. What about a virtual keyboard?

4. Custom created files and application reinstall - bug or my mistake?

5. ViewGroup and SurfaceView

6. How can I know the IP address, which android is using

7. How switch my android source tree to another branch?