weather-service: add hold/release style use counter to pause weather service

Holding and releasing the weather service makes sure it
is stopped whenever no UI depends on it.

Signed-off-by: Markus Göllnitz <camelcasenick@bewares.it>
This commit is contained in:
Markus Göllnitz
2024-01-27 16:09:02 +00:00
committed by Georges Basile Stavracas Neto
parent 9c879c999c
commit cf40734243
3 changed files with 61 additions and 1 deletions
+1
View File
@@ -202,6 +202,7 @@ manage_weather_service (GcalWeatherSettings *self)
}
gcal_weather_service_set_location (weather_service, location);
gcal_weather_service_hold (weather_service);
gcal_weather_service_activate (weather_service);
}
else