feat: 实现撤销/重做功能和CSV导出支持

- 添加撤销/重做管理器,支持添加、删除、编辑、移动等操作的撤销/重做
- 在应用上下文中集成撤销/重做管理器,最大支持50条历史记录
- 为所有基本操作(新建、编辑、删除、上移、下移、清理)添加撤销记录
- 扩展导出功能,支持CSV格式导出(除原有JSON格式外)
- 添加路径格式验证函数,确保导入数据的有效性
- 更新UI文件对话框过滤器以包含CSV格式选项
This commit is contained in:
2026-05-01 22:42:56 +08:00
parent 06e4c15b5c
commit 1f48551199
10 changed files with 700 additions and 20 deletions
+1 -1
View File
@@ -142,7 +142,7 @@ int btn_export_cb(Ihandle *self)
IupSetAttribute(filedlg, "DIALOGTYPE", "SAVE");
IupSetAttribute(filedlg, "TITLE", lua_config_get_string("label", "export_title"));
IupSetAttribute(filedlg, "FILTER", "json");
IupSetAttribute(filedlg, "EXTFILTER", "JSON 文件 (*.json)|*.json");
IupSetAttribute(filedlg, "EXTFILTER", "JSON 文件 (*.json)|*.json|CSV 文件 (*.csv)|*.csv");
IupSetAttribute(filedlg, "DEFAULTEXT", "json");
char default_name[64];