2024-03-15 12:31:34 +08:00
|
|
|
|
#include "DataManage/DataHandle.h"
|
2024-03-19 17:45:12 +08:00
|
|
|
|
#include "global.h"
|
|
|
|
|
#include "SystemInfo.h"
|
|
|
|
|
#include "Logger.h"
|
|
|
|
|
#include "LanguageManager.h"
|
|
|
|
|
#include "Toast.h"
|
|
|
|
|
#include "config/ConfigManager.h"
|
2024-03-15 12:31:34 +08:00
|
|
|
|
|
2024-03-19 17:45:12 +08:00
|
|
|
|
UserType g_Admin;
|
|
|
|
|
|
|
|
|
|
string g_AppPath;
|
|
|
|
|
string g_AppDisk;
|
|
|
|
|
Logger* g_log;
|
|
|
|
|
LanguageManager* g_LngManager;
|
|
|
|
|
Toast* g_Toast;
|
|
|
|
|
bool g_isDebug;
|
|
|
|
|
uint32_t g_ScanSerial;
|
|
|
|
|
string g_gno;
|
|
|
|
|
SystemInfo* g_SystemInfo;
|
|
|
|
|
|
2024-03-15 12:31:34 +08:00
|
|
|
|
|
|
|
|
|
int main(int argc, char** argv) {
|
2024-03-19 17:45:12 +08:00
|
|
|
|
char szFilePath[MAX_PATH + 1] = { 0 };
|
|
|
|
|
GetModuleFileName(NULL, szFilePath, MAX_PATH);
|
|
|
|
|
(strrchr(szFilePath, '\\'))[1] = 0;
|
|
|
|
|
g_AppPath = szFilePath;
|
|
|
|
|
g_AppDisk = g_AppPath.substr(0, 2);
|
|
|
|
|
g_LngManager = new LanguageManager();
|
|
|
|
|
g_LngManager->Init();
|
|
|
|
|
g_Admin = ADMIN;
|
|
|
|
|
|
|
|
|
|
g_isDebug = false;
|
|
|
|
|
g_log = new Logger();
|
|
|
|
|
g_log->m_LogDao->Init();
|
|
|
|
|
g_SystemInfo = new SystemInfo();
|
|
|
|
|
g_Toast = new Toast();
|
|
|
|
|
|
|
|
|
|
|
2024-03-15 12:31:34 +08:00
|
|
|
|
DataHandle* dataHandle = new DataHandle();
|
|
|
|
|
dataHandle->Init();
|
2024-03-19 17:45:12 +08:00
|
|
|
|
|
|
|
|
|
delete g_LngManager;
|
2024-03-15 12:31:34 +08:00
|
|
|
|
delete dataHandle;
|
2024-03-19 17:45:12 +08:00
|
|
|
|
|
2024-03-15 12:31:34 +08:00
|
|
|
|
return 0;
|
|
|
|
|
}
|