InteractiveLayerController class

A controller similar to ListView.scrollController to control interactive layer from outside in addition to get some information from internal states of layer to outside.

This controller acts as the bridge between outside of the chart component and interactive layer.

Inheritance

Constructors

InteractiveLayerController({Offset floatingMenuInitialPosition = Offset.zero})
Creates an instance of InteractiveLayerController.

Properties

currentState InteractiveState
Current state of the interactive layer.
getter/setter pair
floatingMenuPosition Offset
The current position of the floating menu.
getter/setter pair
floatingMenuSize Size
The size of the floating menu.
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
onAddNewTool ↔ dynamic Function(DrawingToolConfig)?
The callback to be called when a new drawing tool going to be added.
getter/setter pair
onCancelAdding VoidCallback?
The callback to be called when the user cancels adding a drawing tool.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
cancelAdding() → void
Cancels the adding of a drawing tool if we're in InteractiveAddingToolState.
dispose() → void
Discards any resources used by the object.
inherited
isPointInFloatingMenu(Offset localPosition) bool
Checks if a given local position is within the floating menu bounds.
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
startAddingNewTool(DrawingToolConfig config) → void
Updates the InteractiveLayer's internal state to start adding the config to the chart.
toString() String
A string representation of this object.
inherited

Operators

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