class KeyEvent
Defined at line 260 of file fidling/gen/sdk/fidl/fuchsia.ui.input3/fuchsia.ui.input3/cpp/fidl/fuchsia.ui.input3/cpp/natural_types.h
A Keyboard event generated to reflect key input. `timestamp` and `type` are required.
At least one of `key` and `key_meaning` must be set for a valid event.
Public Methods
void KeyEvent ()
Defined at line 266 of file fidling/gen/sdk/fidl/fuchsia.ui.input3/fuchsia.ui.input3/cpp/fidl/fuchsia.ui.input3/cpp/natural_types.h
void KeyEvent (KeyEvent && )
Defined at line 267 of file fidling/gen/sdk/fidl/fuchsia.ui.input3/fuchsia.ui.input3/cpp/fidl/fuchsia.ui.input3/cpp/natural_types.h
void KeyEvent (Storage_ storage)
void KeyEvent (const KeyEvent & other)
KeyEvent & operator= (const KeyEvent & other)
bool operator== (const KeyEvent & other)
bool operator!= (const KeyEvent & other)
bool IsEmpty ()
const std::optional<int64_t> & timestamp ()
Time in nanoseconds when the event was recorded, in the `CLOCK_MONOTONIC` time base.
The timestamp is **required** on every key event, and users can expect that it
will always be present.
::std::optional<int64_t> & timestamp ()
Time in nanoseconds when the event was recorded, in the `CLOCK_MONOTONIC` time base.
The timestamp is **required** on every key event, and users can expect that it
will always be present.
KeyEvent & timestamp (std::optional<int64_t> value)
Time in nanoseconds when the event was recorded, in the `CLOCK_MONOTONIC` time base.
The timestamp is **required** on every key event, and users can expect that it
will always be present.
const std::optional< ::fuchsia_ui_input3::KeyEventType> & type ()
Type of event.
::std::optional< ::fuchsia_ui_input3::KeyEventType> & type ()
Type of event.
KeyEvent & type (std::optional< ::fuchsia_ui_input3::KeyEventType> value)
Type of event.
const std::optional< ::fuchsia_input::Key> & key ()
Identifies the key ignoring modifiers, layout, prior key events, etc. This is called
the "physical key" on some platforms. In cases where the key event did not originate
from a physical keyboard (e.g. onscreen keyboard) this field may be empty.
::std::optional< ::fuchsia_input::Key> & key ()
Identifies the key ignoring modifiers, layout, prior key events, etc. This is called
the "physical key" on some platforms. In cases where the key event did not originate
from a physical keyboard (e.g. onscreen keyboard) this field may be empty.
KeyEvent & key (std::optional< ::fuchsia_input::Key> value)
Identifies the key ignoring modifiers, layout, prior key events, etc. This is called
the "physical key" on some platforms. In cases where the key event did not originate
from a physical keyboard (e.g. onscreen keyboard) this field may be empty.
const std::optional< ::fuchsia_ui_input3::Modifiers> & modifiers ()
Modifiers in effect at the time of the event.
Example:
CapsLock is off, user presses CapsLock, then A, then releases both.
Event sequence is as follows:
1. type: Pressed, key: CapsLock, modifiers: None
2. type: Pressed, key: A, modifiers: CapsLock
3. type: Released, key: CapsLock, modifiers: CapsLock
4. type: Released, key: A, modifiers: CapsLock
CapsLock is on, user presses CapsLock, then A, then releases both.
1. type: Pressed, key: CapsLock, modifiers: CapsLock
2. type: Pressed, key: A, modifiers: None
3. type: Released, key: CapsLock, modifiers: None
4. type: Released, key: A, modifiers: None
::std::optional< ::fuchsia_ui_input3::Modifiers> & modifiers ()
Modifiers in effect at the time of the event.
Example:
CapsLock is off, user presses CapsLock, then A, then releases both.
Event sequence is as follows:
1. type: Pressed, key: CapsLock, modifiers: None
2. type: Pressed, key: A, modifiers: CapsLock
3. type: Released, key: CapsLock, modifiers: CapsLock
4. type: Released, key: A, modifiers: CapsLock
CapsLock is on, user presses CapsLock, then A, then releases both.
1. type: Pressed, key: CapsLock, modifiers: CapsLock
2. type: Pressed, key: A, modifiers: None
3. type: Released, key: CapsLock, modifiers: None
4. type: Released, key: A, modifiers: None
KeyEvent & modifiers (std::optional< ::fuchsia_ui_input3::Modifiers> value)
Modifiers in effect at the time of the event.
Example:
CapsLock is off, user presses CapsLock, then A, then releases both.
Event sequence is as follows:
1. type: Pressed, key: CapsLock, modifiers: None
2. type: Pressed, key: A, modifiers: CapsLock
3. type: Released, key: CapsLock, modifiers: CapsLock
4. type: Released, key: A, modifiers: CapsLock
CapsLock is on, user presses CapsLock, then A, then releases both.
1. type: Pressed, key: CapsLock, modifiers: CapsLock
2. type: Pressed, key: A, modifiers: None
3. type: Released, key: CapsLock, modifiers: None
4. type: Released, key: A, modifiers: None
const std::optional< ::fuchsia_ui_input3::KeyMeaning> & key_meaning ()
Meaning of the key.
::std::optional< ::fuchsia_ui_input3::KeyMeaning> & key_meaning ()
Meaning of the key.
KeyEvent & key_meaning (std::optional< ::fuchsia_ui_input3::KeyMeaning> value)
Meaning of the key.
KeyEvent & operator= (KeyEvent && )
Defined at line 268 of file fidling/gen/sdk/fidl/fuchsia.ui.input3/fuchsia.ui.input3/cpp/fidl/fuchsia.ui.input3/cpp/natural_types.h
const std::optional<uint32_t> & repeat_sequence ()
The sequence number of this `KeyEvent` in the sequence of autorepeated
keys.
Unset if this event has been generated in the immediate response to an
input from the keyboard driver. If the `KeyEvent` has been generated
through the autorepeat mechanism, this property is set and is
incremented by one for each successive generated key event.
::std::optional<uint32_t> & repeat_sequence ()
The sequence number of this `KeyEvent` in the sequence of autorepeated
keys.
Unset if this event has been generated in the immediate response to an
input from the keyboard driver. If the `KeyEvent` has been generated
through the autorepeat mechanism, this property is set and is
incremented by one for each successive generated key event.
KeyEvent & repeat_sequence (std::optional<uint32_t> value)
The sequence number of this `KeyEvent` in the sequence of autorepeated
keys.
Unset if this event has been generated in the immediate response to an
input from the keyboard driver. If the `KeyEvent` has been generated
through the autorepeat mechanism, this property is set and is
incremented by one for each successive generated key event.
const std::optional< ::fuchsia_ui_input3::LockState> & lock_state ()
The lock state in effect at the time of the event.
For example, if CapsLock effect is turned on (pressing 'a' results in
the effect 'A'), the corresponding bit in the lock state is set.
NOTE: `LockState` is different from whether the CapsLock modifier key
is actuated or not. `LockState.CAPS_LOCK` can be active even if the
Caps Lock key is not currently actuated.
::std::optional< ::fuchsia_ui_input3::LockState> & lock_state ()
The lock state in effect at the time of the event.
For example, if CapsLock effect is turned on (pressing 'a' results in
the effect 'A'), the corresponding bit in the lock state is set.
NOTE: `LockState` is different from whether the CapsLock modifier key
is actuated or not. `LockState.CAPS_LOCK` can be active even if the
Caps Lock key is not currently actuated.
KeyEvent & lock_state (std::optional< ::fuchsia_ui_input3::LockState> value)
The lock state in effect at the time of the event.
For example, if CapsLock effect is turned on (pressing 'a' results in
the effect 'A'), the corresponding bit in the lock state is set.
NOTE: `LockState` is different from whether the CapsLock modifier key
is actuated or not. `LockState.CAPS_LOCK` can be active even if the
Caps Lock key is not currently actuated.
const std::optional<uint32_t> & device_id ()
Identifies the device originating this event.
::std::optional<uint32_t> & device_id ()
Identifies the device originating this event.
KeyEvent & device_id (std::optional<uint32_t> value)
Identifies the device originating this event.
void KeyEvent (::fidl::internal::DefaultConstructPossiblyInvalidObjectTag )
Friends
class MemberVisitor
class NaturalTableCodingTraits