activity.c
changeset 41 cfb02882828d
parent 35 a77a8e7ab8ae
child 44 636ef7fe3d5b
equal deleted inserted replaced
40:574e404ab82f 41:cfb02882828d
   259 	NULL,
   259 	NULL,
   260 };
   260 };
   261 
   261 
   262 void activity_init (void)
   262 void activity_init (void)
   263 {
   263 {
       
   264 #ifdef MCABBER_API_HAVE_COMPL_FLAGS
       
   265 	activity_cid1 = compl_new_category (COMPL_FLAGS_SORT);
       
   266 	activity_cid2 = compl_new_category (COMPL_FLAGS_SORT);
       
   267 #else
   264 	activity_cid1 = compl_new_category ();
   268 	activity_cid1 = compl_new_category ();
       
   269 	activity_cid2 = compl_new_category ();
       
   270 #endif
       
   271 
   265 	if (activity_cid1) {
   272 	if (activity_cid1) {
   266 		const gchar **activity;
   273 		const gchar **activity;
   267 
   274 
   268 		for (activity = defined_general_activities; *activity; ++activity)
   275 		for (activity = defined_general_activities; *activity; ++activity)
   269 			compl_add_category_word (activity_cid1, *activity);
   276 			compl_add_category_word (activity_cid1, *activity);
   270 	}
   277 	}
   271 
   278 
   272 	activity_cid2 = compl_new_category ();
       
   273 	if (activity_cid2) {
   279 	if (activity_cid2) {
   274 		const gchar **activity;
   280 		const gchar **activity;
   275 
   281 
   276 		for (activity = defined_minor_activities; *activity; ++activity)
   282 		for (activity = defined_minor_activities; *activity; ++activity)
   277 			compl_add_category_word (activity_cid2, *activity);
   283 			compl_add_category_word (activity_cid2, *activity);