From 4d77bab5a0f698943d1abf74482eecef7cc95f08 Mon Sep 17 00:00:00 2001 From: Lisandro Pérez Meyer Date: Thu, 16 Nov 2023 22:44:34 -0300 Subject: Bug fixes. Fixed Fan mode selection off state bug. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes ICS' internal AGL-48,49,50. Original from Sabin Sajeevan Bug-AGL: SPEC-4971 Change-Id: I66c875551a69a1b53eee2d6e1d3fa725b20ff41b Signed-off-by: Lisandro Pérez Meyer --- lib/presentation/screens/weather/hourly_forecast.dart | 18 +++++------------- lib/presentation/screens/weather/weather.dart | 4 +++- 2 files changed, 8 insertions(+), 14 deletions(-) (limited to 'lib/presentation/screens/weather') diff --git a/lib/presentation/screens/weather/hourly_forecast.dart b/lib/presentation/screens/weather/hourly_forecast.dart index aed8a6c..f6170ec 100644 --- a/lib/presentation/screens/weather/hourly_forecast.dart +++ b/lib/presentation/screens/weather/hourly_forecast.dart @@ -8,24 +8,16 @@ class HourlyForecast extends StatefulWidget { } class _HourlyForecastState extends State { - String selectedForescastTime = "13:00"; + String selectedForescastTime = "01:00 pm"; List foreCastList = [ ForecastModel( - time: "13:00", image: "assets/weatherStat.svg", weather: "29.1°"), + time: "01:00 pm", image: "assets/weatherStat.svg", weather: "29.1°"), ForecastModel( - time: "14:00", image: "assets/weatherStat.svg", weather: "28.1°"), + time: "02:00 pm", image: "assets/weatherStat.svg", weather: "28.1°"), ForecastModel( - time: "15:00", image: "assets/weatherStat.svg", weather: "27.1°"), + time: "03:00 pm", image: "assets/weatherStat.svg", weather: "27.1°"), ForecastModel( - time: "16:00", image: "assets/weatherStat.svg", weather: "29.1°"), - ForecastModel( - time: "13:00", image: "assets/weatherStat.svg", weather: "29.1°"), - ForecastModel( - time: "14:00", image: "assets/weatherStat.svg", weather: "28.1°"), - ForecastModel( - time: "15:00", image: "assets/weatherStat.svg", weather: "27.1°"), - ForecastModel( - time: "16:00", image: "assets/weatherStat.svg", weather: "29.1°"), + time: "04:00 pm", image: "assets/weatherStat.svg", weather: "29.1°"), ]; @override Widget build(BuildContext context) { diff --git a/lib/presentation/screens/weather/weather.dart b/lib/presentation/screens/weather/weather.dart index 7231700..d86bd13 100644 --- a/lib/presentation/screens/weather/weather.dart +++ b/lib/presentation/screens/weather/weather.dart @@ -7,6 +7,8 @@ class WeatherPage extends ConsumerWidget { @override Widget build(BuildContext context, WidgetRef ref) { double weatherIconSize = MediaQuery.sizeOf(context).width * 0.278; + final unit = + ref.watch(unitStateProvider.select((unit) => unit.temperatureUnit)); return Column( crossAxisAlignment: CrossAxisAlignment.stretch, children: [ @@ -58,7 +60,7 @@ class WeatherPage extends ConsumerWidget { height: 60, ), Text( - "28.3°C", + "28.3°${unit == TemperatureUnit.celsius ? "C" : "F"}", style: GoogleFonts.brunoAce( color: Colors.white, fontSize: 128), ), -- cgit 1.2.3-korg