Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Top-most and Bottom-most Horizontal Divider does not show up in ListView

I am using a ListView. But the top-most and bottom-most horizontal bar does not show up. Why? I am using this:

android:divider="@android:drawable/divider_horizontal_bright"
like image 241
Sagar Hatekar Avatar asked Mar 30 '10 02:03

Sagar Hatekar


1 Answers

Add a dummy footer and header

listViewContato = (ListView) view.findViewById(R.id.listview_contatos);
listViewContato.addHeaderView(new View(getActivity()));
listViewContato.addFooterView(new View(getActivity()));
like image 126
Victor Pinto Avatar answered Sep 28 '22 00:09

Victor Pinto