PhotoBrowser class

Inheritance

Constructors

PhotoBrowser({Key? key, required int itemCount, required int initIndex, PhotoBrowserController? controller, RouteType routeType = RouteType.fade, bool allowShrinkPhoto = true, StringBuilder? heroTagBuilder, DisplayTypeBuilder? displayTypeBuilder, ImageProviderBuilder? imageProviderBuilder, ImageProviderBuilder? thumbImageProviderBuilder, StringBuilder? imageUrlBuilder, StringBuilder? thumbImageUrlBuilder, CustomChildBuilder? customChildBuilder, LoadingBuilder? loadingBuilder, Widget? loadFailedChild, PositionBuilder? pageCodeBuild, PositionsBuilder? positions, List<PositionBuilder>? positionBuilders, Color? imageColor, BlendMode? imageColorBlendMode, bool? gaplessPlayback, FilterQuality? filterQuality, Color? backcolor, bool allowTapToPop = true, BoolBuilder? allowTapToPopBuilder, bool allowSwipeDownToPop = true, bool allowPullDownToPop = false, bool canPopWhenScrolling = true, PullDownPopConfig pullDownPopConfig = const PullDownPopConfig(), bool? showPageTurnBtn, bool reverse = false, PageController? pageController, ScrollPhysics? scrollPhysics, Axis scrollDirection = Axis.horizontal, ValueChanged<int>? onPageChanged})

Properties

allowPullDownToPop bool
下拉关闭功能开关
final
allowShrinkPhoto bool
允许缩小图片
final
allowSwipeDownToPop bool
向下轻扫关闭功能开关(allowPullDownToPop 为) allowPullDownToPop 等于 true 则allowSwipeDownToPop设置无效
final
allowTapToPop bool
单击关闭功能开关
final
allowTapToPopBuilder BoolBuilder?
final
backcolor Color?
设置背景色
final
canPopWhenScrolling bool
滚动状态可否关闭
final
controller PhotoBrowserController?
控制器,用于给外部提供一些功能,如图片数据、pop、刷新相册浏览器状态
final
customChildBuilder CustomChildBuilder?
设置widget
final
displayTypeBuilder DisplayTypeBuilder?
设置每页显示的类型
final
filterQuality FilterQuality?
final
gaplessPlayback bool?
final
hashCode int
The hash code for this object.
no setterinherited
heroTagBuilder StringBuilder?
设置每张图片飞行动画的tag
final
imageColor Color?
final
imageColorBlendMode BlendMode?
final
imageProviderBuilder ImageProviderBuilder?
设置每张大图的imageProvider imageProviderBuilder、imageUrlBuilder二选一,必选
final
imageUrlBuilder StringBuilder?
设置每张大图的url
final
initIndex int
初始索引
final
itemCount int
图片总数
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
loadFailedChild Widget?
图片加载失败Widget
final
loadingBuilder LoadingBuilder?
设置自定义图片加载指示器,为null则使用默认的
final
onPageChanged ValueChanged<int>?
final
pageCodeBuild PositionBuilder?
设置自定义页码,为null则使用默认的
final
pageController PageController?
final
positionBuilders List<PositionBuilder>?
设置更多自定控件(页面索引变化会刷新里面的builder)
final
positions PositionsBuilder?
设置更多自定控件
final
pullDownPopConfig PullDownPopConfig
下拉关闭功能配置
final
reverse bool
final
routeType RouteType
路由类型,默认值:RouteType.fade
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scrollDirection Axis
final
scrollPhysics ScrollPhysics?
final
showPageTurnBtn bool
显示左右翻页箭头按钮
final
thumbImageProviderBuilder ImageProviderBuilder?
设置每张缩略图的imageProvider thumbImageProviderBuilder、thumbImageUrlBuilder二选一,可选
final
thumbImageUrlBuilder StringBuilder?
设置每张缩略图的url
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<StatefulWidget>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
push(BuildContext context, {bool rootNavigator = true, bool fullscreenDialog = true, Duration? transitionDuration, Widget? page}) Future
弹出图片浏览器
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

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