use of com.github.pockethub.android.ui.item.gist.GistFileItem in project PocketHub by pockethub.
the class GistFragment method updateFiles.
private void updateFiles(Gist gist) {
final Activity activity = getActivity();
if (activity == null) {
return;
}
Map<String, GistFile> files = gist.files();
if (files == null || files.isEmpty()) {
filesSection.update(Collections.emptyList());
return;
}
List<GistFileItem> fileItems = new ArrayList<>();
for (GistFile file : files.values()) {
fileItems.add(new GistFileItem(file));
}
filesSection.update(fileItems);
}
Aggregations