将菜单的架构改成 MVP,并且进一步优化视图层和模型层的逻辑

This commit is contained in:
2026-04-01 19:42:05 +08:00
parent 0690d6a00e
commit 8b44b84d4c
54 changed files with 5362 additions and 2200 deletions

View File

@@ -1,6 +1,8 @@
#ifndef __TYPES__H__
#define __TYPES__H__
#include <stdio.h>
#define uint8_t unsigned char
#define uint16_t unsigned short
#define uint32_t unsigned int
@@ -15,4 +17,18 @@
typedef int (*FUNCPTR) ( );
// 调试模式断言
#ifdef DEBUG
#define ASSERT(expr) \
do { \
if (expr) { \
printf("Assertion failed: %s, file %s, line %d\n", \
#expr, __FILE__, __LINE__); \
} \
} while (0)
#else
#define ASSERT(expr) ((void)0) // 发布模式禁用断言
#endif
#endif