如何将此 Picasso 代码转换为 Glide?
How do I convert translate this Picasso code into Glide?
所以,我正在根据本教程(https://www.youtube.com/watch?v=RCCCLcD4xbY)编写一个Android应用程序作为参考,现在,我已经到了ImageAdapter部分。由于我想使用 Glide 而不是 Picasso,所以我想更改这一行
Picasso.with(mContext).load("http://image.tmdb.org/t/p/w185/" + array.get(position)).
resize(width, (int)(width*1.5)).placeholder(d).into(imageView);
变成毕加索的等价物。
您还可以在此处查看完整的 ImageAdapter 代码以使事情更清楚:http://pastebin.com/K7ZCwqid
Glide.with(mContext)
.load("http://image.tmdb.org/t/p/w185/" + array.get(position))
.override(width, (int)(width*1.5))
.placeholder(d)
.into(imageView);
所以,我正在根据本教程(https://www.youtube.com/watch?v=RCCCLcD4xbY)编写一个Android应用程序作为参考,现在,我已经到了ImageAdapter部分。由于我想使用 Glide 而不是 Picasso,所以我想更改这一行
Picasso.with(mContext).load("http://image.tmdb.org/t/p/w185/" + array.get(position)).
resize(width, (int)(width*1.5)).placeholder(d).into(imageView);
变成毕加索的等价物。
您还可以在此处查看完整的 ImageAdapter 代码以使事情更清楚:http://pastebin.com/K7ZCwqid
Glide.with(mContext)
.load("http://image.tmdb.org/t/p/w185/" + array.get(position))
.override(width, (int)(width*1.5))
.placeholder(d)
.into(imageView);