I am trying to show ProgressBar
with a simple animation for each ListView
item, but
when I am scrolling, the ProgressBar
animation stops.
you must use animation in getView() and set animation for convertView example :
@Override
public View getView(final int position, View convertView, ViewGroup parent) {
ViewHolder holder;
StructureArticles item = getItem(position);
if (convertView == null) {
convertView = G.inflater.inflate(R.layout.adapter_articles, parent, false);
holder = new ViewHolder(convertView);
convertView.setTag(holder);
} else {
holder = (ViewHolder) convertView.getTag();
}
holder.fill(this, item, position);
Animation animationListView = AnimationUtils.loadAnimation(context, R.anim.scale_fade_in);
convertView.startAnimation(animationListView);
return convertView;
}