これは、イメージ アダプターの getView 関数です。GridView が空のようです。私は何を間違っていますか?
@Override
public View getView(int position, View convertView, ViewGroup parent) {
//ImageView view = (ImageView) convertView;
DraweeView view = (DraweeView) convertView;
if (view == null) {
//view = new ImageView(mContext);
view = new DraweeView(mContext);
view.setLayoutParams(new GridView.LayoutParams(200, 200));
view.setScaleType(ImageView.ScaleType.FIT_CENTER);
view.setPadding(1, 1, 1, 1);
view.setBackgroundResource(R.drawable.rounded);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
view.setClipToOutline(true);
}
}
else {
//view = (ImageView) convertView;
view = (DraweeView) convertView;
}
url = pp[position];
Uri uri = Uri.parse(url);
//Picasso.with(mContext).load(url).resize(200, 200).into(view);
view.setImageURI(uri);
return view;
}