Skip to content

Engine → Platform

button_action.h

What happened to a key or button. The values are GLFW's GLFW_RELEASE / GLFW_PRESS / GLFW_REPEAT and travel unchanged through the C ABI (conjure_button_action).

Enumerations

button_action

enum class button_action : u8 {
    RELEASE = 0,
    PRESS = 1,
    REPEAT = 2
};

Functions

Public

parse_button_action

[[nodiscard]] CONJURE_API std::optional<button_action> parse_button_action(
    std::string_view name) noexcept;

Parses an enumerator name case-insensitively; nullopt for anything else.

to_string

[[nodiscard]] CONJURE_API std::string_view to_string(
    button_action action) noexcept;

The enumerator name ("PRESS"), or "" for unknown values.