Merge pull request #8340 from nextcloud/fixInflaterCall

Attach view to parent when calling Inflater
This commit is contained in:
Tobias Kaminsky 2021-05-05 10:30:20 +02:00 committed by GitHub
commit 87b8c1342f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -149,11 +149,11 @@ public class ActivityListAdapter extends RecyclerView.Adapter<RecyclerView.ViewH
public RecyclerView.ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
if (viewType == ACTIVITY_TYPE) {
return new ActivityViewHolder(
ActivityListItemBinding.inflate(LayoutInflater.from(parent.getContext()))
ActivityListItemBinding.inflate(LayoutInflater.from(parent.getContext()), parent, false)
);
} else {
return new ActivityViewHeaderHolder(
ActivityListItemHeaderBinding.inflate(LayoutInflater.from(parent.getContext()))
ActivityListItemHeaderBinding.inflate(LayoutInflater.from(parent.getContext()), parent, false)
);
}
}