Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Programmatic 'Touch' vs Physical Touch

 
Frank Tee
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have tried quite a few suggestions and am still coming up short.

I have a Listview with 100+ Items.
When I select a single Item I want the Background Color to change so as to visually indicate Selection.
I have set up the Item Selector for the items to show State-specific Colors
These settings are

When I do a physical Touch - things work as intended.
When I do a programmatic 'Touch' - the Listview scrolls to the intended item (as intended), but the Background Color does not change

When the programmatic 'Touch' is done (via Voice Recognition) the following is currently being done:
1. The ListView data source is searched for a matching item and if found, the ListView's Item ID is determined.
2. With a matchingLotID the following commands are executed:

3. Now that launches the associated setOnItemClickListener() method which in turn launches the setOnItemClick() method
4. That again issues the setSelected() setPressed() commands.

When in development Debug more I can watch the setOnItemClick() method execute for a physical Touch - again = everything works fine. The Background Color changes as intended
Then when I watch the same code executed for the programmatic 'Touch' the Background Colors does NOT change.

I am baffled (mostly because I am an Android 'greenhorn')
What am I missing?

Thanks
DhugalMac





 
Frank Tee
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oops - Typo Alert !!!

Where I show ListView.. (two periods)
It is really ListView. (single period)

Thanks
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic