[Xfce4-commits] [apps/xfdashboard] 02/07: Create single-instance of XfdashboardApplicationTracker in application
noreply at xfce.org
noreply at xfce.org
Sun Jul 5 18:19:26 CEST 2015
This is an automated email from the git hooks/post-receive script.
nomad pushed a commit to branch master
in repository apps/xfdashboard.
commit 906d8707535074fb2d26af5d005c2da629bd9836
Author: Stephan Haller <nomad at froevel.de>
Date: Sun Jul 5 17:54:28 2015 +0200
Create single-instance of XfdashboardApplicationTracker in application
---
xfdashboard/application.c | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/xfdashboard/application.c b/xfdashboard/application.c
index 499d9dc..5005b33 100644
--- a/xfdashboard/application.c
+++ b/xfdashboard/application.c
@@ -46,6 +46,7 @@
#include "focus-manager.h"
#include "bindings-pool.h"
#include "application-database.h"
+#include "application-tracker.h"
/* Define this class in GObject system */
G_DEFINE_TYPE(XfdashboardApplication,
@@ -78,6 +79,7 @@ struct _XfdashboardApplicationPrivate
XfdashboardBindingsPool *bindings;
XfdashboardApplicationDatabase *appDatabase;
+ XfdashboardApplicationTracker *appTracker;
};
/* Properties */
@@ -327,6 +329,14 @@ static gboolean _xfdashboard_application_initialize_full(XfdashboardApplication
return(FALSE);
}
+ /* Set up application tracker */
+ priv->appTracker=xfdashboard_application_tracker_get_default();
+ if(!priv->appTracker)
+ {
+ g_critical(_("Could not initialize application tracker"));
+ return(FALSE);
+ }
+
/* Set up and load theme */
priv->xfconfThemeChangedSignalID=xfconf_g_property_bind(priv->xfconfChannel,
THEME_NAME_XFCONF_PROP,
@@ -636,6 +646,12 @@ static void _xfdashboard_application_dispose(GObject *inObject)
priv->appDatabase=NULL;
}
+ if(priv->appTracker)
+ {
+ g_object_unref(priv->appTracker);
+ priv->appTracker=NULL;
+ }
+
/* Shutdown xfconf */
priv->xfconfChannel=NULL;
xfconf_shutdown();
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list