때 내 동적 데이터를 같이 걸어 갔다. 어떤 식 으로든이 중지 할 수 있습니다. 나는보기 소유자를 또한 시도했다 그러나 운 없음. 나는 어떤 잘못하고있다. 도움이 사전에스크롤 배경 및 이미지 후 목록보기에서 shyflling
공공보기의 getView (INT 위치보기 convertView, 뷰 그룹 ARG2) {
TextView title, title_sub1, title_sub2, sub1, sub2;
ImageView img, lock;
boolean isenable = false;
try
{
if (convertView == null)
{
convertView = RelativeLayout.inflate(context, R.layout.protection_home, null);
}
int label;
int icon;
if (mFeatures != null)
{
label = mFeatures.get(position).label;
icon = mFeatures.get(position).icon;
isenable = mFeatures.get(position).isenable;
} else
{
label = item[position];
icon = itemimg[position];
}
title = (TextView) convertView.findViewById(R.id.pro_title);
title_sub1 = (TextView) convertView.findViewById(R.id.sub_title1);
title_sub2 = (TextView) convertView.findViewById(R.id.sub_title2);
img = (ImageView) convertView.findViewById(R.id.icon);
sub1 = (TextView) convertView.findViewById(R.id.title1_status);
sub2 = (TextView) convertView.findViewById(R.id.title2_status);
lock = (ImageView) convertView.findViewById(R.id.lock);
title.setText(label);
img.setImageResource(icon);
title_sub1.setText(Setsubtitle1(label));
title_sub2.setText(Setsubtitle2(label));
sub1.setText("OFF");
sub2.setText("ON");
if (isenable == false)
{
convertView.setBackgroundResource(R.color.layout_default_bg_color_gray);
} else
{
convertView.setBackgroundResource(R.color.layout_default_bg_color_white);
}
convertView.setId(label);
} catch (Exception e)
{
// TODO Auto-generated catch block
e.printStackTrace();
}
return convertView;
}
가능한 복제본 http://stackoverflow.com/questions/5635865/images-were-shuffled-when-scrolling-a-listview-with-a-viewholder – JLONG
이 목적으로 발리 라이브러리를 사용해보십시오. Google 또는 Androidhive에서 확인하십시오. 건배! – Rohit