ActionKey constructor

ActionKey(
  1. VirtualKeyboardKeyAction action
)

Implementation

ActionKey(VirtualKeyboardKeyAction action)
    : super(keyType: VirtualKeyboardKeyType.Action, action: action) {
  switch (action) {
    case VirtualKeyboardKeyAction.Space:
      super.text = ' ';
      super.capsText = ' ';
      super.willExpand = true;
      break;
    case VirtualKeyboardKeyAction.Return:
      super.text = '\n';
      super.capsText = '\n';
      break;
    case VirtualKeyboardKeyAction.Backspace:
      super.willExpand = true;
      break;
    default:
      break;
  }
}