libpurple/status.c

branch
soc.2013.gobjectification.plugins
changeset 36955
de491fc3f726
parent 36949
06cbd6ed97ed
parent 35066
f997e5384f79
child 36959
4806ff428ecd
--- a/libpurple/status.c	Sun Nov 17 16:05:54 2013 +0530
+++ b/libpurple/status.c	Sun Nov 17 20:23:45 2013 +0530
@@ -594,13 +594,13 @@
 			PURPLE_STATUS_GET_PRIVATE(old_status)->active = FALSE;
 			g_object_notify(G_OBJECT(old_status), "active");
 		}
-
-		g_object_set(presence, "active-status", status, NULL);
-		g_object_notify(G_OBJECT(status), "active");
 	}
 	else
 		old_status = NULL;
 
+	g_object_set(presence, "active-status", status, NULL);
+	g_object_notify(G_OBJECT(status), "active");
+
 	notify_status_update(presence, old_status, status);
 }
 
@@ -1229,19 +1229,21 @@
 	g_object_class_install_property(obj_class, PROP_STATUS_TYPE,
 			g_param_spec_pointer("status-type", "Status type",
 				"The PurpleStatusType of the status.",
-				G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY)
+				G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY |
+				G_PARAM_STATIC_STRINGS)
 			);
 
 	g_object_class_install_property(obj_class, PROP_PRESENCE,
 			g_param_spec_object("presence", "Presence",
 				"The presence that the status belongs to.", PURPLE_TYPE_PRESENCE,
-				G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY)
+				G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY |
+				G_PARAM_STATIC_STRINGS)
 			);
 
 	g_object_class_install_property(obj_class, PROP_ACTIVE,
 			g_param_spec_boolean("active", "Active",
 				"Whether the status is active or not.", FALSE,
-				G_PARAM_READWRITE)
+				G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)
 			);
 
 	g_type_class_add_private(klass, sizeof(PurpleStatusPrivate));

mercurial