[weather dataengine] bbc: use night icons for forecast "Tonight"

parent 6d16583e
......@@ -846,7 +846,11 @@ void UKMETIon::parseFiveDayForecast(const QString& source, QXmlStreamReader& xml
const QString summaryLC = summary.toLower();
forecast->period = period;
forecast->iconName = getWeatherIcon(dayIcons(), summaryLC);
if (forecast->period == QLatin1String("Tonight")) {
forecast->iconName = getWeatherIcon(nightIcons(), summaryLC);
} else {
forecast->iconName = getWeatherIcon(dayIcons(), summaryLC);
}
// db uses original strings normalized to lowercase, but we prefer the unnormalized if without translation
const QString summaryTranslated = i18nc("weather forecast", summaryLC.toUtf8().data());
forecast->summary = (summaryTranslated != summaryLC) ? summaryTranslated : summary;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment