Thursday, October 29, 2009

[android-developers] Re: How to disable touch event on listView

If you want to disable something, that intent was to be enabled,
rethink your idea.

Use access mutex, message to user, or threads.

On 29 Paź, 15:52, jax <jackma...@gmail.com> wrote:
> I have a ListView with a setOnItemClickListener.  I am trying to
> prevent the user from pressing an item repeatedly but can't seem to
> get it to work.  I have tried the following.
>
>                                 mAvailableOptionsListView.setClickable(false);
>                                 mAvailableOptionsListView.setEnabled(false);
>
> and then a little time later in a TimerTask enabling them again
>
>                                 mAvailableOptionsListView.setClickable(true);
>                                 mAvailableOptionsListView.setEnabled(true);
>
> This does not seem to work
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments:

Post a Comment