buildConnerNetworkImage function
Widget
buildConnerNetworkImage({
- LoadStateChanged? loadStateChanged,
- bool enableLoadState = false,
- bool cache = true,
- bool enableMemoryCache = true,
- bool clearMemoryCacheIfFailed = true,
- required String url,
- double width = double.infinity,
- double height = double.infinity,
- bool isCircle = false,
- double radius = 5,
- BoxFit fit = BoxFit.fill,
圆角图片
Implementation
Widget buildConnerNetworkImage({LoadStateChanged? loadStateChanged,
bool enableLoadState = false,
bool cache = true,
bool enableMemoryCache = true,
bool clearMemoryCacheIfFailed = true,
required String url,
double width = double.infinity,
double height = double.infinity,
bool isCircle = false,
double radius = 5,
BoxFit fit = BoxFit.fill
}){
return ExtendedImage(
image: ExtendedNetworkImageProvider(
url,
cache: cache,
),
width: getWidth(width),
height: getHeight(height),
shape: isCircle? BoxShape.circle : BoxShape.rectangle,
borderRadius: BorderRadius.all(Radius.circular(radius)),
enableMemoryCache: enableMemoryCache,
clearMemoryCacheIfFailed: clearMemoryCacheIfFailed,
enableLoadState: enableLoadState,
loadStateChanged: loadStateChanged,
fit: fit,
);
}