0
我正在定製(充氣)列表視圖。其中我使用了文本和背景圖像(根據條件)。 現在我面臨着滾動列表視圖的問題,即文本視圖的背景與其他文本視圖重疊。 下面是示例代碼:在充氣列表視圖中的問題
@Override
public View getView(int position, View convertView, ViewGroup parent) {
View icontextlayout=convertView;
icontextlayout= inflater.inflate(R.layout.layout_complex_list, null);
TextView Txt1=(TextView)icontextlayout.findViewById(R.id.txt1);
if(disp1==true)
{
Txt1.setBackgroundResource(R.drawable.pic)
}
else
Txt1.setText("Text1 "+strUser);//
TextView Txt2=(TextView)icontextlayout.findViewById(R.id.txt2);
if(disp2==true)
{
Txt2.setBackgroundResource(R.drawable.pic);
}
else Txt2.setText("Text2: "+strIndus);
return icontextlayout;
}
能否請你幫我出這個背景圖像Pic不重疊的其他背景。
感謝你......
它工作。你真的贏得我的關注。謝謝Cristian。 – Pankaj 2011-02-07 14:00:00