DefaultAssetPickerViewerBuilderDelegate class

Inheritance

Constructors

DefaultAssetPickerViewerBuilderDelegate({required int currentIndex, required List<AssetEntity> previewAssets, AssetPickerProvider<AssetEntity, AssetPathEntity>? selectorProvider, required ThemeData themeData, AssetPickerViewerProvider<AssetEntity>? provider, List<AssetEntity>? selectedAssets, List<int>? previewThumbSize, SpecialPickerType? specialPickerType, int? maxAssets})

Properties

bottomBarHeight double
Height for bottom bar widget. 底栏部件的高度
no setterinherited
bottomDetailHeight double
no setterinherited
bottomPreviewHeight double
Height for bottom preview widget. 底栏预览部件的高度
no setterinherited
currentAsset AssetEntity
Getter for the current asset. 当前资源的Getter
no setterinherited
currentIndex int
Current previewing index in assets. 当前查看的索引
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
hasVideo bool
Whether there are videos in preview/selected assets. 当前正在预览或已选的资源是否有视频
no setter
isAppleOS bool
Whether the current platform is Apple OS. 当前平台是否为苹果系列系统
no setterinherited
isDisplayingDetail ValueNotifier<bool>
Whether detail widgets displayed. 详情部件是否显示
final
isSelectedPreviewing bool
Whether the viewer is under preview mode for selected assets. 当前是否处于查看已选中资源的模式
latefinalinherited
isWeChatMoment bool
Whether the SpecialPickerType.wechatMoment is enabled. 当前是否为微信朋友圈选择模式
no setter
maxAssets int?
Maximum count for asset selection. 资源选择的最大数量
finalinherited
pageController PageController
PageController for assets preview PageView. 查看图片资源的页面控制器
latefinal
pageStreamController StreamController<int>
StreamController for viewing page index update. 用于更新当前正在浏览的资源页码的流控制器
finalinherited
previewAssets List<AssetEntity>
Assets provided to preview. 提供预览的资源
finalinherited
previewThumbSize List<int>?
Thumb size for the preview of images in the viewer. 预览时图片的缩略图大小
final
provider AssetPickerViewerProvider<AssetEntity>?
ChangeNotifier for photo selector viewer. 资源预览器的状态保持
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
selectedAssets List<AssetEntity>?
Selected assets. 已选的资源
finalinherited
selectedCount int
The length getter for selected assets currently. 当前选中的资源的长度获取
no setterinherited
selectedNotifier ValueNotifier<int>
Construct a notifier to notify whether if a new asset is selected or unselected. 构造一个通知器,在新资源选中或取消选中时通知。
latefinalinherited
selectorProvider AssetPickerProvider<AssetEntity, AssetPathEntity>?
Provider for AssetPicker. 资源选择器的状态保持
finalinherited
specialPickerType SpecialPickerType?
The current special picker type for the viewer. 当前特殊选择类型
final
themeData ThemeData
Theme for the viewer. 主题
finalinherited
viewerState AssetPickerViewerState<AssetEntity, AssetPathEntity>
The State for a viewer. 预览器的状态实例
latefinalinherited
vsync TickerProvider
The TickerProvider for animations. 用于动画的 TickerProvider
latefinalinherited

Methods

appBar(BuildContext context) Widget
AppBar widget. 顶栏部件
assetPageBuilder(BuildContext context, int index) Widget
Split page builder according to type of asset. 根据资源类型使用不同的构建页
override
bottomDetailBuilder(BuildContext context) Widget
Detail widget aligned to bottom. 底部信息部件
override
bottomDetailItemBuilder(BuildContext context, int index) Widget
Thumb item widgets in bottom detail. 底部信息栏单个资源缩略部件
override
build(BuildContext context) Widget
Yes, the build method. 没错,是它是它就是它,我们亲爱的 build 方法~
override
confirmButton(BuildContext context) Widget
It'll pop with AssetPickerProvider.selectedAssets when there are any assets were chosen. Then, the assets picker will pop too. 当有资源已选时,点击按钮将把已选资源通过路由返回。 资源选择器将识别并一同返回。
override
dispose() → void
Keep a dispose method to sync with State. 保留一个 dispose 方法与 State 同步。
override
failedItemBuilder(BuildContext context) Widget
The item widget when AssetEntity.thumbData load failed. 资源缩略数据加载失败时使用的部件
inherited
initStateAndTicker(AssetPickerViewerState<AssetEntity, AssetPathEntity> s, TickerProvider v) → void
Call when viewer is calling initState. 当预览器调用 initState 时注册 StateTickerProvider
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
previewWidgetLoadStateChanged(BuildContext context, ExtendedImageState state, {bool hasLoaded = false}) Widget
Common image load state changed callback with Widget. 图片加载状态的部件回调
inherited
selectAsset(AssetEntity entity) → void
inherited
selectButton(BuildContext context) Widget
Select button. 选择按钮
override
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(AssetEntity entity) → void
inherited
updateAnimation(ExtendedImageGestureState state) → void
Execute scale animation when double tap. 双击时执行缩放动画

Operators

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