weather: introduce string g_settings.weather_postcode

Origin commit data
------------------
Commit: 46cf941937
Author: vanhofen <vanhofen@gmx.de>
Date: 2022-01-22 (Sat, 22 Jan 2022)

Origin message was:
------------------
- weather: introduce string g_settings.weather_postcode
This commit is contained in:
vanhofen
2022-01-22 00:47:10 +01:00
parent 0ef7810ebf
commit 5ecc7805bf
6 changed files with 9 additions and 10 deletions

View File

@@ -158,12 +158,11 @@ int CWeatherSetup::findLocation()
{
int ret = menu_return::RETURN_REPAINT;
int postcode = WEATHER_DEFAULT_POSTCODE;
CIntInput zipcode(LOCALE_WEATHER_LOCATION_POSTCODE, &postcode, (unsigned int)5);
CStringInput zipcode(LOCALE_WEATHER_LOCATION_POSTCODE, &g_settings.weather_postcode, 5);
ret = zipcode.exec(NULL, "");
zipcode.hide();
if (CWeather::getInstance()->FindCoords(postcode))
if (CWeather::getInstance()->FindCoords(g_settings.weather_postcode))
{
CWeather::getInstance()->setCoords(g_settings.weather_location, g_settings.weather_city);
}