InfiniTime.git

commit e88d0afabfd9f4abec1db94a7b2cdcc022bc4067

Author: FintasticMan <finlay.neon.kid@gmail.com>

pinetimestyle: Display temp in Fahrenheit with setting

 src/displayapp/screens/WatchFacePineTimeStyle.cpp | 6 +++++-


diff --git a/src/displayapp/screens/WatchFacePineTimeStyle.cpp b/src/displayapp/screens/WatchFacePineTimeStyle.cpp
index caabbc111a89258e1c7b17bf1cfa120bbe50b53a..68e9bcfba7f774756b908351febbee7d9428d5af 100644
--- a/src/displayapp/screens/WatchFacePineTimeStyle.cpp
+++ b/src/displayapp/screens/WatchFacePineTimeStyle.cpp
@@ -543,7 +543,11 @@
   if (currentWeather.IsUpdated()) {
     auto optCurrentWeather = currentWeather.Get();
     if (optCurrentWeather) {
-      lv_label_set_text_fmt(temperature, "%d°", (optCurrentWeather->temperature) / 100);
+      int16_t temp = optCurrentWeather->temperature;
+      if (settingsController.GetWeatherFormat() == Controllers::Settings::WeatherFormat::Imperial) {
+        temp = Controllers::SimpleWeatherService::CelsiusToFahrenheit(temp);
+      }
+      lv_label_set_text_fmt(temperature, "%d°", temp / 100);
       lv_label_set_text(weatherIcon, Symbols::GetSymbol(optCurrentWeather->iconId));
       lv_obj_realign(temperature);
       lv_obj_realign(weatherIcon);