# HG changeset patch # User Paul Aurich # Date 1271467678 0 # Node ID 933c8251e036d8f7c648b7376188fb4005fab820 # Parent 35a1cf247168bb7de56309b19639f87cad4654d0# Parent 4e5cfb6ad4711625160205a1a43c46553bfbf0c7 merge of '5bc899d1d49d1b8701e547f4e4d76519e471d339' and 'a778777f714204be832f9a284e141896f41bbdb7' diff -r 35a1cf247168 -r 933c8251e036 COPYRIGHT --- a/COPYRIGHT Sat Apr 17 01:27:04 2010 +0000 +++ b/COPYRIGHT Sat Apr 17 01:27:58 2010 +0000 @@ -530,6 +530,7 @@ Zac West Daniel Westermann-Clark Andrew Whewell +Stephen Whitmore Simon Wilkinson Dan Willemsen Justin Williams (Jaywalker) diff -r 35a1cf247168 -r 933c8251e036 ChangeLog.API --- a/ChangeLog.API Sat Apr 17 01:27:04 2010 +0000 +++ b/ChangeLog.API Sat Apr 17 01:27:58 2010 +0000 @@ -8,6 +8,8 @@ * account-signed-off * account-connection-error * purple_account_get_name_for_display + * purple_account_get_privacy_type + * purple_account_set_privacy_type * purple_buddy_get_media_caps * purple_buddy_set_media_caps * purple_contact_get_group diff -r 35a1cf247168 -r 933c8251e036 libpurple/account.c --- a/libpurple/account.c Sat Apr 17 01:27:04 2010 +0000 +++ b/libpurple/account.c Sat Apr 17 01:27:58 2010 +0000 @@ -1709,6 +1709,14 @@ } void +purple_account_set_privacy_type(PurpleAccount *account, PurplePrivacyType privacy_type) +{ + g_return_if_fail(account != NULL); + + account->perm_deny = privacy_type; +} + +void purple_account_set_status_types(PurpleAccount *account, GList *status_types) { g_return_if_fail(account != NULL); @@ -2105,6 +2113,14 @@ return account->proxy_info; } +PurplePrivacyType +purple_account_get_privacy_type(const PurpleAccount *account) +{ + g_return_val_if_fail(account != NULL, PURPLE_PRIVACY_ALLOW_ALL); + + return account->perm_deny; +} + PurpleStatus * purple_account_get_active_status(const PurpleAccount *account) { diff -r 35a1cf247168 -r 933c8251e036 libpurple/account.h --- a/libpurple/account.h Sat Apr 17 01:27:04 2010 +0000 +++ b/libpurple/account.h Sat Apr 17 01:27:58 2010 +0000 @@ -414,6 +414,14 @@ void purple_account_set_proxy_info(PurpleAccount *account, PurpleProxyInfo *info); /** + * Sets the account's privacy type. + * + * @param account The account. + * @param privacy_type The privacy type. + */ +void purple_account_set_privacy_type(PurpleAccount *account, PurplePrivacyType privacy_type); + +/** * Sets the account's status types. * * @param account The account. @@ -683,6 +691,15 @@ PurpleProxyInfo *purple_account_get_proxy_info(const PurpleAccount *account); /** + * Returns the account's privacy type. + * + * @param account The account. + * + * @return The privacy type. + */ +PurplePrivacyType purple_account_get_privacy_type(const PurpleAccount *account); + +/** * Returns the active status for this account. This looks through * the PurplePresence associated with this account and returns the * PurpleStatus that has its active flag set to "TRUE." There can be diff -r 35a1cf247168 -r 933c8251e036 libpurple/util.c --- a/libpurple/util.c Sat Apr 17 01:27:04 2010 +0000 +++ b/libpurple/util.c Sat Apr 17 01:27:58 2010 +0000 @@ -586,6 +586,7 @@ { purple_debug_error("util", "Format conversion failed in purple_utf8_strftime(): %s\n", err->message); g_error_free(err); + err = NULL; locale = g_strdup(format); }