Have a look at the addAndMeasureChild()
function in HorizontalListView
. You can specify a maximum width/height when measuring like
child.measure(
MeasureSpec.makeMeasureSpec(yourWidth, MeasureSpec.AT_MOST),
MeasureSpec.makeMeasureSpec(yourHeight, MeasureSpec.AT_MOST));
However, this workaround only applies, if your items will always have the same (maximum) width/height, but for me it did the trick.
As for the selection feedback simply register an OnItemClickListener
to your HorizontalListView
and specify the desired behavior in the OnItemClick
method.