ShortcutSerialization.character constructor
Creates a ShortcutSerialization representing a single character.
This is used by a CharacterActivator to serialize itself.
Implementation
ShortcutSerialization.character(String character, {
bool alt = false,
bool control = false,
bool meta = false,
}) : assert(character.length == 1),
_character = character,
_trigger = null,
_alt = alt,
_control = control,
_meta = meta,
_shift = null,
_internal = <String, Object?>{
_kShortcutCharacter: character,
_kShortcutModifiers: (control ? _shortcutModifierControl : 0) |
(alt ? _shortcutModifierAlt : 0) |
(meta ? _shortcutModifierMeta : 0),
};