From: Pekka R. <pri...@ik...> - 2004-05-05 08:39:55
|
: I tought to change all the char * to GaimBuddy * in add/rem buddy/buddies : and faceprint agreed. While doing so I found that only remove_buddies : required a group_name, which I tought it made no sense because in fact you : probably could delete a group of buddies from different groups at the same : time. Then I realized that remove_buddies is only called from rename_group, : but no protocol actually uses remove_buddies except oscar, in the case the : group alredy exists, because all the buddies should be moved to that : existing group. It is also used in serv_rename_group in the case the prpl : doesn't have the corresponding function. Since I wanted to get rid of all : those char *, I wanted to get rid of the group_name sent to remove_buddies, : which made sense since to me but I found something weird... : In addition of all this, then there's the proto_buddy_menu struct's callback (plus some other prpl callbacks) which delivers the char * to prpl instead of GaimBuddy. Which is really bad in case of SILC which does not have any kind of unique nicknames. If you have multiple same named (but maybe different alias) buddies in your buddy list and you right-mouse-click one of them, you cannot reliably know in prpl which buddy user actually clicked, since all we receive is the name. If we want the GaimBuddy in the prpl we cannot deduce the correct GaimBuddy just by its name (reliably). As a general convention I would suggest that anytime buddies are handled or delivered to prpl they are the GaimBuddy context instead of its name. Curently in SILC I just ignore this problem and hope that users don't add same named buddies, which is possible to do. Pekka ________________________________________________________________________ Pekka Riikonen priikone at silcnet.org Secure Internet Live Conferencing (SILC) http://silcnet.org/ |