Re: [android-developers] Re: Button in a ListView cell

2011-05-08 Thread Muhammad Danish Khan
Did u added ur click listener under the adapter or just calling it as we
adds the listener on list item?

--
Sent from Android

On May 7, 2011 12:02 AM, "B Lyon"  wrote:
> I take it you looked through this
>
> http://developer.android.com/resources/articles/touch-mode.html
>
> (which was new to me)
>
> On Fri, May 6, 2011 at 1:59 PM, Eric  wrote:
>>
>>
>> On May 6, 1:38 pm, B Lyon  wrote:
>>> Did you play with descendantFocusibility at all?
>>
>> Not yet.  I would like to avoid an time-consuming and arbitrary number
>> of tag permutation changes if I can find the proper solution up-
>> front.  descendantFocusibility does seem to look promising, but I'm
>> not convince it will work in all of the 6 cases I specified above.
>>
>> The problem with using the 'normal' ListView OnItemClickedListener()
>> is that if you have a clickable-button in the list view item, the
>> ListView item no longer respond to click events at all.
>> descendantFocusibility may indeed be the answer, but it would be nice
>> to hear from someone who has all this working.  It should be
>> completely possible, I am not asking for much here -- just
>> functionality that you would expect from the list view in the first
>> place.
>>
>> --
>> 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+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/android-developers?hl=en
>
> --
> 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+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Button in a ListView cell

2011-05-06 Thread B Lyon
I take it you looked through this

http://developer.android.com/resources/articles/touch-mode.html

(which was new to me)

On Fri, May 6, 2011 at 1:59 PM, Eric  wrote:
>
>
> On May 6, 1:38 pm, B Lyon  wrote:
>> Did you play with descendantFocusibility at all?
>
> Not yet.  I would like to avoid an time-consuming and arbitrary number
> of tag permutation changes if I can find the proper solution up-
> front.  descendantFocusibility does seem to look promising, but I'm
> not convince it will work in all of the 6 cases I specified above.
>
> The problem with using the 'normal' ListView OnItemClickedListener()
> is that if you have a clickable-button in the list view item, the
> ListView item no longer respond to click events at all.
> descendantFocusibility may indeed be the answer, but it would be nice
> to hear from someone who has all this working.  It should be
> completely possible, I am not asking for much here -- just
> functionality that you would expect from the list view in the first
> place.
>
> --
> 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+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Button in a ListView cell

2011-05-06 Thread Eric


On May 6, 1:38 pm, B Lyon  wrote:
> Did you play with descendantFocusibility at all?

Not yet.  I would like to avoid an time-consuming and arbitrary number
of tag permutation changes if I can find the proper solution up-
front.  descendantFocusibility does seem to look promising, but I'm
not convince it will work in all of the 6 cases I specified above.

The problem with using the 'normal' ListView OnItemClickedListener()
is that if you have a clickable-button in the list view item, the
ListView item no longer respond to click events at all.
descendantFocusibility may indeed be the answer, but it would be nice
to hear from someone who has all this working.  It should be
completely possible, I am not asking for much here -- just
functionality that you would expect from the list view in the first
place.

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Button in a ListView cell

2011-05-06 Thread B Lyon
Did you play with descendantFocusibility at all?

On Fri, May 6, 2011 at 1:24 PM, B Lyon  wrote:
> hey
>
> well, I'm really curious what is going on.  I've got some extra
> buttons/imagebuttons and a text view inserted into the row and they
> don't interfere with each other, but that is not the case you are
> looking at (and you obviously already know how to do that).  Looks
> like there is a trackball mode on the emulator I can play with if
> you've got a snippet to play with.   I might be able to try to
> implement what you're doing in something I have.
>
>
>
> On Fri, May 6, 2011 at 1:14 PM, Eric  wrote:
>> I am going to surmise it is safe to assume there is no way to achieve
>> this in Android, due to lack of responses and being unable to find
>> anyone else who has been able to do it?
>>
>> --
>> 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+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/android-developers?hl=en
>

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Button in a ListView cell

2011-05-06 Thread Eric
I am going to surmise it is safe to assume there is no way to achieve
this in Android, due to lack of responses and being unable to find
anyone else who has been able to do it?

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Button in a ListView cell

2011-05-05 Thread Giorgio Torres
so, worked?

On Thu, May 5, 2011 at 8:57 PM, B Lyon  wrote:

