mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-05-20 04:54:45 -07:00
Updated Button Panel (#4119)
* updated button panel * fixed mismateched .c and .h files * Gui: extra events for ok button handling in button_panel * Gui: extra events for other buttons handling in button_panel Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
@@ -13,10 +13,12 @@ typedef union {
|
||||
} InfraredSceneState;
|
||||
#pragma pack(pop)
|
||||
|
||||
void infrared_scene_universal_common_item_callback(void* context, uint32_t index) {
|
||||
void infrared_scene_universal_common_item_callback(void* context, uint32_t index, InputType type) {
|
||||
InfraredApp* infrared = context;
|
||||
uint32_t event = infrared_custom_event_pack(InfraredCustomEventTypeButtonSelected, index);
|
||||
view_dispatcher_send_custom_event(infrared->view_dispatcher, event);
|
||||
if(type == InputTypeShort) {
|
||||
uint32_t event = infrared_custom_event_pack(InfraredCustomEventTypeButtonSelected, index);
|
||||
view_dispatcher_send_custom_event(infrared->view_dispatcher, event);
|
||||
}
|
||||
}
|
||||
|
||||
static void infrared_scene_universal_common_progress_input_callback(
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
void infrared_scene_universal_common_on_enter(void* context);
|
||||
bool infrared_scene_universal_common_on_event(void* context, SceneManagerEvent event);
|
||||
void infrared_scene_universal_common_on_exit(void* context);
|
||||
void infrared_scene_universal_common_item_callback(void* context, uint32_t index);
|
||||
void infrared_scene_universal_common_item_callback(void* context, uint32_t index, InputType type);
|
||||
|
||||
Reference in New Issue
Block a user