Aha! Adding a call to that method fixes both the context menu problem
and the click handler problem. Thanks.

Jesse

On Mar 11, 7:03 pm, Romain Guy <[email protected]> wrote:
> BTW did you call setItemsCanFocus(true) on your ListView?
>
>
>
> On Wed, Mar 11, 2009 at 7:01 PM, Jesse McGrew <[email protected]> wrote:
>
> > On Mar 11, 6:28 pm, Jesse McGrew <[email protected]> wrote:
> >> On Mar 11, 6:04 pm, Romain Guy <[email protected]> wrote:
>
> >> > > I'm trying to get the same behavior as Alarm Clock, where tapping on a
> >> > > list row brings up an activity to edit the row, and the check box can
> >> > > only be selected by tapping on the check box itself. I think that
> >> > > precludes using multiple-choice mode for the list view, correct?
>
> >> > Indeed it does. ListView is not ready to do things like this really
> >> > but a way to do it (much better than how it was done in AlarmClock) is
> >> > to use a TouchDelegate for the checkbox.
>
> >> Interesting. Unfortunately I can't find any examples of TouchDelegate,
> >> and the class documentation is confusing.
>
> >> I gather that I need to pass the bounds of the check box (relative to
> >> its container) into the TouchDelegate constructor. Once I have a
> >> TouchDelegate instance, what do I do with it? I see a method called
> >> setTouchDelegate() - do I call that on the check box, the list row, or
> >> the view group that directly contains the check box? And is that
> >> method enough to get the touch events relayed to the delegate, or do I
> >> need to listen for touch events and forward them myself?
>
> > Also: would it still be possible to focus the check box using the
> > trackball? I assumed TouchDelegates were only for touch, and so the
> > trackball would only be able to move between list rows. In AlarmClock,
> > the trackball can move horizontally between the clock view and check
> > box inside a row, as well as moving vertically between rows.
>
> > Jesse
>
> --
> Romain Guy
> Android framework engineer
> [email protected]
>
> 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
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to