currentStateValue property

  1. @override
bool get currentStateValue

Callback to query the widget's state for the value to be assigned to currentState

Implementation

@override
bool get currentStateValue {
  switch (widget.clipboardAction) {
    case ClipboardAction.cut:
      return !controller.readOnly && !controller.selection.isCollapsed;
    case ClipboardAction.copy:
      return !controller.selection.isCollapsed;
    case ClipboardAction.paste:
      return !controller.readOnly && (kIsWeb || widget._monitor.canPaste);
  }
}