Switched to using textGetString for action descriptions and app info

This commit is contained in:
Adubbz 2018-02-25 18:23:19 +11:00 committed by plutoo
parent 62e26552d0
commit bb53f73cc7
4 changed files with 73 additions and 6 deletions

View File

@ -10,6 +10,4 @@ Build with Makefile.nx directly or just run ```make```.
#### Credits
* This uses code based on 3DS [new-hbmenu](https://github.com/fincs/new-hbmenu).
* The "switchicon-questionmark" icon is based on the icon by [Sweet Farm from the Noun Project](https://thenounproject.com/term/nintendo-switch/694750/).
* "folder_icon": [Original](https://www.iconfinder.com/icons/97888/docs_folder_google_icon) icon by Dakirby309, modified by @fincs.
* [nanojpeg](https://svn.emphy.de/nanojpeg/trunk/nanojpeg/nanojpeg.c) is used for handling JPEG icons.

View File

@ -214,6 +214,70 @@ const char* const g_strings[StrId_Max][16] =
),
},
[StrId_AppInfo_Author] =
{
STR_EN("Author"),
STR_ES("Autor"),
STR_DE("Autor"),
STR_FR("Auteur"),
STR_IT("Autore"),
STR_JP("著者"),
STR_PT("Autor"),
STR_NL("Auteur"),
STR_KO("저자"),
STR_RU("автор"),
STR_ZH("作者"),
STR_TW("作者"),
},
[StrId_AppInfo_Version] =
{
STR_EN("Version"),
STR_ES("Versión"),
STR_DE("Ausführung"),
STR_FR("Version"),
STR_IT("Versione"),
STR_JP("バージョン"),
STR_PT("Versão"),
STR_NL("Versie"),
STR_KO("번역"),
STR_RU("Версия"),
STR_ZH(""),
STR_TW(""),
},
[StrId_Actions_Launch] =
{
STR_EN("Launch"),
STR_ES("Lanzamiento"),
STR_DE("Starten"),
STR_FR("Lancement"),
STR_IT("Lanciare"),
STR_JP("打ち上げ"),
STR_PT("Lançamento"),
STR_NL("Lancering"),
STR_KO("쏘다"),
STR_RU("запуск"),
STR_ZH("发射"),
STR_TW("发射"),
},
[StrId_Actions_Open] =
{
STR_EN("Open"),
STR_ES("Abierto"),
STR_DE("Öffnen"),
STR_FR("Ouvrir"),
STR_IT("Aperto"),
STR_JP("開いた"),
STR_PT("Aberto"),
STR_NL("Open"),
STR_KO("열다"),
STR_RU("открыто"),
STR_ZH("打开"),
STR_TW("打开"),
},
/*[StrId_Reboot] =
{
STR_EN(

View File

@ -12,6 +12,11 @@ typedef enum
StrId_NoAppsFound_Title,
StrId_NoAppsFound_Msg,
StrId_AppInfo_Author,
StrId_AppInfo_Version,
StrId_Actions_Launch,
StrId_Actions_Open,
StrId_Reboot,
StrId_ReturnToHome,

View File

@ -191,18 +191,18 @@ static void drawEntry(menuEntry_s* me, int off_x, int is_active) {
if (me->type != ENTRY_TYPE_FOLDER) {
memset(tmpstr, 0, sizeof(tmpstr));
snprintf(tmpstr, sizeof(tmpstr)-1, "Author: %s", me->author);
snprintf(tmpstr, sizeof(tmpstr)-1, "%s: %s", textGetString(StrId_AppInfo_Author), me->author);
DrawText(interuiregular14, start_x, start_y + 28 + 30, themeCurrent.textColor, tmpstr);
memset(tmpstr, 0, sizeof(tmpstr));
snprintf(tmpstr, sizeof(tmpstr)-1, "Version: %s", me->version);
snprintf(tmpstr, sizeof(tmpstr)-1, "%s: %s", textGetString(StrId_AppInfo_Version), me->version);
DrawText(interuiregular14, start_x, start_y + 28 + 30 + 18 + 6, themeCurrent.textColor, tmpstr);
drawImage(1280 - 126 - 30, 720 - 48, 32, 32, themeCurrent.buttonAImage, IMAGE_MODE_RGBA32);
DrawText(interuiregular18, 1280 - 90 - 30, 720 - 47, themeCurrent.textColor, "Launch");
DrawText(interuiregular18, 1280 - 90 - 30, 720 - 47, themeCurrent.textColor, textGetString(StrId_Actions_Launch));
}
else {
drawImage(1280 - 126 - 30, 720 - 48, 32, 32, themeCurrent.buttonAImage, IMAGE_MODE_RGBA32);
DrawText(interuiregular18, 1280 - 90 - 30, 720 - 47, themeCurrent.textColor, "Open");
DrawText(interuiregular18, 1280 - 90 - 30, 720 - 47, themeCurrent.textColor, textGetString(StrId_Actions_Open));
}
}
}