我使用 Picasso 已经有一段时间了,但我不得不将 OkHttp 库升级到 2.0.0,因此,我不得不将 Picasso 升级到 2.3.2 版本。
然而,现在毕加索根本不加载任何图像,图像视图是空的。任何时候都没有出现错误,但是当我打开 Picasso 登录时,“Hunter”似乎已被调度并开始执行,但从未完成。
所有图像都可以访问且相当小(大约 200 像素 x 100 像素)。
我正在通过毕加索的“典型”方法加载图像:
Picasso.with(context).load(url).error(R.drawable.errorimg).into(imageView);
但是,errorimg
从未显示。
我可能做错了什么?
编辑:
这是毕加索不起作用的地方之一的代码(PlaceListAdapter.java - getView 函数)
public View getView(int position, View convertView, ViewGroup parent)
{
final PBNPlace ev = values.get(position);
LayoutInflater inflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
View rowView = inflater.inflate(R.layout.places_list_item, parent, false);
TextView titleView = (TextView)rowView.findViewById(R.id.place_title);
ImageView placeImage = (ImageView)rowView.findViewById(R.id.place_image);
Picasso picasso = Picasso.with(context);
picasso.load(ev.imageURL).error(R.drawable.chat).into(placeImage);
titleView.setText(ev.name);
return rowView;
}