> I've recently added extra buttons to each row of a listactivity that
> can then do whatever, but your case sounds a little more involved.
>
> On Thu, May 5, 2011 at 7:20 PM, Eric  wrote:
> >
> >
> > On May 5, 7:11 pm, B Lyon  wrote:
> >> So you were able to get everything to work without the trackball case?
> >
> > It depends on what you mean by 'work'.  I was able to hack things to
> > work.  The ListView steals focus from the inner-widgets if you set an
> > OnItemClickListener.  So I had to set an OnClickListener() on the
> > ListView item View, and a separate OnClickListener() for the child
> > button.  That works in so much as touch-clicks work, but the trackball/
> > D-pad is broken for clicks.  Furthermore, I still haven't been able to
> > figure out how to get the trackball to be able to focus into the
> > Button instead of the entire list view cell.
> >
> > So, no, I would not say I have things working to anywhere near my
> > satisfaction.  I am hoping there is one solution that will allow
> > everything to work as I would expect it to above, which is in my
> > opinion that way the UI should function.
> >
> > --
> > 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+unsubscr...@googlegroups.com
> > For more options, visit this group at
> > http://groups.google.com/group/android-developers?hl=en
>
> --
> 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+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Giorgio Prímola F. G. Torres
Graduando em Ciência da Computação
Universidade Federal de Viçosa



  



-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Button in a ListView cell

2011-05-05 Thread B Lyon
I've recently added extra buttons to each row of a listactivity that
can then do whatever, but your case sounds a little more involved.

On Thu, May 5, 2011 at 7:20 PM, Eric  wrote:
>
>
> On May 5, 7:11 pm, B Lyon  wrote:
>> So you were able to get everything to work without the trackball case?
>
> It depends on what you mean by 'work'.  I was able to hack things to
> work.  The ListView steals focus from the inner-widgets if you set an
> OnItemClickListener.  So I had to set an OnClickListener() on the
> ListView item View, and a separate OnClickListener() for the child
> button.  That works in so much as touch-clicks work, but the trackball/
> D-pad is broken for clicks.  Furthermore, I still haven't been able to
> figure out how to get the trackball to be able to focus into the
> Button instead of the entire list view cell.
>
> So, no, I would not say I have things working to anywhere near my
> satisfaction.  I am hoping there is one solution that will allow
> everything to work as I would expect it to above, which is in my
> opinion that way the UI should function.
>
> --
> 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+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Button in a ListView cell

2011-05-05 Thread Giorgio Torres
Eric, I don't know much about Android yet, I just started studying it.
Do you know much of programing concepts? Mainly inheritance?

It happens that,l i think button its not a View, so, you wont be able to add
it to a ListView.

Try build a row composed by a Linear or a Relative layout. Add it your
schemma of the line, with textviews and button. Then use this new row
into your ListView. I think it may work.

I cheer here for you! Feedback me if it works.

On Thu, May 5, 2011 at 8:20 PM, Eric  wrote:

>
>
> On May 5, 7:11 pm, B Lyon  wrote:
> > So you were able to get everything to work without the trackball case?
>
> It depends on what you mean by 'work'.  I was able to hack things to
> work.  The ListView steals focus from the inner-widgets if you set an
> OnItemClickListener.  So I had to set an OnClickListener() on the
> ListView item View, and a separate OnClickListener() for the child
> button.  That works in so much as touch-clicks work, but the trackball/
> D-pad is broken for clicks.  Furthermore, I still haven't been able to
> figure out how to get the trackball to be able to focus into the
> Button instead of the entire list view cell.
>
> So, no, I would not say I have things working to anywhere near my
> satisfaction.  I am hoping there is one solution that will allow
> everything to work as I would expect it to above, which is in my
> opinion that way the UI should function.
>
> --
> 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+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Giorgio Prímola F. G. Torres
Graduando em Ciência da Computação
Universidade Federal de Viçosa



  



-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Button in a ListView cell

2011-05-05 Thread Eric


On May 5, 7:11 pm, B Lyon  wrote:
> So you were able to get everything to work without the trackball case?

It depends on what you mean by 'work'.  I was able to hack things to
work.  The ListView steals focus from the inner-widgets if you set an
OnItemClickListener.  So I had to set an OnClickListener() on the
ListView item View, and a separate OnClickListener() for the child
button.  That works in so much as touch-clicks work, but the trackball/
D-pad is broken for clicks.  Furthermore, I still haven't been able to
figure out how to get the trackball to be able to focus into the
Button instead of the entire list view cell.

So, no, I would not say I have things working to anywhere near my
satisfaction.  I am hoping there is one solution that will allow
everything to work as I would expect it to above, which is in my
opinion that way the UI should function.

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Button in a ListView cell

2011-05-05 Thread Eric
and also:

6. The trackball D-pad will ideally allow me to navigate not only to
every cell in the ListView, but also navigate over the clickable
Button and give it trackball focus such that I can run the Button
action from the Trackball.

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en