Use our context's layout inflater
This commit is contained in:
parent
cdcd9844a5
commit
9bae5fb333
|
@ -325,7 +325,7 @@ public class AppListAdapter extends RecyclerView.Adapter<AppListAdapter.ViewHold
|
|||
if (mLabelDisabled == null) {
|
||||
mLabelDisabled = viewGroup.getContext().getString(R.string.list_item_disabled);
|
||||
}
|
||||
LayoutInflater inflater = viewGroup.getContext().getSystemService(LayoutInflater.class);
|
||||
LayoutInflater inflater = LayoutInflater.from(viewGroup.getContext());
|
||||
View view = inflater.inflate(R.layout.app_list_item, viewGroup, false);
|
||||
ViewHolder vh = new ViewHolder(view);
|
||||
vh.setIndex(i);
|
||||
|
|
Loading…
Reference in a new issue