X-Git-Url: https://glassweightruler.freedombox.rocks/gitweb/Ventoy.git/blobdiff_plain/ef80baf150f48e2b318e1e60fb95bf61a0555c72..2d1230cba48162eb76562a66dee805cebfee65b9:/Ventoy2Disk/Ventoy2Disk/Language.c diff --git a/Ventoy2Disk/Ventoy2Disk/Language.c b/Ventoy2Disk/Ventoy2Disk/Language.c index 66a1e56..2c135aa 100644 --- a/Ventoy2Disk/Ventoy2Disk/Language.c +++ b/Ventoy2Disk/Ventoy2Disk/Language.c @@ -1,74 +1,36 @@ -/****************************************************************************** - * Language.c - * - * Copyright (c) 2020, longpanda - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 3 of the - * License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, see . - * - */ - -#include -#include "Ventoy2Disk.h" -#include "Language.h" - -const TCHAR * g_Str_English[STR_ID_MAX] = -{ - TEXT("Error"), - TEXT("Warning"), - TEXT("Info"), - TEXT("Please run under the correct directory!"), - TEXT("Device"), - TEXT("Ventoy At Local"), - TEXT("Ventoy In Device"), - TEXT("Status - READY"), - TEXT("Install"), - TEXT("Update"), - TEXT("Upgrade operation is safe, ISO files will be unchanged.\r\nContinue?"), - TEXT("The disk will be formatted and all the data will be lost.\r\nContinue?"), - TEXT("The disk will be formatted and all the data will be lost.\r\nContinue? (Double Check)"), - TEXT("Congratulations!\r\nVentoy has been successfully installed to the device."), - TEXT("An error occurred during the installation. You can try again and check log.txt for detail."), - TEXT("Congratulations!\r\nVentoy has been successfully updated to the device."), - TEXT("An error occurred during the update. You can try again and check log.txt for detail."), - - TEXT("A thread is running, please wait..."), -}; - -const TCHAR * g_Str_ChineseSimple[STR_ID_MAX] = -{ - TEXT("´íÎó"), - TEXT("¾¯¸æ"), - TEXT("ÌáÐÑ"), - TEXT("ÇëÔÚÕýÈ·µÄĿ¼ÏÂÔËÐÐ!"), - TEXT("É豸"), - TEXT("±¾µØ Ventoy"), - TEXT("É豸ÉÏ Ventoy"), - TEXT("״̬ - ×¼±¸¾ÍÐ÷"), - TEXT("°²×°"), - TEXT("Éý¼¶"), - TEXT("Éý¼¶²Ù×÷Êǰ²È«µÄ, ISOÎļþ²»»á¶ªÊ§\r\nÊÇ·ñ¼ÌÐø£¿"), - TEXT("´ÅÅ̻ᱻ¸ñʽ»¯, ËùÓÐÊý¾Ý¶¼»á¶ªÊ§!\r\nÊÇ·ñ¼ÌÐø£¿"), - TEXT("´ÅÅ̻ᱻ¸ñʽ»¯, ËùÓÐÊý¾Ý¶¼»á¶ªÊ§!\r\nÔÙ´ÎÈ·ÈÏÊÇ·ñ¼ÌÐø£¿"), - TEXT("¹§Ï²Äã! Ventoy ÒѾ­³É¹¦°²×°µ½´ËÉ豸ÖÐ."), - TEXT("°²×° Ventoy ¹ý³ÌÖз¢Éú´íÎó. Äã¿ÉÒÔÖØÊÔÒ»´Î, ÏêϸÐÅÏ¢Çë²éÔÄ log.txt Îļþ."), - TEXT("¹§Ï²Äã! а汾µÄ Ventoy ÒѾ­³É¹¦¸üе½´ËÉ豸ÖÐ."), - TEXT("¸üРVentoy ¹ý³ÌÖÐÓöµ½´íÎó. Äã¿ÉÒÔÖØÊÔÒ»´Î, ÏêϸÐÅÏ¢Çë²éÔÄ log.txt Îļþ."), - - TEXT("µ±Ç°ÓÐÈÎÎñÕýÔÚÔËÐÐ, ÇëµÈ´ý..."), -}; - -const TCHAR * GetString(enum STR_ID ID) -{ - return g_Str_English[ID]; -}; +/****************************************************************************** + * Language.c + * + * Copyright (c) 2020, longpanda + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, see . + * + */ + +#include +#include +#include "Ventoy2Disk.h" +#include "Language.h" + +const TCHAR * GetString(enum STR_ID ID) +{ + if (g_cur_lang_data) + { + return g_cur_lang_data->MsgString[ID]; + } + else + { + return NULL; + } +};