A view can only receive click events inside its boundaries. So make them
larger, by using appropriate layout options.
If you want the button to look small and respond to clicks over a larger
area, then add some kind of layout around it with width=fill_parent, and
set the click handler on that (make sure you use a state-list drawable
for the background, so there is visual feedback for clicking).
For TextViews, this is not necessary - you can stretch them full width
without affecting how they draw text.
-- Kostya
20.01.2011 18:02, BuckeyeDroid пишет:
Hi,
I have a RelativeLayout with two TextViews and a Button. Each of these
is a row. I want to be able to click anywhere on the row and get the
same effect as if I just clicked the button. Right now, only clicking
the button works. Clicking anywhere else on the row does not work.
Does anyone know how to fix this?
Thanks,
Bill
--
Kostya Vasilyev -- WiFi Manager + pretty widget -- http://kmansoft.wordpress.com
--
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