ReorderableBuilderController class

Handles logic to set all ReorderableEntity that are related to the children.

Every child gets a ReorderableEntity that contains information about the position, the size and so on. This is need for calculations later when the children are moving or changing their position.

Inheritance

Properties

childrenKeyMap Map<String, ReorderableEntity>
finalinherited
childrenOrderMap Map<int, ReorderableEntity>
finalinherited
draggedEntity ReorderableEntity?
Instance of dragged entity when dragging starts.
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
isScrollableOutside bool
Defines if the scrollable part is outside of the widget.
getter/setter pairinherited
lockedIndices List<int>
Indices of children that cannot move while drag and drop.
getter/setter pairinherited
offsetMap Map<int, Offset>
finalinherited
releasedReorderableEntity ReleasedReorderableEntity?
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scrollOffset Offset
Holding this value for better performance.
getter/setter pairinherited
startDraggingScrollOffset Offset
Saves the state of scroll Offset when the drag and drop is starting.
getter/setter pairinherited

Methods

getReorderableEntity({required ValueKey key, required int index}) ReorderableEntity
Creates or updates ReorderableEntity related to key and returns it.
inherited
handleCreatedChild({required Offset? offset, required Size size, required ReorderableEntity reorderableEntity}) ReorderableEntity
Updates specific values of reorderableEntity and update maps.
inherited
handleDeviceOrientationChanged() → void
Resets all entities in childrenOrderMap and childrenKeyMap.
inherited
handleDragEnd() List<ReorderUpdateEntity>?
inherited
handleDragStarted({required ReorderableEntity reorderableEntity, required Offset currentScrollOffset, required List<int> lockedIndices, required bool isScrollableOutside}) → void
inherited
handleDragUpdate({required PointerMoveEvent pointerMoveEvent}) bool
inherited
handleMovingFinished({required ReorderableEntity reorderableEntity}) ReorderableEntity
Updates offset and order id of reorderableEntity faded in.
inherited
handleOpacityFinished({required ReorderableEntity reorderableEntity}) ReorderableEntity
Updates offset and order id of reorderableEntity faded in.
inherited
initChildren({required List<Widget> children}) → void
Adds ReorderableEntity for all children to two maps.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
reorderList<T>({required List<T> items, required List<ReorderUpdateEntity> reorderUpdateEntities}) List<T>
Reorders list of items that depends on reorderUpdateEntities.
inherited
replaceMaps({required Map<String, ReorderableEntity> updatedChildrenKeyMap, required Map<int, ReorderableEntity> updatedChildrenOrderMap}) → void
inherited
toString() String
A string representation of this object.
inherited
updateChildren({required List<Widget> children}) → void
Iterates through children and updates childrenKeyMap and childrenOrderMap.
updateReleasedReorderableEntity({required ReleasedReorderableEntity releasedReorderableEntity}) → void
inherited
updateToActualPositions() → void
Iterates through childrenKeyMap and updates ReorderableEntity.
inherited

Operators

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