getToolbarAnchor static method
- TextSelectionToolbarAnchors anchors
Determines the Offset that the toolbar will be anchored to.
Implementation
static Offset getToolbarAnchor(TextSelectionToolbarAnchors anchors) {
// Since this will be positioned below the anchor point, use the secondary
// anchor by default.
return anchors.secondaryAnchor == null ? anchors.primaryAnchor : anchors.secondaryAnchor!;
}