- localization wrappers

Currently a no-op, but if it's in it won't be forgotten later.
This commit is contained in:
Christoph Oelckers 2019-11-25 00:28:59 +01:00
parent 1f1e39fac0
commit a9ee5940fc
3 changed files with 18 additions and 4 deletions

View file

@ -111,6 +111,18 @@ private:
void DeleteForLabel(int lumpnum, FName label);
static size_t ProcessEscapes (char *str);
public:
static FString MakeMacro(const char *str)
{
//return FStringf("${%s}", str);
return str;
}
static FString MakeMacro(const char *str, size_t len)
{
//return FStringf("${%.*s}", len, str);
return FString(str, len);
}
};
#endif //__STRINGTABLE_H__

View file

@ -37,6 +37,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#include "printf.h"
#include "m_argv.h"
#include "menu/menu.h"
#include "stringtable.h"
BEGIN_DUKE_NS
@ -5017,7 +5018,7 @@ repeatcase:
}
i = strcspn(textptr, "\r\n");
gVolumeNames[j] = FString(textptr, i);
gVolumeNames[j] = StringTable::MakeMacro(textptr, i);
textptr += i;
g_volumeCnt = j+1;
@ -5118,7 +5119,7 @@ repeatcase:
}
i = strcspn(textptr, "\r\n");
gSkillNames[j] = FString(textptr, i);
gSkillNames[j] = StringTable::MakeMacro(textptr, i);
textptr+=i;
for (i=0; i<MAXSKILLS; i++)

View file

@ -36,6 +36,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#include "m_crc32.h"
#include "printf.h"
#include "menu/menu.h"
#include "stringtable.h"
BEGIN_RR_NS
@ -1886,7 +1887,7 @@ static int32_t C_ParseCommand(int32_t loop)
}
i = strcspn(textptr, "\r\n");
gVolumeNames[j] = FString(textptr, i);
gVolumeNames[j] = StringTable::MakeMacro(textptr, i);
textptr+=i;
g_volumeCnt = j+1;
continue;
@ -1910,7 +1911,7 @@ static int32_t C_ParseCommand(int32_t loop)
}
i = strcspn(textptr, "\r\n");
gSkillNames[j] = FString(textptr, i);
gSkillNames[j] = StringTable::MakeMacro(textptr, i);
textptr+=i;
for (i=0; i<MAXSKILLS; i++)