mirror of
https://github.com/DarkFlippers/unleashed-firmware
synced 2024-12-22 10:43:11 +00:00
28 lines
496 B
C
28 lines
496 B
C
|
#pragma once
|
||
|
#include <stdint.h>
|
||
|
#include <gui/modules/dialog_ex.h>
|
||
|
|
||
|
class iButtonApp;
|
||
|
|
||
|
class iButtonEvent {
|
||
|
public:
|
||
|
// events enum
|
||
|
enum class Type : uint8_t {
|
||
|
EventTypeTick,
|
||
|
EventTypeBack,
|
||
|
EventTypeMenuSelected,
|
||
|
EventTypeDialogResult,
|
||
|
EventTypeTextEditResult,
|
||
|
EventTypeByteEditResult,
|
||
|
};
|
||
|
|
||
|
// payload
|
||
|
union {
|
||
|
uint32_t menu_index;
|
||
|
DialogExResult dialog_result;
|
||
|
} payload;
|
||
|
|
||
|
// event type
|
||
|
Type type;
|
||
|
};
|