MorphPieceChannel class

A per-frame geometry channel for a MorphPiece: a translation plus per-axis scales over the piece's base MorphPiece.rect, written by the app (a drag, a tether, an orbit) and consumed by the skin's render object directly. A write repaints and re-traces the skin with no widget rebuild and no relayout - the same citizenship flight ticks have.

The delta lives in the group's local pixels and applies about the base rect's center. The skin mirrors it onto the piece's mass and, as a child-local paint transform, onto the content: one rigid body. The content paint-scales rather than reflows (text does not rewrap at a stretched width) - the contract of the channel, invisible at tether scales. A MorphTag inside the content measures itself through the same transform, so a flight launches from wherever the piece currently stands; hit testing follows the displaced content, which must stay within the group's own box to remain reachable.

The app owns the channel: create it in a State, dispose it there, hand it to MorphPiece.channel. Transient motion (a drag) commits into the base rect at rest and calls reset - the channel carries the live delta, the rect carries the truth.

Inheritance

Constructors

MorphPieceChannel()

Properties

hashCode int
The hash code for this object.
no setterinherited
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
isIdentity bool
Whether the channel currently displaces nothing.
no setter
offset Offset
Translation of the piece's base rect, in group-local px.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scaleX double
Horizontal scale about the base rect's center.
no setter
scaleY double
Vertical scale about the base rect's center.
no setter

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
apply(Rect base) Rect
base displaced by the current delta: shifted by offset, scaled about its center by scaleX and scaleY.
dispose() → void
Discards any resources used by the object.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
Call all the registered listeners.
inherited
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that are notified when the object changes.
inherited
reset() → void
Returns the channel to identity.
toString() String
A string representation of this object.
inherited
update({Offset? offset, double? scaleX, double? scaleY}) → void
Writes the delta; omitted fields keep their value. Notifies only when something actually changed, so an idle writer costs nothing.

Operators

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