Skip to content

Commit

Permalink
more temp debug for windows
Browse files Browse the repository at this point in the history
  • Loading branch information
mcleinman committed Oct 10, 2024
1 parent 947fd91 commit 318f2c3
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions src/localizer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -653,7 +653,7 @@ QString Localizer::getTranslatedCityName(const QString& cityName) const {

auto value = getCapitalizedStringFromI18n(i18nCityId);

if (cityName.contains("Malm") || cityName.contains("Salt")) {
if (cityName.contains("Malm")) {
logger.debug() << "TEMP:" << cityName << " parsed " << parsedCityName
<< " i18nCityId " << i18nCityId << " value " << value;
}
Expand All @@ -679,8 +679,15 @@ QString Localizer::getTranslationCode() {

// static
QString Localizer::getCapitalizedStringFromI18n(const QString& id) {
QString str = I18nStrings::instance()->t(I18nStrings::getString(id));
return toUpper(QLocale(getTranslationCode()), str);
I18nStrings::String gstr = I18nStrings::getString(id);
QString str = I18nStrings::instance()->t(gstr);
QString gtc = getTranslationCode();
QString finalOne = toUpper(QLocale(gtc), str);
if (id.contains("Malm")) {
logger.debug() << "TEMP2:" << gstr << " str " << str << " gtc " << gtc
<< " returning " << finalOne;
}
return finalOne;
}

// static
Expand Down

0 comments on commit 318f2c3

Please sign in to comment.