android - 回收站中的 CardView 图像在平板电脑上滚动时放大太多
问题描述
当用户执行搜索时,我有一个包含卡片的片段。卡片包含 3 张图片和文字。手机没有问题。在用户滚动之前,前几张卡片在平板电脑上看起来不错。新加载的卡片具有放大很多的图像。由于在滚动之前没有问题,我知道这一定与我的绑定有关
public void bind(Model model) {
mModel = model;
Glide.with(mCtx).load(model.getImage1()).into(imageView1);
Glide.with(mCtx).load(model.getImage2()).into(imageView2);
Glide.with(mCtx).load(model.getImage3()).into(imageView3);
textViewFirstName.setText(model.getFirstName());
textViewLastName.setText(model.getLastName());
}
但是我很困惑,因为滚动后图像在手机上看起来很好。请帮忙
解决方案
解决了只需使用 Picasso 库而不是垃圾 Glide 库
推荐阅读
- git - 每当我尝试通过 git 推送到远程仓库时都会发生错误。我已经尝试过使用我的 github 和 gitlab 帐户
- reactive-programming - 如何将错误记录到数据库并在项目反应器中恢复执行?
- go - 有没有办法用 Kubernetes client-go 优雅地结束一个 pod?
- python - 为什么星号分配产生列表而不是元组?
- python - 创建一个模型,它可以在图像是否倾斜时对图像进行分类(根据页面或图像的方向)
- c# - Blazor,在组件循环中选择一个项目并取消选择其他项目
- pandas - Pandas 中奇怪的列排列
- excel - 如何在现有的 Excel 行中循环直到最后一行
- .net - 如何修复“将值转换为类型时出错”
- dataframe - 基于python中唯一列组合的聚合