Last ListView: Fab element hides it

My problem is that I have ListViewan action button attached to it. But FAB hides the button if the list is at the very end. Therefore, I want to apply some free space, but only to the last element of the list.

I use a simple extension adapter BaseAdapter. So in getView, I could apply something to convertView if position == getCount()-1.

But how can I make this extra free space?

When I set the padding with convertView.setPadding, until the 56dpsize increases, it just hides the items in my ListView. If I use LinearLayout.Layoutparamsand set the fields, nothing happens at all. So what can I do here?

+4
source share
2 answers

Install the bottom pad on ListView. You must install android:clipToPadding="false"at ListView.

+14
source

as well as the Egor approach, you can also use ListView.setFooterView(View v)for an inflated performance that is as high as your factory.

+1
source

All Articles