AssetPickerViewerBuilderDelegate<Asset, Path> class abstract

Constructors

AssetPickerViewerBuilderDelegate({required List<Asset> previewAssets, required ThemeData themeData, required int currentIndex, AssetPickerProvider<Asset, Path>? selectorProvider, AssetPickerViewerProvider<Asset>? provider, List<Asset>? selectedAssets, int? maxAssets, bool shouldReversePreview = false, AssetSelectPredicate<Asset>? selectPredicate})

Properties

bottomBarHeight double
Height for bottom bar widget. 底栏部件的高度
no setter
bottomDetailHeight double
no setter
bottomPreviewHeight double
Height for bottom preview widget. 底栏预览部件的高度
no setter
currentAsset → Asset
Getter for the current asset. 当前资源的Getter
no setter
currentIndex int
Current previewing index in assets. 当前查看的索引
getter/setter pair
doubleTapAnimation Animation<double>?
Animation for double tap. 双击缩放的动画
getter/setter pair
doubleTapAnimationController AnimationController
AnimationController for double tap animation. 双击缩放的动画控制器
getter/setter pair
doubleTapCurveAnimation Animation<double>
CurvedAnimation for double tap. 双击缩放的动画曲线
getter/setter pair
doubleTapListener VoidCallback
Callback for double tap. 双击缩放的回调
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
isDisplayingDetail ValueNotifier<bool>
Whether detail widgets displayed. 详情部件是否显示
final
isSelectedPreviewing bool
Whether the viewer is under preview mode for selected assets. 当前是否处于查看已选中资源的模式
latefinal
maxAssets int?
Maximum count for asset selection. 资源选择的最大数量
final
pageController → ExtendedPageController
PageController for assets preview PageView. 查看图片资源的页面控制器
no setter
pageStreamController StreamController<int>
StreamController for viewing page index update. 用于更新当前正在浏览的资源页码的流控制器
final
previewAssets List<Asset>
Assets provided to preview. 提供预览的资源
final
previewingListController ScrollController
The ScrollController for the previewing assets list. 正在预览的资源的 ScrollController
final
provider AssetPickerViewerProvider<Asset>?
ChangeNotifier for photo selector viewer. 资源预览器的状态保持
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
selectedAssets List<Asset>?
Selected assets. 已选的资源
final
selectedCount int
The length getter for selected assets currently. 当前选中的资源的长度获取
no setter
selectedMaximumAssets bool
是否已经选择了最大数量的资源
no setter
selectedNotifier ValueNotifier<int>
Construct a notifier to notify whether if a new asset is selected or unselected. 构造一个通知器,在新资源选中或取消选中时通知。
latefinal
selectorProvider AssetPickerProvider<Asset, Path>?
Provider for AssetPicker. 资源选择器的状态保持
final
selectPredicate AssetSelectPredicate<Asset>?
Predicate whether an asset can be selected or unselected. 判断资源可否被选择。
final
semanticsTextDelegate AssetPickerTextDelegate
no setter
shouldReversePreview bool
Whether the preview sequence is reversed. 预览时顺序是否为反向
final
textDelegate AssetPickerTextDelegate
no setter
themeData ThemeData
Theme for the viewer. 主题
final
viewerState AssetPickerViewerState<Asset, Path>
The State for a viewer. 预览器的状态实例
getter/setter pair

Methods

assetPageBuilder(BuildContext context, int index) Widget
Split page builder according to type of asset. 根据资源类型使用不同的构建页
bottomDetailBuilder(BuildContext context) Widget
Detail widget aligned to bottom. 底部信息部件
bottomDetailItemBuilder(BuildContext context, int index) Widget
Thumb item widgets in bottom detail. 底部信息栏单个资源缩略部件
build(BuildContext context) Widget
Yes, the build method. 没错,是它是它就是它,我们亲爱的 build 方法~
confirmButton(BuildContext context) Widget
Confirm button. 确认按钮
didUpdateViewer(covariant AssetPickerViewerState<Asset, Path> state, covariant AssetPickerViewer<Asset, Path> oldWidget, covariant AssetPickerViewer<Asset, Path> newWidget) → void
Call when the viewer is calling State.didUpdateWidget. 当预览器调用 State.didUpdateWidget 时操作 State
dispose() → void
Keep a dispose method to sync with State. 保留一个 dispose 方法与 State 同步。
failedItemBuilder(BuildContext context) Widget
The item widget when AssetEntity.thumbnailData load failed. 资源缩略数据加载失败时使用的部件
initAnimations(covariant AssetPickerViewerState<Asset, Path> state) → void
Initialize animations related to the zooming preview. 为缩放预览初始化动画
initStateAndTicker(covariant AssetPickerViewerState<Asset, Path> state, TickerProvider v) → void
Call when viewer is calling State.initState. 当预览器调用 State.initState 时注册 State
isAppleOS(BuildContext context) bool
Whether the current platform is Apple OS. 当前平台是否为苹果系列系统
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onChangingSelected(BuildContext context, Asset asset, bool isSelected) Future<bool>
ordinalSortKey(double value) OrdinalSortKey
Produce OrdinalSortKey with the fixed name.
previewWidgetLoadStateChanged(BuildContext context, ExtendedImageState state, {bool hasLoaded = false}) Widget
Common image load state changed callback with Widget. 图片加载状态的部件回调
selectAsset(Asset entity) → void
selectButton(BuildContext context) Widget
Select button. 选择按钮
switchDisplayingDetail({bool? value}) → void
Method to switch isDisplayingDetail. 切换显示详情状态的方法
syncSelectedAssetsWhenPop() Future<bool>
Sync selected assets currently with asset picker provider. 在预览中当前已选的图片同步到选择器的状态
toString() String
A string representation of this object.
inherited
unSelectAsset(Asset entity) → void
updateAnimation(ExtendedImageGestureState state) → void
Execute scale animation when double tap. 双击时执行缩放动画

Operators

operator ==(Object other) bool
The equality operator.
inherited