onChangingSelected method
Implementation
Future<bool> onChangingSelected(
BuildContext context,
Asset asset,
bool isSelected,
) async {
final bool? selectPredicateResult = await selectPredicate?.call(
context,
asset,
isSelected,
);
if (selectPredicateResult == false) {
return false;
}
if (isSelected) {
unSelectAsset(asset);
} else {
selectAsset(asset);
}
return true;
}