/soc/2013/ankitkv/gobjectification: ed2747e0598c: Refactored fin...
Ankit Vani
a at nevitus.org
Wed Jun 19 06:22:08 EDT 2013
Changeset: ed2747e0598cc0bb150e47b6eb3a3648b5dde4bc
Author: Ankit Vani <a at nevitus.org>
Date: 2013-06-19 15:47 +0530
Branch: soc.2013.gobjectification
URL: https://hg.pidgin.im/soc/2013/ankitkv/gobjectification/rev/ed2747e0598c
Description:
Refactored finch to use the GObject-based PurpleAccount API
diffstat:
finch/gntblist.c | 11 +++++------
1 files changed, 5 insertions(+), 6 deletions(-)
diffs (43 lines):
diff --git a/finch/gntblist.c b/finch/gntblist.c
--- a/finch/gntblist.c
+++ b/finch/gntblist.c
@@ -30,7 +30,6 @@
#include <blist.h>
#include <log.h>
#include <notify.h>
-#include <privacy.h>
#include <request.h>
#include <savedstatuses.h>
#include <server.h>
@@ -1267,8 +1266,8 @@ toggle_block_buddy(GntMenuItem *item, gp
PurpleAccount *account = purple_buddy_get_account(buddy);
const char *name = purple_buddy_get_name(buddy);
- block ? purple_privacy_deny(account, name, FALSE, FALSE) :
- purple_privacy_allow(account, name, FALSE, FALSE);
+ block ? purple_account_privacy_deny(account, name) :
+ purple_account_privacy_allow(account, name);
}
static void
@@ -1310,7 +1309,7 @@ create_buddy_menu(GntMenu *menu, PurpleB
}
account = purple_buddy_get_account(buddy);
- permitted = purple_privacy_check(account, purple_buddy_get_name(buddy));
+ permitted = purple_account_privacy_check(account, purple_buddy_get_name(buddy));
item = gnt_menuitem_check_new(_("Blocked"));
gnt_menuitem_check_set_checked(GNT_MENU_ITEM_CHECK(item), !permitted);
@@ -2673,9 +2672,9 @@ block_select_cb(gpointer data, PurpleReq
const char *name = purple_request_fields_get_string(fields, "screenname");
if (account && name && *name != '\0') {
if (purple_request_fields_get_choice(fields, "block") == 1) {
- purple_privacy_deny(account, name, FALSE, FALSE);
+ purple_account_privacy_deny(account, name);
} else {
- purple_privacy_allow(account, name, FALSE, FALSE);
+ purple_account_privacy_allow(account, name);
}
}
}
More information about the Commits
mailing list