mirror of
https://github.com/FossifyOrg/Gallery.git
synced 2024-11-22 12:38:00 +01:00
more renames
This commit is contained in:
parent
1e3b2ff8d6
commit
77077b7369
2 changed files with 14 additions and 14 deletions
|
@ -30,20 +30,20 @@ public class DirectoryAdapter extends BaseAdapter {
|
|||
|
||||
@Override
|
||||
public View getView(int position, View convertView, ViewGroup parent) {
|
||||
ViewHolder holder;
|
||||
ViewHolder viewHolder;
|
||||
if (convertView == null) {
|
||||
convertView = mInflater.inflate(R.layout.directory_item, parent, false);
|
||||
holder = new ViewHolder(convertView);
|
||||
convertView.setTag(holder);
|
||||
viewHolder = new ViewHolder(convertView);
|
||||
convertView.setTag(viewHolder);
|
||||
} else {
|
||||
holder = (ViewHolder) convertView.getTag();
|
||||
viewHolder = (ViewHolder) convertView.getTag();
|
||||
}
|
||||
|
||||
final Directory dir = mDirs.get(position);
|
||||
holder.dirName.setText(dir.getName());
|
||||
holder.photoCnt.setText(String.valueOf(dir.getMediaCnt()));
|
||||
viewHolder.dirName.setText(dir.getName());
|
||||
viewHolder.photoCnt.setText(String.valueOf(dir.getMediaCnt()));
|
||||
Glide.with(mContext).load(dir.getThumbnail()).placeholder(R.color.tmb_background).centerCrop().crossFade()
|
||||
.into(holder.dirThumbnail);
|
||||
.into(viewHolder.dirThumbnail);
|
||||
|
||||
return convertView;
|
||||
}
|
||||
|
|
|
@ -30,23 +30,23 @@ public class MediaAdapter extends BaseAdapter {
|
|||
@Override
|
||||
public View getView(int position, View convertView, ViewGroup parent) {
|
||||
final Medium medium = mMedia.get(position);
|
||||
ViewHolder holder;
|
||||
ViewHolder viewHolder;
|
||||
if (convertView == null) {
|
||||
convertView = mInflater.inflate(R.layout.video_item, parent, false);
|
||||
holder = new ViewHolder(convertView);
|
||||
convertView.setTag(holder);
|
||||
viewHolder = new ViewHolder(convertView);
|
||||
convertView.setTag(viewHolder);
|
||||
} else {
|
||||
holder = (ViewHolder) convertView.getTag();
|
||||
viewHolder = (ViewHolder) convertView.getTag();
|
||||
}
|
||||
|
||||
if (medium.getIsVideo()) {
|
||||
holder.playOutline.setVisibility(View.VISIBLE);
|
||||
viewHolder.playOutline.setVisibility(View.VISIBLE);
|
||||
} else {
|
||||
holder.playOutline.setVisibility(View.GONE);
|
||||
viewHolder.playOutline.setVisibility(View.GONE);
|
||||
}
|
||||
|
||||
final String path = medium.getPath();
|
||||
Glide.with(mContext).load(path).placeholder(R.color.tmb_background).centerCrop().crossFade().into(holder.photoThumbnail);
|
||||
Glide.with(mContext).load(path).placeholder(R.color.tmb_background).centerCrop().crossFade().into(viewHolder.photoThumbnail);
|
||||
|
||||
return convertView;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue