#include <glib.h>
#include "account.h"
#include "buddyicon.h"
Include dependency graph for blist.h:
This graph shows which files directly or indirectly include this file:
Go to the source code of this file.
Data Structures | |
struct | _GaimBlistNode |
A Buddy list node. More... | |
struct | _GaimBlistUiOps |
Buddy list UI operations. More... | |
struct | _GaimBuddy |
A buddy. More... | |
struct | _GaimBuddyList |
The Buddy List. More... | |
struct | _GaimChat |
A chat. More... | |
struct | _GaimContact |
A contact. More... | |
struct | _GaimGroup |
A group. More... | |
Buddy List API | |
GaimBuddyList * | gaim_blist_new () |
Creates a new buddy list. | |
void | gaim_set_blist (GaimBuddyList *blist) |
Sets the main buddy list. | |
GaimBuddyList * | gaim_get_blist (void) |
Returns the main buddy list. | |
void | gaim_blist_show () |
Shows the buddy list, creating a new one if necessary. | |
void | gaim_blist_destroy () |
Destroys the buddy list window. | |
void | gaim_blist_set_visible (gboolean show) |
Hides or unhides the buddy list. | |
void | gaim_blist_update_buddy_status (GaimBuddy *buddy, int status) |
Updates a buddy's status. | |
void | gaim_blist_update_buddy_presence (GaimBuddy *buddy, int presence) |
Updates a buddy's presence. | |
void | gaim_blist_update_buddy_signon (GaimBuddy *buddy, time_t signon) |
Updates a buddy's signon time. | |
void | gaim_blist_update_buddy_idle (GaimBuddy *buddy, int idle) |
Updates a buddy's idle time. | |
void | gaim_blist_update_buddy_evil (GaimBuddy *buddy, int warning) |
Updates a buddy's warning level. | |
void | gaim_blist_update_buddy_icon (GaimBuddy *buddy) |
Updates a buddy's icon. | |
void | gaim_blist_rename_buddy (GaimBuddy *buddy, const char *name) |
Renames a buddy in the buddy list. | |
void | gaim_blist_alias_buddy (GaimBuddy *buddy, const char *alias) |
Aliases a buddy in the buddy list. | |
void | gaim_blist_server_alias_buddy (GaimBuddy *buddy, const char *alias) |
Sets the server-sent alias of a buddy in the buddy list. | |
void | gaim_blist_alias_chat (GaimChat *chat, const char *alias) |
Aliases a chat in the buddy list. | |
void | gaim_blist_rename_group (GaimGroup *group, const char *name) |
Renames a group. | |
GaimChat * | gaim_chat_new (GaimAccount *account, const char *alias, GHashTable *components) |
Creates a new chat for the buddy list. | |
char * | gaim_chat_get_display_name (GaimChat *chat) |
Gets the alias of the chat, or the chat name if the alias does not exist. | |
void | gaim_blist_add_chat (GaimChat *chat, GaimGroup *group, GaimBlistNode *node) |
Adds a new chat to the buddy list. | |
GaimBuddy * | gaim_buddy_new (GaimAccount *account, const char *screenname, const char *alias) |
Creates a new buddy. | |
void | gaim_buddy_set_icon (GaimBuddy *buddy, GaimBuddyIcon *icon) |
Sets a buddy's icon. | |
GaimBuddyIcon * | gaim_buddy_get_icon (const GaimBuddy *buddy) |
Returns a buddy's icon. | |
GaimContact * | gaim_buddy_get_contact (GaimBuddy *buddy) |
Returns a buddy's contact. | |
void | gaim_blist_add_buddy (GaimBuddy *buddy, GaimContact *contact, GaimGroup *group, GaimBlistNode *node) |
Adds a new buddy to the buddy list. | |
GaimGroup * | gaim_group_new (const char *name) |
Creates a new group. | |
void | gaim_blist_add_group (GaimGroup *group, GaimBlistNode *node) |
Adds a new group to the buddy list. | |
GaimContact * | gaim_contact_new () |
Creates a new contact. | |
void | gaim_blist_add_contact (GaimContact *contact, GaimGroup *group, GaimBlistNode *node) |
Adds a new contact to the buddy list. | |
void | gaim_blist_merge_contact (GaimContact *source, GaimBlistNode *node) |
Merges two contacts. | |
GaimBuddy * | gaim_contact_get_priority_buddy (GaimContact *contact) |
Returns the highest priority buddy for a given contact. | |
void | gaim_contact_set_alias (GaimContact *contact, const char *alias) |
Sets the alias for a contact. | |
const char * | gaim_contact_get_alias (GaimContact *contact) |
Gets the alias for a contact. | |
void | gaim_blist_remove_buddy (GaimBuddy *buddy) |
Removes a buddy from the buddy list and frees the memory allocated to it. | |
void | gaim_blist_remove_contact (GaimContact *contact) |
Removes a contact, and any buddies it contains, and frees the memory allocated to it. | |
void | gaim_blist_remove_chat (GaimChat *chat) |
Removes a chat from the buddy list and frees the memory allocated to it. | |
void | gaim_blist_remove_group (GaimGroup *group) |
Removes a group from the buddy list and frees the memory allocated to it and to its children. | |
const char * | gaim_get_buddy_alias_only (GaimBuddy *buddy) |
Returns the alias of a buddy. | |
const char * | gaim_get_buddy_alias (GaimBuddy *buddy) |
Returns the correct name to display for a buddy. | |
const char * | gaim_chat_get_name (GaimChat *chat) |
Returns the correct name to display for a blist chat. | |
GaimBuddy * | gaim_find_buddy (GaimAccount *account, const char *name) |
Finds the buddy struct given a screenname and an account. | |
GaimBuddy * | gaim_find_buddy_in_group (GaimAccount *account, const char *name, GaimGroup *group) |
Finds the buddy struct given a screenname, an account, and a group. | |
GSList * | gaim_find_buddies (GaimAccount *account, const char *name) |
Finds all buddies struct given a screenname and an account. | |
GaimGroup * | gaim_find_group (const char *name) |
Finds a group by name. | |
GaimChat * | gaim_blist_find_chat (GaimAccount *account, const char *name) |
Finds a chat by name. | |
GaimGroup * | gaim_chat_get_group (GaimChat *chat) |
Returns the group of which the chat is a member. | |
GaimGroup * | gaim_find_buddys_group (GaimBuddy *buddy) |
Returns the group of which the buddy is a member. | |
GSList * | gaim_group_get_accounts (GaimGroup *g) |
Returns a list of accounts that have buddies in this group. | |
gboolean | gaim_group_on_account (GaimGroup *g, GaimAccount *account) |
Determines whether an account owns any buddies in a given group. | |
void | gaim_blist_add_account (GaimAccount *account) |
Called when an account gets signed on. | |
void | gaim_blist_remove_account (GaimAccount *account) |
Called when an account gets signed off. | |
int | gaim_blist_get_group_size (GaimGroup *group, gboolean offline) |
Determines the total size of a group. | |
int | gaim_blist_get_group_online_count (GaimGroup *group) |
Determines the number of online buddies in a group. | |
Buddy list file management API | |
void | gaim_blist_save () |
Saves the buddy list to file. | |
void | gaim_blist_parse_toc_buddy_list (GaimAccount *account, char *config) |
Parses the toc-style buddy list used in older versions of Gaim and for SSI in toc.c. | |
void | gaim_blist_load () |
Loads the buddy list from ~/.gaim/blist.xml. | |
void | gaim_blist_request_add_buddy (GaimAccount *account, const char *username, const char *group, const char *alias) |
Requests from the user information needed to add a buddy to the buddy list. | |
void | gaim_blist_request_add_chat (GaimAccount *account, GaimGroup *group, const char *alias) |
Requests from the user information needed to add a chat to the buddy list. | |
void | gaim_blist_request_add_group (void) |
Requests from the user information needed to add a group to the buddy list. | |
void | gaim_blist_node_set_bool (GaimBlistNode *node, const char *key, gboolean value) |
Associates a boolean with a node in the buddy list. | |
gboolean | gaim_blist_node_get_bool (GaimBlistNode *node, const char *key) |
Retrieves a named boolean setting from a node in the buddy list. | |
void | gaim_blist_node_set_int (GaimBlistNode *node, const char *key, int value) |
Associates an integer with a node in the buddy list. | |
int | gaim_blist_node_get_int (GaimBlistNode *node, const char *key) |
Retrieves a named integer setting from a node in the buddy list. | |
void | gaim_blist_node_set_string (GaimBlistNode *node, const char *key, const char *value) |
Associates a string with a node in the buddy list. | |
const char * | gaim_blist_node_get_string (GaimBlistNode *node, const char *key) |
Retrieves a named string setting from a node in the buddy list. | |
void | gaim_blist_node_remove_setting (GaimBlistNode *node, const char *key) |
Removes a named setting from a blist node. | |
void | gaim_group_set_setting (GaimGroup *g, const char *key, const char *value) |
Associates some data with the group in the xml buddy list. | |
const char * | gaim_group_get_setting (GaimGroup *g, const char *key) |
Retrieves data from the XML buddy list set by gaim_group_set_setting()). | |
void | gaim_chat_set_setting (GaimChat *c, const char *key, const char *value) |
Associates some data with the chat in the xml buddy list. | |
const char * | gaim_chat_get_setting (GaimChat *c, const char *key) |
Retrieves data from the XML buddy list set by gaim_chat_set_setting()). | |
void | gaim_buddy_set_setting (GaimBuddy *b, const char *key, const char *value) |
Associates some data with the buddy in the xml buddy list. | |
const char * | gaim_buddy_get_setting (GaimBuddy *b, const char *key) |
Retrieves data from the XML buddy list set by gaim_buddy_set_setting()). | |
UI Registration Functions | |
void | gaim_blist_set_ui_ops (GaimBlistUiOps *ops) |
Sets the UI operations structure to be used for the buddy list. | |
GaimBlistUiOps * | gaim_blist_get_ui_ops (void) |
Returns the UI operations structure to be used for the buddy list. | |
Buddy List Subsystem | |
void * | gaim_blist_get_handle (void) |
Returns the handle for the buddy list subsystem. | |
void | gaim_blist_init (void) |
Initializes the buddy list subsystem. | |
void | gaim_blist_uninit (void) |
Uninitializes the buddy list subsystem. | |
Defines | |
#define | GAIM_BLIST_NODE_IS_CHAT(n) ((n)->type == GAIM_BLIST_CHAT_NODE) |
#define | GAIM_BLIST_NODE_IS_BUDDY(n) ((n)->type == GAIM_BLIST_BUDDY_NODE) |
#define | GAIM_BLIST_NODE_IS_CONTACT(n) ((n)->type == GAIM_BLIST_CONTACT_NODE) |
#define | GAIM_BLIST_NODE_IS_GROUP(n) ((n)->type == GAIM_BLIST_GROUP_NODE) |
#define | GAIM_BUDDY_IS_ONLINE(b) |
Typedefs | |
typedef _GaimBuddyList | GaimBuddyList |
typedef _GaimBlistUiOps | GaimBlistUiOps |
typedef _GaimBlistNode | GaimBlistNode |
typedef _GaimChat | GaimChat |
typedef _GaimGroup | GaimGroup |
typedef _GaimContact | GaimContact |
typedef _GaimBuddy | GaimBuddy |
Enumerations | |
enum | GaimBlistNodeType { GAIM_BLIST_GROUP_NODE, GAIM_BLIST_CONTACT_NODE, GAIM_BLIST_BUDDY_NODE, GAIM_BLIST_CHAT_NODE, GAIM_BLIST_OTHER_NODE } |
enum | GaimBuddyPresenceState { GAIM_BUDDY_SIGNING_OFF = -1, GAIM_BUDDY_OFFLINE = 0, GAIM_BUDDY_ONLINE, GAIM_BUDDY_SIGNING_ON } |
Functions | |
GList * | gaim_buddy_get_extended_menu (GaimBuddy *b) |
Retrieves the extended menu items for a buddy. |
gaim
Gaim is the legal property of its developers, whose names are too numerous to list here. Please refer to the COPYRIGHT file distributed with this source distribution.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
Value: ((b)->account->gc && \ ((b)->present == GAIM_BUDDY_ONLINE || \ (b)->present == GAIM_BUDDY_SIGNING_ON)) |
|
Called when an account gets signed on. Tells the UI to update all the buddies.
|
|
Adds a new buddy to the buddy list. The buddy will be inserted right after node or prepended to the group if node is NULL. If both are NULL, the buddy will be added to the "Buddies" group.
|
|
Adds a new chat to the buddy list. The chat will be inserted right after node or appended to the end of group if node is NULL. If both are NULL, the buddy will be added to the "Chats" group.
|
|
Adds a new contact to the buddy list. The new contact will be inserted after insert or prepended to the list if node is NULL.
|
|
Adds a new group to the buddy list. The new group will be inserted after insert or prepended to the list if node is NULL.
|
|
Aliases a buddy in the buddy list.
|
|
Aliases a chat in the buddy list.
|
|
Finds a chat by name.
|
|
Determines the number of online buddies in a group.
|
|
Determines the total size of a group.
|
|
Returns the handle for the buddy list subsystem.
|
|
Returns the UI operations structure to be used for the buddy list.
|
|
Merges two contacts. All of the buddies from source will be moved to target
|
|
Retrieves a named boolean setting from a node in the buddy list.
|
|
Retrieves a named integer setting from a node in the buddy list.
|
|
Retrieves a named string setting from a node in the buddy list.
|
|
Removes a named setting from a blist node.
|
|
Associates a boolean with a node in the buddy list.
|
|
Associates an integer with a node in the buddy list.
|
|
Associates a string with a node in the buddy list.
|
|
Parses the toc-style buddy list used in older versions of Gaim and for SSI in toc.c.
|
|
Called when an account gets signed off. Sets the presence of all the buddies to 0 and tells the UI to update them.
|
|
Removes a buddy from the buddy list and frees the memory allocated to it.
|
|
Removes a chat from the buddy list and frees the memory allocated to it.
|
|
Removes a contact, and any buddies it contains, and frees the memory allocated to it.
|
|
Removes a group from the buddy list and frees the memory allocated to it and to its children.
|
|
Renames a buddy in the buddy list.
|
|
Renames a group.
|
|
Requests from the user information needed to add a buddy to the buddy list.
|
|
Requests from the user information needed to add a chat to the buddy list.
|
|
Sets the server-sent alias of a buddy in the buddy list.
|
|
Sets the UI operations structure to be used for the buddy list.
|
|
Hides or unhides the buddy list.
|
|
Updates a buddy's warning level.
|
|
Updates a buddy's icon.
|
|
Updates a buddy's idle time.
|
|
Updates a buddy's presence.
|
|
Updates a buddy's signon time.
|
|
Updates a buddy's status. This needs to not take an int.
|
|
Returns a buddy's contact.
|
|
Retrieves the extended menu items for a buddy.
|
|
Returns a buddy's icon.
|
|
Retrieves data from the XML buddy list set by gaim_buddy_set_setting()).
|
|
Creates a new buddy.
|
|
Sets a buddy's icon. This should only be called from within Gaim. You probably want to call gaim_buddy_icon_set_data().
|
|
Associates some data with the buddy in the xml buddy list.
|
|
Gets the alias of the chat, or the chat name if the alias does not exist.
|
|
Returns the group of which the chat is a member.
|
|
Returns the correct name to display for a blist chat.
|
|
Retrieves data from the XML buddy list set by gaim_chat_set_setting()).
|
|
Creates a new chat for the buddy list.
|
|
Associates some data with the chat in the xml buddy list.
|
|
Gets the alias for a contact.
|
|
Returns the highest priority buddy for a given contact.
|
|
Creates a new contact.
|
|
Sets the alias for a contact.
|
|
Finds all buddies struct given a screenname and an account.
|
|
Finds the buddy struct given a screenname and an account.
|
|
Finds the buddy struct given a screenname, an account, and a group.
|
|
Returns the group of which the buddy is a member.
|
|
Finds a group by name.
|
|
Returns the main buddy list.
|
|
Returns the correct name to display for a buddy.
|
|
Returns the alias of a buddy.
|
|
Returns a list of accounts that have buddies in this group.
|
|
Retrieves data from the XML buddy list set by gaim_group_set_setting()).
|
|
Creates a new group. You can't have more than one group with the same name. Sorry. If you pass this the * name of a group that already exists, it will return that group.
|
|
Determines whether an account owns any buddies in a given group.
|
|
Associates some data with the group in the xml buddy list.
|
|
Sets the main buddy list.
|