checkIsUnsupportedFile static method
Implementation
static bool checkIsUnsupportedFile(String fileName, String action) {
bool isUnsupportedFile = false;
String message = '';
switch (action) {
case 'open':
isUnsupportedFile = isUnsupportedViewFile(fileName);
if (isUnsupportedFile) message = 'unsupported_file_for_download_view'.tr;
break;
case 'print':
isUnsupportedFile = isUnsupportedPrintFile(fileName);
if (isUnsupportedFile) message = 'unsupported_file_for_print'.tr;
break;
}
if (message.isNotEmpty) {
UFUToast.showToast(message);
}
return isUnsupportedFile;
}