I have a working navigation drawer that uses ArrayAdapter
as shown in the documentation. I want to set ImageView
icons for each of the navigation d
Updated
1) I don't see the source of data to be displayed in your code - you don't pass it in the constructor or any other way
2) In getView()
you should set values for your Views
3) To be efficient you have to re-use convertView
if it's not null
4) And at last - for your CustomAdapter
override also following methods:
@Override
public int getViewTypeCount() {
...
}
@Override
public int getItemViewType(int position) {
...
}
@Override
public int getCount() {
...
}
@Override
public YOUR_ITEM_TYPE getItem(int position) {
...
}
@Override
public long getItemId(int position) {
...
}
@Override
public boolean hasStableIds() {
...
}
@Override
public boolean isEmpty() {
...
}
@Override
public boolean areAllItemsEnabled() {
...
}
@Override
public boolean isEnabled(int position) {
...
}