mirror of
https://github.com/zoriya/noctalia-shell.git
synced 2025-12-06 06:36:15 +00:00
Weather: check for more weather states
This commit is contained in:
@@ -20,7 +20,7 @@ NBox {
|
||||
|
||||
// Weather condition detection
|
||||
readonly property int currentWeatherCode: weatherReady ? LocationService.data.weather.current_weather.weathercode : 0
|
||||
readonly property bool isRaining: testEffects === "rain" || (testEffects === "" && currentWeatherCode >= 51 && currentWeatherCode <= 67)
|
||||
readonly property bool isRaining: testEffects === "rain" || (testEffects === "" && ((currentWeatherCode >= 51 && currentWeatherCode <= 67) || (currentWeatherCode >= 80 && currentWeatherCode <= 82)))
|
||||
readonly property bool isSnowing: testEffects === "snow" || (testEffects === "" && ((currentWeatherCode >= 71 && currentWeatherCode <= 77) || (currentWeatherCode >= 85 && currentWeatherCode <= 86)))
|
||||
|
||||
visible: Settings.data.location.weatherEnabled
|
||||
|
||||
@@ -238,6 +238,8 @@ Singleton {
|
||||
return "weather-cloud-haze";
|
||||
if (code >= 51 && code <= 67)
|
||||
return "weather-cloud-rain";
|
||||
if (code >= 80 && code <= 82)
|
||||
return "weather-cloud-rain";
|
||||
if (code >= 71 && code <= 77)
|
||||
return "weather-cloud-snow";
|
||||
if (code >= 71 && code <= 77)
|
||||
|
||||
Reference in New Issue
Block a user