|
|
|
|
#pragma once
|
|
|
|
|
#include "GlobalDefine.h"
|
|
|
|
|
#include "LabVecRang.h"
|
|
|
|
|
#include "Module.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//<2F><><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD><C4BC>ı<EFBFBD><C4B1><EFBFBD><EFBFBD>Ͷ<EFBFBD>ȡ
|
|
|
|
|
class CWorkFileMgr:public CModule
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
CWorkFileMgr(void);
|
|
|
|
|
~CWorkFileMgr(void);
|
|
|
|
|
virtual MODULE GetModuleType(){return _WORK_FILE_PROP;};
|
|
|
|
|
virtual void OnAppInitialize();
|
|
|
|
|
|
|
|
|
|
void SaveWorkFile(CString FilePath);
|
|
|
|
|
void ReadWorkFile(CString FilePath);
|
|
|
|
|
void SeparateStrVec(CLabVecRang &LabVecRang,vector<CLabVecRang> &LabVecRangVec,LAB_TYPE StrLabStart,LAB_TYPE StrLabEnd);
|
|
|
|
|
void SeparateLabVecRangVec(vector<CLab> &LabVec,vector<CLabVecRang>&LabVecRangVec,CString Path,LAB_TYPE StrLabStart,LAB_TYPE StrLabEnd);
|
|
|
|
|
CLab FindLab(CLabVecRang &LabVecRang,LAB_TYPE LabStr);
|
|
|
|
|
void OnOpenFile();
|
|
|
|
|
void OnSaveFile();
|
|
|
|
|
void OnSaveFileAs();
|
|
|
|
|
void OpenObjFile();
|
|
|
|
|
void SaveObjFile();
|
|
|
|
|
static CString GetCurOpenFilePath(){return m_CurOpenFile;};
|
|
|
|
|
bool IsOpenFile();
|
|
|
|
|
void ReadObjFileByName(CString FileName);
|
|
|
|
|
void SaveObjTemplateFile(CString FilePath);
|
|
|
|
|
void ReadObjTemplateFile(CString FileName);
|
|
|
|
|
void SaveWorkFileExt(CString FilePath,vector<CLab> &LabVec);
|
|
|
|
|
void WriteDbxyVecToFile(vector<Dbxy> &vec,CString Path);
|
|
|
|
|
void SaveFileName(CString FileName);
|
|
|
|
|
void OnOpenFileExt(CString Path);
|
|
|
|
|
void ExtParToTxtFile();
|
|
|
|
|
void ExtParToTxtFileOnAppOpen();
|
|
|
|
|
void OpenObjTxtFile();
|
|
|
|
|
void SaveObjTxtFile();
|
|
|
|
|
private:
|
|
|
|
|
void ReadWorkFileExt(CString FilePath,vector<CLab> &LabVec);
|
|
|
|
|
void SaveFile(CString FileName);
|
|
|
|
|
CString CreatMapHistoryPath();
|
|
|
|
|
private:
|
|
|
|
|
static CString m_CurOpenFile;//<2F><>ǰ<EFBFBD><EFBFBD><F2BFAAB5>ļ<EFBFBD><C4BC><EFBFBD>
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
extern CWorkFileMgr *gWorkFileMgr;
|