1
0
mirror of https://github.com/MarlinFirmware/Marlin.git synced 2024-11-30 15:26:18 +00:00

Add a typedef for MENU_ITEM(function,…) functions

This commit is contained in:
Scott Lahteine 2017-10-02 23:33:57 -05:00
parent 6ea2cc0293
commit a8b8d4e85e
2 changed files with 2 additions and 1 deletions

View File

@ -212,7 +212,7 @@ uint16_t max_display_update_time = 0;
void _menu_action_back(); void _menu_action_back();
void menu_action_submenu(screenFunc_t data); void menu_action_submenu(screenFunc_t data);
void menu_action_gcode(const char* pgcode); void menu_action_gcode(const char* pgcode);
void menu_action_function(screenFunc_t data); void menu_action_function(menuAction_t data);
#define DECLARE_MENU_EDIT_TYPE(_type, _name) \ #define DECLARE_MENU_EDIT_TYPE(_type, _name) \
bool _menu_edit_ ## _name(); \ bool _menu_edit_ ## _name(); \

View File

@ -84,6 +84,7 @@
// Function pointer to menu functions. // Function pointer to menu functions.
typedef void (*screenFunc_t)(); typedef void (*screenFunc_t)();
typedef void (*menuAction_t)();
void lcd_goto_screen(screenFunc_t screen, const uint32_t encoder=0); void lcd_goto_screen(screenFunc_t screen, const uint32_t encoder=0);