application: Move night light monitor to GcalContext

This commit is contained in:
Georges Basile Stavracas Neto
2019-04-25 16:30:55 -03:00
parent 1b8a29e59b
commit 8366d22cf0
2 changed files with 6 additions and 6 deletions
+6
View File
@@ -21,6 +21,7 @@
#define G_LOG_DOMAIN "GcalContext"
#include "gcal-context.h"
#include "gcal-night-light-monitor.h"
struct _GcalContext
{
@@ -31,6 +32,8 @@ struct _GcalContext
GcalManager *manager;
GSettings *settings;
GcalWeatherService *weather_service;
GcalNightLightMonitor *night_light_monitor;
};
G_DEFINE_TYPE (GcalContext, gcal_context, G_TYPE_OBJECT)
@@ -61,6 +64,7 @@ gcal_context_finalize (GObject *object)
g_clear_object (&self->clock);
g_clear_object (&self->goa_client);
g_clear_object (&self->manager);
g_clear_object (&self->night_light_monitor);
g_clear_object (&self->weather_service);
G_OBJECT_CLASS (gcal_context_parent_class)->finalize (object);
@@ -169,6 +173,8 @@ gcal_context_init (GcalContext *self)
self->manager = gcal_manager_new ();
self->settings = g_settings_new ("org.gnome.calendar");
self->weather_service = gcal_weather_service_new ();
self->night_light_monitor = gcal_night_light_monitor_new (self);
}
/**