Ifdef, broken variable assignement

This commit is contained in:
XargonWan 2024-09-27 13:33:35 +09:00
parent 8dfd82f4cf
commit 902d849003
2 changed files with 11 additions and 5 deletions

View file

@ -2355,10 +2355,15 @@ void GuiMenu::addVersionInfo()
mVersion.setAutoCalcExtent(glm::ivec2 {0, 0});
mVersion.setColor(mMenuColorTertiary);
const std::string applicationName {"ES-DE"};
const std::string applicationName =
#if defined(__RETRODECK__)
"RetroDECK";
#else
"ES-DE";
#endif
#if defined(__RETRODECK__)
applicationName = "RetroDECK";
std::ifstream file("/app/retrodeck/version");
std::string version;
if (file.is_open() && std::getline(file, version) && !version.empty()) {

View file

@ -695,10 +695,11 @@ int main(int argc, char* argv[])
Log::open();
{
const std::string applicationName {"ES-DE"};
const std::string applicationName =
#if defined(__RETRODECK__)
applicationName = "RetroDECK";
"RetroDECK";
#else
"ES-DE";
#endif
#if defined(__ANDROID__)