KeyEvent constructor

const KeyEvent(
  1. {required PhysicalKeyboardKey physicalKey,
  2. required LogicalKeyboardKey logicalKey,
  3. String? character,
  4. required Duration timeStamp,
  5. KeyEventDeviceType deviceType = ui.KeyEventDeviceType.keyboard,
  6. bool synthesized = false}
)

Create a const KeyEvent by providing each field.

Implementation

const KeyEvent({
  required this.physicalKey,
  required this.logicalKey,
  this.character,
  required this.timeStamp,
  this.deviceType = ui.KeyEventDeviceType.keyboard,
  this.synthesized = false,
});