getfiletypeIcon static method
Implementation
static getfiletypeIcon(String? type, {String? path}) {
if (type == null && path != null) {
type = path.split(".").last;
}
switch (type) {
case "pdf":
return pdf;
case "png":
case "jpg":
case "jpeg":
return image;
case "epub":
return epub;
case "mp3":
return audio;
case "mp4":
case "flv":
return audio;
case "docx":
case "xls":
return doc;
case "link":
return link;
case "doc":
return doc;
default:
return doc;
}
}