ListView 的 ViewHolder的, 代码里不应该是判mConvertView为空否去new holder吗,通过tag获取也应该是mConvertView吧?
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 42/100
Research direction
The issue centers on ViewHolder.get(Context, View convertView, ...), with the relevant recycling and tag lookup shown in the report. Start by tracing how ListView supplies recycled views and how the holder is stored and retrieved; done means the intended lookup path is confirmed and the reported behavior is covered by a test or clearly documented.
Written by the indexing model from the issue text.
Description
public static ViewHolder get(Context context, View convertView,
ViewGroup parent, int layoutId, int position)
{
if (convertView == null)
{
View itemView = LayoutInflater.from(context).inflate(layoutId, parent,
false);
ViewHolder holder = new ViewHolder(context, itemView, parent, position);
holder.mLayoutId = layoutId;
return holder;
} else
{
ViewHolder holder = (ViewHolder) convertView.getTag();
holder.mPosition = position;
return holder;
}
}
- Dominant language
- Java
- Stars
- 4.7k
- Forks
- 1.2k
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from hongyangAndroid/baseAdapter
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
hongyangAndroid/baseAdapter#122 ·
-
含泪放弃维护了 Open
Difficulty 5/5 Over a week Newbie friendliness 1/100
hongyangAndroid/baseAdapter#136 ·
-
Difficulty 5/5 Over a week Newbie friendliness 10/100
hongyangAndroid/baseAdapter#134 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
hongyangAndroid/baseAdapter#133 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 20/100
hongyangAndroid/baseAdapter#131 · 2 comments · 1 reaction ·
All issues in hongyangAndroid/baseAdapter
Similar issues
-
area-deployment area-integrations triage:bot-seen
Difficulty 2/5 Half a day Newbie friendliness 86/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
apache/flink-agents#1156 ·
-
[source-shopify] FAILED bulk operation without partialDataUrl is silently treated as successful Openarea/connectors autoteam community connectors/source/shopify needs-triage team/use type/bug
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100