in src/main/cpp/launcher/windows/src/Launcher.c [388:417]
void resolveLauncherStringProperty(LauncherProperties * props, WCHAR ** result) {
if(*result!=NULL) {
WCHAR * propStart = searchW(*result, L"$P{");
if(propStart!=NULL) {
WCHAR * propEnd = searchW(propStart + 3, L"}");
if(propEnd!=NULL) {
WCHAR * propName;
writeMessageA(props, OUTPUT_LEVEL_DEBUG, 0, "... resolving string property", 1);
propName = appendStringNW(NULL, 0, propStart + 3 ,
getLengthW(propStart + 3) - getLengthW(propEnd));
writeMessageA(props, OUTPUT_LEVEL_DEBUG, 0, "... property name is : ", 0);
writeMessageW(props, OUTPUT_LEVEL_DEBUG, 0, propName, 1);
if(propName!=NULL) {
char * name = toChar(propName);
const WCHAR * propValue = getI18nProperty(props, name);
if(propValue!=NULL) {
WCHAR * tmp = appendStringNW(NULL, 0, *result, getLengthW(*result) - getLengthW(propStart));
tmp = appendStringW(tmp, propValue);
tmp = appendStringW(tmp, propEnd + 1);
FREE(*result);
*result = tmp;
}
FREE(name);
FREE(propName);
}
}
}
}
}