I have an expandable list with a context menu that can be accessed by
long clicking any of the children.
The view template used to create the children consists of 2 nested
linear layouts with a textView inside the second one. There's more to
the GUI than that, but this is sufficient to cause the bug to appear.

As long as the groups and children only contain a text field
everything works fine. However if I add a button before my textView,
long clicks are not received anymore. I can fix this by flagging the
inner Linear Layout as LongClickable. The top most one does not need
this to work.

Doing this allows me to receive longClick events again, however the
visual feedback of long clicks (the slow orange to white gradient) is
gone. Nothing happens visually when I hold down, however I do
eventually receive the event. The weird thing is that the visual
feedback still happens fine in focus mode. It's only invisible in
touch mode.

Does anyone have any idea what I can do to fix this?


Here's the xml
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/
android" android:layout_height="wrap_content"
android:layout_width="fill_parent"
android:orientation="vertical"
android:longClickable="true"
android:focusableInTouchMode="true"
android:focusable="true">
<LinearLayout android:layout_height="wrap_content"
android:id="@+id/EntryLineLinearLayout"
android:orientation="horizontal"
android:weightSum="1"
android:layout_width="fill_parent"
android:longClickable="true"
android:focusableInTouchMode="true"
android:focusable="true">
<Button android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:visibility="invisible"
android:text="@string/Hint"
android:id="@+id/Button">
</Button>
<TextView android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/EntryTextView"
android:layout_weight="0"
android:textSize="17sp">
</TextView>
</LinearLayout>
</LinearLayout>

--~--~---------~--~----~------------~-------~--~----~
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