Seems 0.5.6 was kept around, whoops. I wondered why that binary was a little heavy.
1.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/account.h Sun Jun 21 22:04:11 2009 -0400
1.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
1.3 @@ -1,1054 +0,0 @@
1.4 -/**
1.5 - * @file account.h Account API
1.6 - * @ingroup core
1.7 - * @see @ref account-signals
1.8 - */
1.9 -
1.10 -/* purple
1.11 - *
1.12 - * Purple is the legal property of its developers, whose names are too numerous
1.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
1.14 - * source distribution.
1.15 - *
1.16 - * This program is free software; you can redistribute it and/or modify
1.17 - * it under the terms of the GNU General Public License as published by
1.18 - * the Free Software Foundation; either version 2 of the License, or
1.19 - * (at your option) any later version.
1.20 - *
1.21 - * This program is distributed in the hope that it will be useful,
1.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
1.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1.24 - * GNU General Public License for more details.
1.25 - *
1.26 - * You should have received a copy of the GNU General Public License
1.27 - * along with this program; if not, write to the Free Software
1.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
1.29 - */
1.30 -#ifndef _PURPLE_ACCOUNT_H_
1.31 -#define _PURPLE_ACCOUNT_H_
1.32 -
1.33 -#include <glib.h>
1.34 -#include <glib-object.h>
1.35 -
1.36 -/** @copydoc _PurpleAccountUiOps */
1.37 -typedef struct _PurpleAccountUiOps PurpleAccountUiOps;
1.38 -/** @copydoc _PurpleAccount */
1.39 -typedef struct _PurpleAccount PurpleAccount;
1.40 -
1.41 -typedef gboolean (*PurpleFilterAccountFunc)(PurpleAccount *account);
1.42 -typedef void (*PurpleAccountRequestAuthorizationCb)(void *);
1.43 -typedef void (*PurpleAccountRegistrationCb)(PurpleAccount *account, gboolean succeeded, void *user_data);
1.44 -typedef void (*PurpleAccountUnregistrationCb)(PurpleAccount *account, gboolean succeeded, void *user_data);
1.45 -
1.46 -#include "connection.h"
1.47 -#include "log.h"
1.48 -#include "proxy.h"
1.49 -#include "prpl.h"
1.50 -#include "status.h"
1.51 -
1.52 -/**
1.53 - * Account request types.
1.54 - */
1.55 -typedef enum
1.56 -{
1.57 - PURPLE_ACCOUNT_REQUEST_AUTHORIZATION = 0 /* Account authorization request */
1.58 -} PurpleAccountRequestType;
1.59 -
1.60 -
1.61 -/** Account UI operations, used to notify the user of status changes and when
1.62 - * buddies add this account to their buddy lists.
1.63 - */
1.64 -struct _PurpleAccountUiOps
1.65 -{
1.66 - /** A buddy who is already on this account's buddy list added this account
1.67 - * to their buddy list.
1.68 - */
1.69 - void (*notify_added)(PurpleAccount *account,
1.70 - const char *remote_user,
1.71 - const char *id,
1.72 - const char *alias,
1.73 - const char *message);
1.74 -
1.75 - /** This account's status changed. */
1.76 - void (*status_changed)(PurpleAccount *account,
1.77 - PurpleStatus *status);
1.78 -
1.79 - /** Someone we don't have on our list added us; prompt to add them. */
1.80 - void (*request_add)(PurpleAccount *account,
1.81 - const char *remote_user,
1.82 - const char *id,
1.83 - const char *alias,
1.84 - const char *message);
1.85 -
1.86 - /** Prompt for authorization when someone adds this account to their buddy
1.87 - * list. To authorize them to see this account's presence, call \a
1.88 - * authorize_cb (\a user_data); otherwise call \a deny_cb (\a user_data);
1.89 - * @return a UI-specific handle, as passed to #close_account_request.
1.90 - */
1.91 - void *(*request_authorize)(PurpleAccount *account,
1.92 - const char *remote_user,
1.93 - const char *id,
1.94 - const char *alias,
1.95 - const char *message,
1.96 - gboolean on_list,
1.97 - PurpleAccountRequestAuthorizationCb authorize_cb,
1.98 - PurpleAccountRequestAuthorizationCb deny_cb,
1.99 - void *user_data);
1.100 -
1.101 - /** Close a pending request for authorization. \a ui_handle is a handle
1.102 - * as returned by #request_authorize.
1.103 - */
1.104 - void (*close_account_request)(void *ui_handle);
1.105 -
1.106 - void (*_purple_reserved1)(void);
1.107 - void (*_purple_reserved2)(void);
1.108 - void (*_purple_reserved3)(void);
1.109 - void (*_purple_reserved4)(void);
1.110 -};
1.111 -
1.112 -/** Structure representing an account.
1.113 - */
1.114 -struct _PurpleAccount
1.115 -{
1.116 - char *username; /**< The username. */
1.117 - char *alias; /**< How you appear to yourself. */
1.118 - char *password; /**< The account password. */
1.119 - char *user_info; /**< User information. */
1.120 -
1.121 - char *buddy_icon_path; /**< The buddy icon's non-cached path. */
1.122 -
1.123 - gboolean remember_pass; /**< Remember the password. */
1.124 -
1.125 - char *protocol_id; /**< The ID of the protocol. */
1.126 -
1.127 - PurpleConnection *gc; /**< The connection handle. */
1.128 - gboolean disconnecting; /**< The account is currently disconnecting */
1.129 -
1.130 - GHashTable *settings; /**< Protocol-specific settings. */
1.131 - GHashTable *ui_settings; /**< UI-specific settings. */
1.132 -
1.133 - PurpleProxyInfo *proxy_info; /**< Proxy information. This will be set */
1.134 - /* to NULL when the account inherits */
1.135 - /* proxy settings from global prefs. */
1.136 -
1.137 - /*
1.138 - * TODO: Supplementing the next two linked lists with hash tables
1.139 - * should help performance a lot when these lists are long. This
1.140 - * matters quite a bit for protocols like MSN, where all your
1.141 - * buddies are added to your permit list. Currently we have to
1.142 - * iterate through the entire list if we want to check if someone
1.143 - * is permitted or denied. We should do this for 3.0.0.
1.144 - */
1.145 - GSList *permit; /**< Permit list. */
1.146 - GSList *deny; /**< Deny list. */
1.147 - int perm_deny; /**< The permit/deny setting. */
1.148 -
1.149 - GList *status_types; /**< Status types. */
1.150 -
1.151 - PurplePresence *presence; /**< Presence. */
1.152 - PurpleLog *system_log; /**< The system log */
1.153 -
1.154 - void *ui_data; /**< The UI can put data here. */
1.155 - PurpleAccountRegistrationCb registration_cb;
1.156 - void *registration_cb_user_data;
1.157 -
1.158 - gpointer priv; /**< Pointer to opaque private data. */
1.159 -};
1.160 -
1.161 -#ifdef __cplusplus
1.162 -extern "C" {
1.163 -#endif
1.164 -
1.165 -/**************************************************************************/
1.166 -/** @name Account API */
1.167 -/**************************************************************************/
1.168 -/*@{*/
1.169 -
1.170 -/**
1.171 - * Creates a new account.
1.172 - *
1.173 - * @param username The username.
1.174 - * @param protocol_id The protocol ID.
1.175 - *
1.176 - * @return The new account.
1.177 - */
1.178 -PurpleAccount *purple_account_new(const char *username, const char *protocol_id);
1.179 -
1.180 -/**
1.181 - * Destroys an account.
1.182 - *
1.183 - * @param account The account to destroy.
1.184 - */
1.185 -void purple_account_destroy(PurpleAccount *account);
1.186 -
1.187 -/**
1.188 - * Connects to an account.
1.189 - *
1.190 - * @param account The account to connect to.
1.191 - */
1.192 -void purple_account_connect(PurpleAccount *account);
1.193 -
1.194 -/**
1.195 - * Sets the callback for successful registration.
1.196 - *
1.197 - * @param account The account for which this callback should be used
1.198 - * @param cb The callback
1.199 - * @param user_data The user data passed to the callback
1.200 - */
1.201 -void purple_account_set_register_callback(PurpleAccount *account, PurpleAccountRegistrationCb cb, void *user_data);
1.202 -
1.203 -/**
1.204 - * Registers an account.
1.205 - *
1.206 - * @param account The account to register.
1.207 - */
1.208 -void purple_account_register(PurpleAccount *account);
1.209 -
1.210 -/**
1.211 - * Unregisters an account (deleting it from the server).
1.212 - *
1.213 - * @param account The account to unregister.
1.214 - * @param cb Optional callback to be called when unregistration is complete
1.215 - * @param user_data user data to pass to the callback
1.216 - */
1.217 -void purple_account_unregister(PurpleAccount *account, PurpleAccountUnregistrationCb cb, void *user_data);
1.218 -
1.219 -/**
1.220 - * Disconnects from an account.
1.221 - *
1.222 - * @param account The account to disconnect from.
1.223 - */
1.224 -void purple_account_disconnect(PurpleAccount *account);
1.225 -
1.226 -/**
1.227 - * Notifies the user that the account was added to a remote user's
1.228 - * buddy list.
1.229 - *
1.230 - * This will present a dialog informing the user that he was added to the
1.231 - * remote user's buddy list.
1.232 - *
1.233 - * @param account The account that was added.
1.234 - * @param remote_user The name of the user that added this account.
1.235 - * @param id The optional ID of the local account. Rarely used.
1.236 - * @param alias The optional alias of the user.
1.237 - * @param message The optional message sent from the user adding you.
1.238 - */
1.239 -void purple_account_notify_added(PurpleAccount *account, const char *remote_user,
1.240 - const char *id, const char *alias,
1.241 - const char *message);
1.242 -
1.243 -/**
1.244 - * Notifies the user that the account was addded to a remote user's buddy
1.245 - * list and asks ther user if they want to add the remote user to their buddy
1.246 - * list.
1.247 - *
1.248 - * This will present a dialog informing the local user that the remote user
1.249 - * added them to the remote user's buddy list and will ask if they want to add
1.250 - * the remote user to the buddy list.
1.251 - *
1.252 - * @param account The account that was added.
1.253 - * @param remote_user The name of the user that added this account.
1.254 - * @param id The optional ID of the local account. Rarely used.
1.255 - * @param alias The optional alias of the user.
1.256 - * @param message The optional message sent from the user adding you.
1.257 - */
1.258 -void purple_account_request_add(PurpleAccount *account, const char *remote_user,
1.259 - const char *id, const char *alias,
1.260 - const char *message);
1.261 -
1.262 -/**
1.263 - * Notifies the user that a remote user has wants to add the local user
1.264 - * to his or her buddy list and requires authorization to do so.
1.265 - *
1.266 - * This will present a dialog informing the user of this and ask if the
1.267 - * user authorizes or denies the remote user from adding him.
1.268 - *
1.269 - * @param account The account that was added
1.270 - * @param remote_user The name of the user that added this account.
1.271 - * @param id The optional ID of the local account. Rarely used.
1.272 - * @param alias The optional alias of the remote user.
1.273 - * @param message The optional message sent by the user wanting to add you.
1.274 - * @param on_list Is the remote user already on the buddy list?
1.275 - * @param auth_cb The callback called when the local user accepts
1.276 - * @param deny_cb The callback called when the local user rejects
1.277 - * @param user_data Data to be passed back to the above callbacks
1.278 - *
1.279 - * @return A UI-specific handle.
1.280 - */
1.281 -void *purple_account_request_authorization(PurpleAccount *account, const char *remote_user,
1.282 - const char *id, const char *alias, const char *message, gboolean on_list,
1.283 - PurpleAccountRequestAuthorizationCb auth_cb, PurpleAccountRequestAuthorizationCb deny_cb, void *user_data);
1.284 -
1.285 -/**
1.286 - * Close account requests registered for the given PurpleAccount
1.287 - *
1.288 - * @param account The account for which requests should be closed
1.289 - */
1.290 -void purple_account_request_close_with_account(PurpleAccount *account);
1.291 -
1.292 -/**
1.293 - * Close the account request for the given ui handle
1.294 - *
1.295 - * @param ui_handle The ui specific handle for which requests should be closed
1.296 - */
1.297 -void purple_account_request_close(void *ui_handle);
1.298 -
1.299 -/**
1.300 - * Requests a password from the user for the account. Does not set the
1.301 - * account password on success; do that in ok_cb if desired.
1.302 - *
1.303 - * @param account The account to request the password for.
1.304 - * @param ok_cb The callback for the OK button.
1.305 - * @param cancel_cb The callback for the cancel button.
1.306 - * @param user_data User data to be passed into callbacks.
1.307 - */
1.308 -void purple_account_request_password(PurpleAccount *account, GCallback ok_cb,
1.309 - GCallback cancel_cb, void *user_data);
1.310 -
1.311 -/**
1.312 - * Requests information from the user to change the account's password.
1.313 - *
1.314 - * @param account The account to change the password on.
1.315 - */
1.316 -void purple_account_request_change_password(PurpleAccount *account);
1.317 -
1.318 -/**
1.319 - * Requests information from the user to change the account's
1.320 - * user information.
1.321 - *
1.322 - * @param account The account to change the user information on.
1.323 - */
1.324 -void purple_account_request_change_user_info(PurpleAccount *account);
1.325 -
1.326 -/**
1.327 - * Sets the account's username.
1.328 - *
1.329 - * @param account The account.
1.330 - * @param username The username.
1.331 - */
1.332 -void purple_account_set_username(PurpleAccount *account, const char *username);
1.333 -
1.334 -/**
1.335 - * Sets the account's password.
1.336 - *
1.337 - * @param account The account.
1.338 - * @param password The password.
1.339 - */
1.340 -void purple_account_set_password(PurpleAccount *account, const char *password);
1.341 -
1.342 -/**
1.343 - * Sets the account's alias.
1.344 - *
1.345 - * @param account The account.
1.346 - * @param alias The alias.
1.347 - */
1.348 -void purple_account_set_alias(PurpleAccount *account, const char *alias);
1.349 -
1.350 -/**
1.351 - * Sets the account's user information
1.352 - *
1.353 - * @param account The account.
1.354 - * @param user_info The user information.
1.355 - */
1.356 -void purple_account_set_user_info(PurpleAccount *account, const char *user_info);
1.357 -
1.358 -/**
1.359 - * Sets the account's buddy icon path.
1.360 - *
1.361 - * @param account The account.
1.362 - * @param path The buddy icon non-cached path.
1.363 - */
1.364 -void purple_account_set_buddy_icon_path(PurpleAccount *account, const char *path);
1.365 -
1.366 -/**
1.367 - * Sets the account's protocol ID.
1.368 - *
1.369 - * @param account The account.
1.370 - * @param protocol_id The protocol ID.
1.371 - */
1.372 -void purple_account_set_protocol_id(PurpleAccount *account,
1.373 - const char *protocol_id);
1.374 -
1.375 -/**
1.376 - * Sets the account's connection.
1.377 - *
1.378 - * @param account The account.
1.379 - * @param gc The connection.
1.380 - */
1.381 -void purple_account_set_connection(PurpleAccount *account, PurpleConnection *gc);
1.382 -
1.383 -/**
1.384 - * Sets whether or not this account should save its password.
1.385 - *
1.386 - * @param account The account.
1.387 - * @param value @c TRUE if it should remember the password.
1.388 - */
1.389 -void purple_account_set_remember_password(PurpleAccount *account, gboolean value);
1.390 -
1.391 -/**
1.392 - * Sets whether or not this account should check for mail.
1.393 - *
1.394 - * @param account The account.
1.395 - * @param value @c TRUE if it should check for mail.
1.396 - */
1.397 -void purple_account_set_check_mail(PurpleAccount *account, gboolean value);
1.398 -
1.399 -/**
1.400 - * Sets whether or not this account is enabled for the specified
1.401 - * UI.
1.402 - *
1.403 - * @param account The account.
1.404 - * @param ui The UI.
1.405 - * @param value @c TRUE if it is enabled.
1.406 - */
1.407 -void purple_account_set_enabled(PurpleAccount *account, const char *ui,
1.408 - gboolean value);
1.409 -
1.410 -/**
1.411 - * Sets the account's proxy information.
1.412 - *
1.413 - * @param account The account.
1.414 - * @param info The proxy information.
1.415 - */
1.416 -void purple_account_set_proxy_info(PurpleAccount *account, PurpleProxyInfo *info);
1.417 -
1.418 -/**
1.419 - * Sets the account's status types.
1.420 - *
1.421 - * @param account The account.
1.422 - * @param status_types The list of status types.
1.423 - */
1.424 -void purple_account_set_status_types(PurpleAccount *account, GList *status_types);
1.425 -
1.426 -/**
1.427 - * Variadic version of purple_account_set_status_list(); the variadic list
1.428 - * replaces @a attrs, and should be <tt>NULL</tt>-terminated.
1.429 - *
1.430 - * @copydoc purple_account_set_status_list()
1.431 - */
1.432 -void purple_account_set_status(PurpleAccount *account, const char *status_id,
1.433 - gboolean active, ...) G_GNUC_NULL_TERMINATED;
1.434 -
1.435 -
1.436 -/**
1.437 - * Activates or deactivates a status. All changes to the statuses of
1.438 - * an account go through this function or purple_account_set_status().
1.439 - *
1.440 - * You can only deactivate an exclusive status by activating another exclusive
1.441 - * status. So, if @a status_id is an exclusive status and @a active is @c
1.442 - * FALSE, this function does nothing.
1.443 - *
1.444 - * @param account The account.
1.445 - * @param status_id The ID of the status.
1.446 - * @param active Whether @a status_id is to be activated (<tt>TRUE</tt>) or
1.447 - * deactivated (<tt>FALSE</tt>).
1.448 - * @param attrs A list of <tt>const char *</tt> attribute names followed by
1.449 - * <tt>const char *</tt> attribute values for the status.
1.450 - * (For example, one pair might be <tt>"message"</tt> followed
1.451 - * by <tt>"hello, talk to me!"</tt>.)
1.452 - */
1.453 -void purple_account_set_status_list(PurpleAccount *account,
1.454 - const char *status_id, gboolean active, GList *attrs);
1.455 -
1.456 -/**
1.457 - * Clears all protocol-specific settings on an account.
1.458 - *
1.459 - * @param account The account.
1.460 - */
1.461 -void purple_account_clear_settings(PurpleAccount *account);
1.462 -
1.463 -/**
1.464 - * Sets a protocol-specific integer setting for an account.
1.465 - *
1.466 - * @param account The account.
1.467 - * @param name The name of the setting.
1.468 - * @param value The setting's value.
1.469 - */
1.470 -void purple_account_set_int(PurpleAccount *account, const char *name, int value);
1.471 -
1.472 -/**
1.473 - * Sets a protocol-specific string setting for an account.
1.474 - *
1.475 - * @param account The account.
1.476 - * @param name The name of the setting.
1.477 - * @param value The setting's value.
1.478 - */
1.479 -void purple_account_set_string(PurpleAccount *account, const char *name,
1.480 - const char *value);
1.481 -
1.482 -/**
1.483 - * Sets a protocol-specific boolean setting for an account.
1.484 - *
1.485 - * @param account The account.
1.486 - * @param name The name of the setting.
1.487 - * @param value The setting's value.
1.488 - */
1.489 -void purple_account_set_bool(PurpleAccount *account, const char *name,
1.490 - gboolean value);
1.491 -
1.492 -/**
1.493 - * Sets a UI-specific integer setting for an account.
1.494 - *
1.495 - * @param account The account.
1.496 - * @param ui The UI name.
1.497 - * @param name The name of the setting.
1.498 - * @param value The setting's value.
1.499 - */
1.500 -void purple_account_set_ui_int(PurpleAccount *account, const char *ui,
1.501 - const char *name, int value);
1.502 -
1.503 -/**
1.504 - * Sets a UI-specific string setting for an account.
1.505 - *
1.506 - * @param account The account.
1.507 - * @param ui The UI name.
1.508 - * @param name The name of the setting.
1.509 - * @param value The setting's value.
1.510 - */
1.511 -void purple_account_set_ui_string(PurpleAccount *account, const char *ui,
1.512 - const char *name, const char *value);
1.513 -
1.514 -/**
1.515 - * Sets a UI-specific boolean setting for an account.
1.516 - *
1.517 - * @param account The account.
1.518 - * @param ui The UI name.
1.519 - * @param name The name of the setting.
1.520 - * @param value The setting's value.
1.521 - */
1.522 -void purple_account_set_ui_bool(PurpleAccount *account, const char *ui,
1.523 - const char *name, gboolean value);
1.524 -
1.525 -/**
1.526 - * Returns whether or not the account is connected.
1.527 - *
1.528 - * @param account The account.
1.529 - *
1.530 - * @return @c TRUE if connected, or @c FALSE otherwise.
1.531 - */
1.532 -gboolean purple_account_is_connected(const PurpleAccount *account);
1.533 -
1.534 -/**
1.535 - * Returns whether or not the account is connecting.
1.536 - *
1.537 - * @param account The account.
1.538 - *
1.539 - * @return @c TRUE if connecting, or @c FALSE otherwise.
1.540 - */
1.541 -gboolean purple_account_is_connecting(const PurpleAccount *account);
1.542 -
1.543 -/**
1.544 - * Returns whether or not the account is disconnected.
1.545 - *
1.546 - * @param account The account.
1.547 - *
1.548 - * @return @c TRUE if disconnected, or @c FALSE otherwise.
1.549 - */
1.550 -gboolean purple_account_is_disconnected(const PurpleAccount *account);
1.551 -
1.552 -/**
1.553 - * Returns the account's username.
1.554 - *
1.555 - * @param account The account.
1.556 - *
1.557 - * @return The username.
1.558 - */
1.559 -const char *purple_account_get_username(const PurpleAccount *account);
1.560 -
1.561 -/**
1.562 - * Returns the account's password.
1.563 - *
1.564 - * @param account The account.
1.565 - *
1.566 - * @return The password.
1.567 - */
1.568 -const char *purple_account_get_password(const PurpleAccount *account);
1.569 -
1.570 -/**
1.571 - * Returns the account's alias.
1.572 - *
1.573 - * @param account The account.
1.574 - *
1.575 - * @return The alias.
1.576 - */
1.577 -const char *purple_account_get_alias(const PurpleAccount *account);
1.578 -
1.579 -/**
1.580 - * Returns the account's user information.
1.581 - *
1.582 - * @param account The account.
1.583 - *
1.584 - * @return The user information.
1.585 - */
1.586 -const char *purple_account_get_user_info(const PurpleAccount *account);
1.587 -
1.588 -/**
1.589 - * Gets the account's buddy icon path.
1.590 - *
1.591 - * @param account The account.
1.592 - *
1.593 - * @return The buddy icon's non-cached path.
1.594 - */
1.595 -const char *purple_account_get_buddy_icon_path(const PurpleAccount *account);
1.596 -
1.597 -/**
1.598 - * Returns the account's protocol ID.
1.599 - *
1.600 - * @param account The account.
1.601 - *
1.602 - * @return The protocol ID.
1.603 - */
1.604 -const char *purple_account_get_protocol_id(const PurpleAccount *account);
1.605 -
1.606 -/**
1.607 - * Returns the account's protocol name.
1.608 - *
1.609 - * @param account The account.
1.610 - *
1.611 - * @return The protocol name.
1.612 - */
1.613 -const char *purple_account_get_protocol_name(const PurpleAccount *account);
1.614 -
1.615 -/**
1.616 - * Returns the account's connection.
1.617 - *
1.618 - * @param account The account.
1.619 - *
1.620 - * @return The connection.
1.621 - */
1.622 -PurpleConnection *purple_account_get_connection(const PurpleAccount *account);
1.623 -
1.624 -/**
1.625 - * Returns whether or not this account should save its password.
1.626 - *
1.627 - * @param account The account.
1.628 - *
1.629 - * @return @c TRUE if it should remember the password.
1.630 - */
1.631 -gboolean purple_account_get_remember_password(const PurpleAccount *account);
1.632 -
1.633 -/**
1.634 - * Returns whether or not this account should check for mail.
1.635 - *
1.636 - * @param account The account.
1.637 - *
1.638 - * @return @c TRUE if it should check for mail.
1.639 - */
1.640 -gboolean purple_account_get_check_mail(const PurpleAccount *account);
1.641 -
1.642 -/**
1.643 - * Returns whether or not this account is enabled for the
1.644 - * specified UI.
1.645 - *
1.646 - * @param account The account.
1.647 - * @param ui The UI.
1.648 - *
1.649 - * @return @c TRUE if it enabled on this UI.
1.650 - */
1.651 -gboolean purple_account_get_enabled(const PurpleAccount *account,
1.652 - const char *ui);
1.653 -
1.654 -/**
1.655 - * Returns the account's proxy information.
1.656 - *
1.657 - * @param account The account.
1.658 - *
1.659 - * @return The proxy information.
1.660 - */
1.661 -PurpleProxyInfo *purple_account_get_proxy_info(const PurpleAccount *account);
1.662 -
1.663 -/**
1.664 - * Returns the active status for this account. This looks through
1.665 - * the PurplePresence associated with this account and returns the
1.666 - * PurpleStatus that has its active flag set to "TRUE." There can be
1.667 - * only one active PurpleStatus in a PurplePresence.
1.668 - *
1.669 - * @param account The account.
1.670 - *
1.671 - * @return The active status.
1.672 - */
1.673 -PurpleStatus *purple_account_get_active_status(const PurpleAccount *account);
1.674 -
1.675 -/**
1.676 - * Returns the account status with the specified ID.
1.677 - *
1.678 - * Note that this works differently than purple_buddy_get_status() in that
1.679 - * it will only return NULL if the status was not registered.
1.680 - *
1.681 - * @param account The account.
1.682 - * @param status_id The status ID.
1.683 - *
1.684 - * @return The status, or NULL if it was never registered.
1.685 - */
1.686 -PurpleStatus *purple_account_get_status(const PurpleAccount *account,
1.687 - const char *status_id);
1.688 -
1.689 -/**
1.690 - * Returns the account status type with the specified ID.
1.691 - *
1.692 - * @param account The account.
1.693 - * @param id The ID of the status type to find.
1.694 - *
1.695 - * @return The status type if found, or NULL.
1.696 - */
1.697 -PurpleStatusType *purple_account_get_status_type(const PurpleAccount *account,
1.698 - const char *id);
1.699 -
1.700 -/**
1.701 - * Returns the account status type with the specified primitive.
1.702 - * Note: It is possible for an account to have more than one
1.703 - * PurpleStatusType with the same primitive. In this case, the
1.704 - * first PurpleStatusType is returned.
1.705 - *
1.706 - * @param account The account.
1.707 - * @param primitive The type of the status type to find.
1.708 - *
1.709 - * @return The status if found, or NULL.
1.710 - */
1.711 -PurpleStatusType *purple_account_get_status_type_with_primitive(
1.712 - const PurpleAccount *account,
1.713 - PurpleStatusPrimitive primitive);
1.714 -
1.715 -/**
1.716 - * Returns the account's presence.
1.717 - *
1.718 - * @param account The account.
1.719 - *
1.720 - * @return The account's presence.
1.721 - */
1.722 -PurplePresence *purple_account_get_presence(const PurpleAccount *account);
1.723 -
1.724 -/**
1.725 - * Returns whether or not an account status is active.
1.726 - *
1.727 - * @param account The account.
1.728 - * @param status_id The status ID.
1.729 - *
1.730 - * @return TRUE if active, or FALSE if not.
1.731 - */
1.732 -gboolean purple_account_is_status_active(const PurpleAccount *account,
1.733 - const char *status_id);
1.734 -
1.735 -/**
1.736 - * Returns the account's status types.
1.737 - *
1.738 - * @param account The account.
1.739 - *
1.740 - * @constreturn The account's status types.
1.741 - */
1.742 -GList *purple_account_get_status_types(const PurpleAccount *account);
1.743 -
1.744 -/**
1.745 - * Returns a protocol-specific integer setting for an account.
1.746 - *
1.747 - * @param account The account.
1.748 - * @param name The name of the setting.
1.749 - * @param default_value The default value.
1.750 - *
1.751 - * @return The value.
1.752 - */
1.753 -int purple_account_get_int(const PurpleAccount *account, const char *name,
1.754 - int default_value);
1.755 -
1.756 -/**
1.757 - * Returns a protocol-specific string setting for an account.
1.758 - *
1.759 - * @param account The account.
1.760 - * @param name The name of the setting.
1.761 - * @param default_value The default value.
1.762 - *
1.763 - * @return The value.
1.764 - */
1.765 -const char *purple_account_get_string(const PurpleAccount *account,
1.766 - const char *name,
1.767 - const char *default_value);
1.768 -
1.769 -/**
1.770 - * Returns a protocol-specific boolean setting for an account.
1.771 - *
1.772 - * @param account The account.
1.773 - * @param name The name of the setting.
1.774 - * @param default_value The default value.
1.775 - *
1.776 - * @return The value.
1.777 - */
1.778 -gboolean purple_account_get_bool(const PurpleAccount *account, const char *name,
1.779 - gboolean default_value);
1.780 -
1.781 -/**
1.782 - * Returns a UI-specific integer setting for an account.
1.783 - *
1.784 - * @param account The account.
1.785 - * @param ui The UI name.
1.786 - * @param name The name of the setting.
1.787 - * @param default_value The default value.
1.788 - *
1.789 - * @return The value.
1.790 - */
1.791 -int purple_account_get_ui_int(const PurpleAccount *account, const char *ui,
1.792 - const char *name, int default_value);
1.793 -
1.794 -/**
1.795 - * Returns a UI-specific string setting for an account.
1.796 - *
1.797 - * @param account The account.
1.798 - * @param ui The UI name.
1.799 - * @param name The name of the setting.
1.800 - * @param default_value The default value.
1.801 - *
1.802 - * @return The value.
1.803 - */
1.804 -const char *purple_account_get_ui_string(const PurpleAccount *account,
1.805 - const char *ui, const char *name,
1.806 - const char *default_value);
1.807 -
1.808 -/**
1.809 - * Returns a UI-specific boolean setting for an account.
1.810 - *
1.811 - * @param account The account.
1.812 - * @param ui The UI name.
1.813 - * @param name The name of the setting.
1.814 - * @param default_value The default value.
1.815 - *
1.816 - * @return The value.
1.817 - */
1.818 -gboolean purple_account_get_ui_bool(const PurpleAccount *account, const char *ui,
1.819 - const char *name, gboolean default_value);
1.820 -
1.821 -
1.822 -/**
1.823 - * Returns the system log for an account.
1.824 - *
1.825 - * @param account The account.
1.826 - * @param create Should it be created if it doesn't exist?
1.827 - *
1.828 - * @return The log.
1.829 - *
1.830 - * @note Callers should almost always pass @c FALSE for @a create.
1.831 - * Passing @c TRUE could result in an existing log being reopened,
1.832 - * if the log has already been closed, which not all loggers deal
1.833 - * with appropriately.
1.834 - */
1.835 -PurpleLog *purple_account_get_log(PurpleAccount *account, gboolean create);
1.836 -
1.837 -/**
1.838 - * Frees the system log of an account
1.839 - *
1.840 - * @param account The account.
1.841 - */
1.842 -void purple_account_destroy_log(PurpleAccount *account);
1.843 -
1.844 -/**
1.845 - * Adds a buddy to the server-side buddy list for the specified account.
1.846 - *
1.847 - * @param account The account.
1.848 - * @param buddy The buddy to add.
1.849 - */
1.850 -void purple_account_add_buddy(PurpleAccount *account, PurpleBuddy *buddy);
1.851 -/**
1.852 - * Adds a list of buddies to the server-side buddy list.
1.853 - *
1.854 - * @param account The account.
1.855 - * @param buddies The list of PurpleBlistNodes representing the buddies to add.
1.856 - */
1.857 -void purple_account_add_buddies(PurpleAccount *account, GList *buddies);
1.858 -
1.859 -/**
1.860 - * Removes a buddy from the server-side buddy list.
1.861 - *
1.862 - * @param account The account.
1.863 - * @param buddy The buddy to remove.
1.864 - * @param group The group to remove the buddy from.
1.865 - */
1.866 -void purple_account_remove_buddy(PurpleAccount *account, PurpleBuddy *buddy,
1.867 - PurpleGroup *group);
1.868 -
1.869 -/**
1.870 - * Removes a list of buddies from the server-side buddy list.
1.871 - *
1.872 - * @note The lists buddies and groups are parallel lists. Be sure that node n of
1.873 - * groups matches node n of buddies.
1.874 - *
1.875 - * @param account The account.
1.876 - * @param buddies The list of buddies to remove.
1.877 - * @param groups The list of groups to remove buddies from. Each node of this
1.878 - * list should match the corresponding node of buddies.
1.879 - */
1.880 -void purple_account_remove_buddies(PurpleAccount *account, GList *buddies,
1.881 - GList *groups);
1.882 -
1.883 -/**
1.884 - * Removes a group from the server-side buddy list.
1.885 - *
1.886 - * @param account The account.
1.887 - * @param group The group to remove.
1.888 - */
1.889 -void purple_account_remove_group(PurpleAccount *account, PurpleGroup *group);
1.890 -
1.891 -/**
1.892 - * Changes the password on the specified account.
1.893 - *
1.894 - * @param account The account.
1.895 - * @param orig_pw The old password.
1.896 - * @param new_pw The new password.
1.897 - */
1.898 -void purple_account_change_password(PurpleAccount *account, const char *orig_pw,
1.899 - const char *new_pw);
1.900 -
1.901 -/**
1.902 - * Whether the account supports sending offline messages to buddy.
1.903 - *
1.904 - * @param account The account
1.905 - * @param buddy The buddy
1.906 - */
1.907 -gboolean purple_account_supports_offline_message(PurpleAccount *account, PurpleBuddy *buddy);
1.908 -
1.909 -/**
1.910 - * Get the error that caused the account to be disconnected, or @c NULL if the
1.911 - * account is happily connected or disconnected without an error.
1.912 - *
1.913 - * @param account The account whose error should be retrieved.
1.914 - * @constreturn The type of error and a human-readable description of the
1.915 - * current error, or @c NULL if there is no current error. This
1.916 - * pointer is guaranteed to remain valid until the @ref
1.917 - * account-error-changed signal is emitted for @a account.
1.918 - */
1.919 -const PurpleConnectionErrorInfo *purple_account_get_current_error(PurpleAccount *account);
1.920 -
1.921 -/**
1.922 - * Clear an account's current error state, resetting it to @c NULL.
1.923 - *
1.924 - * @param account The account whose error state should be cleared.
1.925 - */
1.926 -void purple_account_clear_current_error(PurpleAccount *account);
1.927 -
1.928 -/*@}*/
1.929 -
1.930 -/**************************************************************************/
1.931 -/** @name Accounts API */
1.932 -/**************************************************************************/
1.933 -/*@{*/
1.934 -
1.935 -/**
1.936 - * Adds an account to the list of accounts.
1.937 - *
1.938 - * @param account The account.
1.939 - */
1.940 -void purple_accounts_add(PurpleAccount *account);
1.941 -
1.942 -/**
1.943 - * Removes an account from the list of accounts.
1.944 - *
1.945 - * @param account The account.
1.946 - */
1.947 -void purple_accounts_remove(PurpleAccount *account);
1.948 -
1.949 -/**
1.950 - * Deletes an account.
1.951 - *
1.952 - * This will remove any buddies from the buddy list that belong to this
1.953 - * account, buddy pounces that belong to this account, and will also
1.954 - * destroy @a account.
1.955 - *
1.956 - * @param account The account.
1.957 - */
1.958 -void purple_accounts_delete(PurpleAccount *account);
1.959 -
1.960 -/**
1.961 - * Reorders an account.
1.962 - *
1.963 - * @param account The account to reorder.
1.964 - * @param new_index The new index for the account.
1.965 - */
1.966 -void purple_accounts_reorder(PurpleAccount *account, gint new_index);
1.967 -
1.968 -/**
1.969 - * Returns a list of all accounts.
1.970 - *
1.971 - * @constreturn A list of all accounts.
1.972 - */
1.973 -GList *purple_accounts_get_all(void);
1.974 -
1.975 -/**
1.976 - * Returns a list of all enabled accounts
1.977 - *
1.978 - * @return A list of all enabled accounts. The list is owned
1.979 - * by the caller, and must be g_list_free()d to avoid
1.980 - * leaking the nodes.
1.981 - */
1.982 -GList *purple_accounts_get_all_active(void);
1.983 -
1.984 -/**
1.985 - * Finds an account with the specified name and protocol id.
1.986 - *
1.987 - * @param name The account username.
1.988 - * @param protocol The account protocol ID.
1.989 - *
1.990 - * @return The account, if found, or @c FALSE otherwise.
1.991 - */
1.992 -PurpleAccount *purple_accounts_find(const char *name, const char *protocol);
1.993 -
1.994 -/**
1.995 - * This is called by the core after all subsystems and what
1.996 - * not have been initialized. It sets all enabled accounts
1.997 - * to their startup status by signing them on, setting them
1.998 - * away, etc.
1.999 - *
1.1000 - * You probably shouldn't call this unless you really know
1.1001 - * what you're doing.
1.1002 - */
1.1003 -void purple_accounts_restore_current_statuses(void);
1.1004 -
1.1005 -/*@}*/
1.1006 -
1.1007 -
1.1008 -/**************************************************************************/
1.1009 -/** @name UI Registration Functions */
1.1010 -/**************************************************************************/
1.1011 -/*@{*/
1.1012 -/**
1.1013 - * Sets the UI operations structure to be used for accounts.
1.1014 - *
1.1015 - * @param ops The UI operations structure.
1.1016 - */
1.1017 -void purple_accounts_set_ui_ops(PurpleAccountUiOps *ops);
1.1018 -
1.1019 -/**
1.1020 - * Returns the UI operations structure used for accounts.
1.1021 - *
1.1022 - * @return The UI operations structure in use.
1.1023 - */
1.1024 -PurpleAccountUiOps *purple_accounts_get_ui_ops(void);
1.1025 -
1.1026 -/*@}*/
1.1027 -
1.1028 -
1.1029 -/**************************************************************************/
1.1030 -/** @name Accounts Subsystem */
1.1031 -/**************************************************************************/
1.1032 -/*@{*/
1.1033 -
1.1034 -/**
1.1035 - * Returns the accounts subsystem handle.
1.1036 - *
1.1037 - * @return The accounts subsystem handle.
1.1038 - */
1.1039 -void *purple_accounts_get_handle(void);
1.1040 -
1.1041 -/**
1.1042 - * Initializes the accounts subsystem.
1.1043 - */
1.1044 -void purple_accounts_init(void);
1.1045 -
1.1046 -/**
1.1047 - * Uninitializes the accounts subsystem.
1.1048 - */
1.1049 -void purple_accounts_uninit(void);
1.1050 -
1.1051 -/*@}*/
1.1052 -
1.1053 -#ifdef __cplusplus
1.1054 -}
1.1055 -#endif
1.1056 -
1.1057 -#endif /* _PURPLE_ACCOUNT_H_ */
2.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/accountopt.h Sun Jun 21 22:04:11 2009 -0400
2.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
2.3 @@ -1,395 +0,0 @@
2.4 -/**
2.5 - * @file accountopt.h Account Options API
2.6 - * @ingroup core
2.7 - */
2.8 -
2.9 -/* purple
2.10 - *
2.11 - * Purple is the legal property of its developers, whose names are too numerous
2.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
2.13 - * source distribution.
2.14 - *
2.15 - * This program is free software; you can redistribute it and/or modify
2.16 - * it under the terms of the GNU General Public License as published by
2.17 - * the Free Software Foundation; either version 2 of the License, or
2.18 - * (at your option) any later version.
2.19 - *
2.20 - * This program is distributed in the hope that it will be useful,
2.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
2.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2.23 - * GNU General Public License for more details.
2.24 - *
2.25 - * You should have received a copy of the GNU General Public License
2.26 - * along with this program; if not, write to the Free Software
2.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
2.28 - */
2.29 -#ifndef _PURPLE_ACCOUNTOPT_H_
2.30 -#define _PURPLE_ACCOUNTOPT_H_
2.31 -
2.32 -#include "prefs.h"
2.33 -
2.34 -/**
2.35 - * An option for an account.
2.36 - *
2.37 - * This is set by protocol plugins, and appears in the account settings
2.38 - * dialogs.
2.39 - */
2.40 -typedef struct
2.41 -{
2.42 - PurplePrefType type; /**< The type of value. */
2.43 -
2.44 - char *text; /**< The text that will appear to the user. */
2.45 - char *pref_name; /**< The name of the associated preference. */
2.46 -
2.47 - union
2.48 - {
2.49 - gboolean boolean; /**< The default boolean value. */
2.50 - int integer; /**< The default integer value. */
2.51 - char *string; /**< The default string value. */
2.52 - GList *list; /**< The default list value. */
2.53 -
2.54 - } default_value;
2.55 -
2.56 - gboolean masked; /**< Whether the value entered should be
2.57 - * obscured from view (for passwords and
2.58 - * similar options)
2.59 - */
2.60 -} PurpleAccountOption;
2.61 -
2.62 -/**
2.63 - * A username split.
2.64 - *
2.65 - * This is used by some protocols to separate the fields of the username
2.66 - * into more human-readable components.
2.67 - */
2.68 -typedef struct
2.69 -{
2.70 - char *text; /**< The text that will appear to the user. */
2.71 - char *default_value; /**< The default value. */
2.72 - char field_sep; /**< The field separator. */
2.73 - gboolean reverse; /**< TRUE if the separator should be found
2.74 - starting a the end of the string, FALSE
2.75 - otherwise */
2.76 -
2.77 -} PurpleAccountUserSplit;
2.78 -
2.79 -#ifdef __cplusplus
2.80 -extern "C" {
2.81 -#endif
2.82 -
2.83 -/**************************************************************************/
2.84 -/** @name Account Option API */
2.85 -/**************************************************************************/
2.86 -/*@{*/
2.87 -
2.88 -/**
2.89 - * Creates a new account option. If you know what @a type will be in advance,
2.90 - * consider using purple_account_option_bool_new(),
2.91 - * purple_account_option_int_new(), purple_account_option_string_new() or
2.92 - * purple_account_option_list_new() (as appropriate) instead.
2.93 - *
2.94 - * @param type The type of option.
2.95 - * @param text The text of the option.
2.96 - * @param pref_name The account preference name for the option.
2.97 - *
2.98 - * @return The account option.
2.99 - */
2.100 -PurpleAccountOption *purple_account_option_new(PurplePrefType type,
2.101 - const char *text, const char *pref_name);
2.102 -
2.103 -/**
2.104 - * Creates a new boolean account option.
2.105 - *
2.106 - * @param text The text of the option.
2.107 - * @param pref_name The account preference name for the option.
2.108 - * @param default_value The default value.
2.109 - *
2.110 - * @return The account option.
2.111 - */
2.112 -PurpleAccountOption *purple_account_option_bool_new(const char *text,
2.113 - const char *pref_name, gboolean default_value);
2.114 -
2.115 -/**
2.116 - * Creates a new integer account option.
2.117 - *
2.118 - * @param text The text of the option.
2.119 - * @param pref_name The account preference name for the option.
2.120 - * @param default_value The default value.
2.121 - *
2.122 - * @return The account option.
2.123 - */
2.124 -PurpleAccountOption *purple_account_option_int_new(const char *text,
2.125 - const char *pref_name, int default_value);
2.126 -
2.127 -/**
2.128 - * Creates a new string account option.
2.129 - *
2.130 - * @param text The text of the option.
2.131 - * @param pref_name The account preference name for the option.
2.132 - * @param default_value The default value.
2.133 - *
2.134 - * @return The account option.
2.135 - */
2.136 -PurpleAccountOption *purple_account_option_string_new(const char *text,
2.137 - const char *pref_name, const char *default_value);
2.138 -
2.139 -/**
2.140 - * Creates a new list account option.
2.141 - *
2.142 - * The list passed will be owned by the account option, and the
2.143 - * strings inside will be freed automatically.
2.144 - *
2.145 - * The list is a list of #PurpleKeyValuePair items. The key is the label that
2.146 - * should be displayed to the user, and the <tt>(const char *)</tt> value is
2.147 - * the internal ID that should be passed to purple_account_set_string() to
2.148 - * choose that value.
2.149 - *
2.150 - * @param text The text of the option.
2.151 - * @param pref_name The account preference name for the option.
2.152 - * @param list The key, value list.
2.153 - *
2.154 - * @return The account option.
2.155 - */
2.156 -PurpleAccountOption *purple_account_option_list_new(const char *text,
2.157 - const char *pref_name, GList *list);
2.158 -
2.159 -/**
2.160 - * Destroys an account option.
2.161 - *
2.162 - * @param option The option to destroy.
2.163 - */
2.164 -void purple_account_option_destroy(PurpleAccountOption *option);
2.165 -
2.166 -/**
2.167 - * Sets the default boolean value for an account option.
2.168 - *
2.169 - * @param option The account option.
2.170 - * @param value The default boolean value.
2.171 - */
2.172 -void purple_account_option_set_default_bool(PurpleAccountOption *option,
2.173 - gboolean value);
2.174 -
2.175 -/**
2.176 - * Sets the default integer value for an account option.
2.177 - *
2.178 - * @param option The account option.
2.179 - * @param value The default integer value.
2.180 - */
2.181 -void purple_account_option_set_default_int(PurpleAccountOption *option,
2.182 - int value);
2.183 -
2.184 -/**
2.185 - * Sets the default string value for an account option.
2.186 - *
2.187 - * @param option The account option.
2.188 - * @param value The default string value.
2.189 - */
2.190 -void purple_account_option_set_default_string(PurpleAccountOption *option,
2.191 - const char *value);
2.192 -
2.193 -/**
2.194 - * Sets the masking for an account option. Setting this to %TRUE acts
2.195 - * as a hint to the UI that the option's value should be obscured from
2.196 - * view, like a password.
2.197 - *
2.198 - * @param option The account option.
2.199 - * @param masked The masking.
2.200 - */
2.201 -void
2.202 -purple_account_option_set_masked(PurpleAccountOption *option, gboolean masked);
2.203 -
2.204 -/**
2.205 - * Sets the list values for an account option.
2.206 - *
2.207 - * The list passed will be owned by the account option, and the
2.208 - * strings inside will be freed automatically.
2.209 - *
2.210 - * The list is in key, value pairs. The key is the ID stored and used
2.211 - * internally, and the value is the label displayed.
2.212 - *
2.213 - * @param option The account option.
2.214 - * @param values The default list value.
2.215 - */
2.216 -void purple_account_option_set_list(PurpleAccountOption *option, GList *values);
2.217 -
2.218 -/**
2.219 - * Adds an item to a list account option.
2.220 - *
2.221 - * @param option The account option.
2.222 - * @param key The key.
2.223 - * @param value The value.
2.224 - */
2.225 -void purple_account_option_add_list_item(PurpleAccountOption *option,
2.226 - const char *key, const char *value);
2.227 -
2.228 -/**
2.229 - * Returns the specified account option's type.
2.230 - *
2.231 - * @param option The account option.
2.232 - *
2.233 - * @return The account option's type.
2.234 - */
2.235 -PurplePrefType purple_account_option_get_type(const PurpleAccountOption *option);
2.236 -
2.237 -/**
2.238 - * Returns the text for an account option.
2.239 - *
2.240 - * @param option The account option.
2.241 - *
2.242 - * @return The account option's text.
2.243 - */
2.244 -const char *purple_account_option_get_text(const PurpleAccountOption *option);
2.245 -
2.246 -/**
2.247 - * Returns the name of an account option. This corresponds to the @c pref_name
2.248 - * parameter supplied to purple_account_option_new() or one of the
2.249 - * type-specific constructors.
2.250 - *
2.251 - * @param option The account option.
2.252 - *
2.253 - * @return The option's name.
2.254 - */
2.255 -const char *purple_account_option_get_setting(const PurpleAccountOption *option);
2.256 -
2.257 -/**
2.258 - * Returns the default boolean value for an account option.
2.259 - *
2.260 - * @param option The account option.
2.261 - *
2.262 - * @return The default boolean value.
2.263 - */
2.264 -gboolean purple_account_option_get_default_bool(const PurpleAccountOption *option);
2.265 -
2.266 -/**
2.267 - * Returns the default integer value for an account option.
2.268 - *
2.269 - * @param option The account option.
2.270 - *
2.271 - * @return The default integer value.
2.272 - */
2.273 -int purple_account_option_get_default_int(const PurpleAccountOption *option);
2.274 -
2.275 -/**
2.276 - * Returns the default string value for an account option.
2.277 - *
2.278 - * @param option The account option.
2.279 - *
2.280 - * @return The default string value.
2.281 - */
2.282 -const char *purple_account_option_get_default_string(
2.283 - const PurpleAccountOption *option);
2.284 -
2.285 -/**
2.286 - * Returns the default string value for a list account option.
2.287 - *
2.288 - * @param option The account option.
2.289 - *
2.290 - * @return The default list string value.
2.291 - */
2.292 -const char *purple_account_option_get_default_list_value(
2.293 - const PurpleAccountOption *option);
2.294 -
2.295 -/**
2.296 - * Returns whether an option's value should be masked from view, like a
2.297 - * password. If so, the UI might display each character of the option
2.298 - * as a '*' (for example).
2.299 - *
2.300 - * @param option The account option.
2.301 - *
2.302 - * @return %TRUE if the option's value should be obscured.
2.303 - */
2.304 -gboolean
2.305 -purple_account_option_get_masked(const PurpleAccountOption *option);
2.306 -
2.307 -/**
2.308 - * Returns the list values for an account option.
2.309 - *
2.310 - * @param option The account option.
2.311 - *
2.312 - * @constreturn A list of #PurpleKeyValuePair, mapping the human-readable
2.313 - * description of the value to the <tt>(const char *)</tt> that
2.314 - * should be passed to purple_account_set_string() to set the
2.315 - * option.
2.316 - */
2.317 -GList *purple_account_option_get_list(const PurpleAccountOption *option);
2.318 -
2.319 -/*@}*/
2.320 -
2.321 -
2.322 -/**************************************************************************/
2.323 -/** @name Account User Split API */
2.324 -/**************************************************************************/
2.325 -/*@{*/
2.326 -
2.327 -/**
2.328 - * Creates a new account username split.
2.329 - *
2.330 - * @param text The text of the option.
2.331 - * @param default_value The default value.
2.332 - * @param sep The field separator.
2.333 - *
2.334 - * @return The new user split.
2.335 - */
2.336 -PurpleAccountUserSplit *purple_account_user_split_new(const char *text,
2.337 - const char *default_value,
2.338 - char sep);
2.339 -
2.340 -/**
2.341 - * Destroys an account username split.
2.342 - *
2.343 - * @param split The split to destroy.
2.344 - */
2.345 -void purple_account_user_split_destroy(PurpleAccountUserSplit *split);
2.346 -
2.347 -/**
2.348 - * Returns the text for an account username split.
2.349 - *
2.350 - * @param split The account username split.
2.351 - *
2.352 - * @return The account username split's text.
2.353 - */
2.354 -const char *purple_account_user_split_get_text(const PurpleAccountUserSplit *split);
2.355 -
2.356 -/**
2.357 - * Returns the default string value for an account split.
2.358 - *
2.359 - * @param split The account username split.
2.360 - *
2.361 - * @return The default string.
2.362 - */
2.363 -const char *purple_account_user_split_get_default_value(
2.364 - const PurpleAccountUserSplit *split);
2.365 -
2.366 -/**
2.367 - * Returns the field separator for an account split.
2.368 - *
2.369 - * @param split The account username split.
2.370 - *
2.371 - * @return The field separator.
2.372 - */
2.373 -char purple_account_user_split_get_separator(const PurpleAccountUserSplit *split);
2.374 -
2.375 -/**
2.376 - * Returns the 'reverse' value for an account split.
2.377 - *
2.378 - * @param split The account username split.
2.379 - *
2.380 - * @return The 'reverse' value.
2.381 - */
2.382 -gboolean purple_account_user_split_get_reverse(const PurpleAccountUserSplit *split);
2.383 -
2.384 -/**
2.385 - * Sets the 'reverse' value for an account split.
2.386 - *
2.387 - * @param split The account username split.
2.388 - * @param reverse The 'reverse' value
2.389 - */
2.390 -void purple_account_user_split_set_reverse(PurpleAccountUserSplit *split, gboolean reverse);
2.391 -
2.392 -/*@}*/
2.393 -
2.394 -#ifdef __cplusplus
2.395 -}
2.396 -#endif
2.397 -
2.398 -#endif /* _PURPLE_ACCOUNTOPT_H_ */
3.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/blist.h Sun Jun 21 22:04:11 2009 -0400
3.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
3.3 @@ -1,1045 +0,0 @@
3.4 -/**
3.5 - * @file blist.h Buddy List API
3.6 - * @ingroup core
3.7 - * @see @ref blist-signals
3.8 - */
3.9 -
3.10 -/* purple
3.11 - *
3.12 - * Purple is the legal property of its developers, whose names are too numerous
3.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
3.14 - * source distribution.
3.15 - *
3.16 - * This program is free software; you can redistribute it and/or modify
3.17 - * it under the terms of the GNU General Public License as published by
3.18 - * the Free Software Foundation; either version 2 of the License, or
3.19 - * (at your option) any later version.
3.20 - *
3.21 - * This program is distributed in the hope that it will be useful,
3.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
3.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3.24 - * GNU General Public License for more details.
3.25 - *
3.26 - * You should have received a copy of the GNU General Public License
3.27 - * along with this program; if not, write to the Free Software
3.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
3.29 - */
3.30 -#ifndef _PURPLE_BLIST_H_
3.31 -#define _PURPLE_BLIST_H_
3.32 -
3.33 -/* I can't believe I let ChipX86 inspire me to write good code. -Sean */
3.34 -
3.35 -#include <glib.h>
3.36 -
3.37 -/** @copydoc _PurpleBuddyList */
3.38 -typedef struct _PurpleBuddyList PurpleBuddyList;
3.39 -/** @copydoc _PurpleBlistUiOps */
3.40 -typedef struct _PurpleBlistUiOps PurpleBlistUiOps;
3.41 -/** @copydoc _PurpleBlistNode */
3.42 -typedef struct _PurpleBlistNode PurpleBlistNode;
3.43 -
3.44 -/** @copydoc _PurpleChat */
3.45 -typedef struct _PurpleChat PurpleChat;
3.46 -/** @copydoc _PurpleGroup */
3.47 -typedef struct _PurpleGroup PurpleGroup;
3.48 -/** @copydoc _PurpleContact */
3.49 -typedef struct _PurpleContact PurpleContact;
3.50 -/** @copydoc _PurpleBuddy */
3.51 -typedef struct _PurpleBuddy PurpleBuddy;
3.52 -
3.53 -/**************************************************************************/
3.54 -/* Enumerations */
3.55 -/**************************************************************************/
3.56 -typedef enum
3.57 -{
3.58 - PURPLE_BLIST_GROUP_NODE,
3.59 - PURPLE_BLIST_CONTACT_NODE,
3.60 - PURPLE_BLIST_BUDDY_NODE,
3.61 - PURPLE_BLIST_CHAT_NODE,
3.62 - PURPLE_BLIST_OTHER_NODE
3.63 -
3.64 -} PurpleBlistNodeType;
3.65 -
3.66 -#define PURPLE_BLIST_NODE_IS_CHAT(n) (purple_blist_node_get_type(n) == PURPLE_BLIST_CHAT_NODE)
3.67 -#define PURPLE_BLIST_NODE_IS_BUDDY(n) (purple_blist_node_get_type(n) == PURPLE_BLIST_BUDDY_NODE)
3.68 -#define PURPLE_BLIST_NODE_IS_CONTACT(n) (purple_blist_node_get_type(n) == PURPLE_BLIST_CONTACT_NODE)
3.69 -#define PURPLE_BLIST_NODE_IS_GROUP(n) (purple_blist_node_get_type(n) == PURPLE_BLIST_GROUP_NODE)
3.70 -
3.71 -#define PURPLE_BUDDY_IS_ONLINE(b) \
3.72 - ((b) != NULL && purple_account_is_connected(purple_buddy_get_account(b)) && \
3.73 - purple_presence_is_online(purple_buddy_get_presence(b)))
3.74 -
3.75 -typedef enum
3.76 -{
3.77 - PURPLE_BLIST_NODE_FLAG_NO_SAVE = 1 << 0 /**< node should not be saved with the buddy list */
3.78 -
3.79 -} PurpleBlistNodeFlags;
3.80 -
3.81 -#define PURPLE_BLIST_NODE_HAS_FLAG(b, f) (purple_blist_node_get_flags((PurpleBlistNode*)(b)) & (f))
3.82 -#define PURPLE_BLIST_NODE_SHOULD_SAVE(b) (! PURPLE_BLIST_NODE_HAS_FLAG(b, PURPLE_BLIST_NODE_FLAG_NO_SAVE))
3.83 -
3.84 -#define PURPLE_BLIST_NODE_NAME(n) (purple_blist_node_get_type(n) == PURPLE_BLIST_CHAT_NODE ? purple_chat_get_name((PurpleChat*)n) : \
3.85 - purple_blist_node_get_type(n) == PURPLE_BLIST_BUDDY_NODE ? purple_buddy_get_name((PurpleBuddy*)n) : NULL)
3.86 -
3.87 -#include "account.h"
3.88 -#include "buddyicon.h"
3.89 -#include "status.h"
3.90 -
3.91 -/**************************************************************************/
3.92 -/* Data Structures */
3.93 -/**************************************************************************/
3.94 -
3.95 -#if !(defined PURPLE_HIDE_STRUCTS) || (defined _PURPLE_BLIST_C_)
3.96 -
3.97 -/**
3.98 - * A Buddy list node. This can represent a group, a buddy, or anything else.
3.99 - * This is a base class for struct buddy and struct group and for anything
3.100 - * else that wants to put itself in the buddy list. */
3.101 -struct _PurpleBlistNode {
3.102 - PurpleBlistNodeType type; /**< The type of node this is */
3.103 - PurpleBlistNode *prev; /**< The sibling before this buddy. */
3.104 - PurpleBlistNode *next; /**< The sibling after this buddy. */
3.105 - PurpleBlistNode *parent; /**< The parent of this node */
3.106 - PurpleBlistNode *child; /**< The child of this node */
3.107 - GHashTable *settings; /**< per-node settings */
3.108 - void *ui_data; /**< The UI can put data here. */
3.109 - PurpleBlistNodeFlags flags; /**< The buddy flags */
3.110 -};
3.111 -
3.112 -/**
3.113 - * A buddy. This contains everything Purple will ever need to know about someone on the buddy list. Everything.
3.114 - */
3.115 -struct _PurpleBuddy {
3.116 - PurpleBlistNode node; /**< The node that this buddy inherits from */
3.117 - char *name; /**< The screenname of the buddy. */
3.118 - char *alias; /**< The user-set alias of the buddy */
3.119 - char *server_alias; /**< The server-specified alias of the buddy. (i.e. MSN "Friendly Names") */
3.120 - void *proto_data; /**< This allows the prpl to associate whatever data it wants with a buddy */
3.121 - PurpleBuddyIcon *icon; /**< The buddy icon. */
3.122 - PurpleAccount *account; /**< the account this buddy belongs to */
3.123 - PurplePresence *presence;
3.124 -};
3.125 -
3.126 -/**
3.127 - * A contact. This contains everything Purple will ever need to know about a contact.
3.128 - */
3.129 -struct _PurpleContact {
3.130 - PurpleBlistNode node; /**< The node that this contact inherits from. */
3.131 - char *alias; /**< The user-set alias of the contact */
3.132 - int totalsize; /**< The number of buddies in this contact */
3.133 - int currentsize; /**< The number of buddies in this contact corresponding to online accounts */
3.134 - int online; /**< The number of buddies in this contact who are currently online */
3.135 - PurpleBuddy *priority; /**< The "top" buddy for this contact */
3.136 - gboolean priority_valid; /**< Is priority valid? */
3.137 -};
3.138 -
3.139 -
3.140 -/**
3.141 - * A group. This contains everything Purple will ever need to know about a group.
3.142 - */
3.143 -struct _PurpleGroup {
3.144 - PurpleBlistNode node; /**< The node that this group inherits from */
3.145 - char *name; /**< The name of this group. */
3.146 - int totalsize; /**< The number of chats and contacts in this group */
3.147 - int currentsize; /**< The number of chats and contacts in this group corresponding to online accounts */
3.148 - int online; /**< The number of chats and contacts in this group who are currently online */
3.149 -};
3.150 -
3.151 -/**
3.152 - * A chat. This contains everything Purple needs to put a chat room in the
3.153 - * buddy list.
3.154 - */
3.155 -struct _PurpleChat {
3.156 - PurpleBlistNode node; /**< The node that this chat inherits from */
3.157 - char *alias; /**< The display name of this chat. */
3.158 - GHashTable *components; /**< the stuff the protocol needs to know to join the chat */
3.159 - PurpleAccount *account; /**< The account this chat is attached to */
3.160 -};
3.161 -
3.162 -#endif /* PURPLE_HIDE_STRUCTS && PURPLE_BLIST_STRUCTS */
3.163 -
3.164 -
3.165 -/**
3.166 - * The Buddy List
3.167 - */
3.168 -struct _PurpleBuddyList {
3.169 - PurpleBlistNode *root; /**< The first node in the buddy list */
3.170 - GHashTable *buddies; /**< Every buddy in this list */
3.171 - void *ui_data; /**< UI-specific data. */
3.172 -};
3.173 -
3.174 -/**
3.175 - * Buddy list UI operations.
3.176 - *
3.177 - * Any UI representing a buddy list must assign a filled-out PurpleBlistUiOps
3.178 - * structure to the buddy list core.
3.179 - */
3.180 -struct _PurpleBlistUiOps
3.181 -{
3.182 - void (*new_list)(PurpleBuddyList *list); /**< Sets UI-specific data on a buddy list. */
3.183 - void (*new_node)(PurpleBlistNode *node); /**< Sets UI-specific data on a node. */
3.184 - void (*show)(PurpleBuddyList *list); /**< The core will call this when it's finished doing its core stuff */
3.185 - void (*update)(PurpleBuddyList *list,
3.186 - PurpleBlistNode *node); /**< This will update a node in the buddy list. */
3.187 - void (*remove)(PurpleBuddyList *list,
3.188 - PurpleBlistNode *node); /**< This removes a node from the list */
3.189 - void (*destroy)(PurpleBuddyList *list); /**< When the list gets destroyed, this gets called to destroy the UI. */
3.190 - void (*set_visible)(PurpleBuddyList *list,
3.191 - gboolean show); /**< Hides or unhides the buddy list */
3.192 - void (*request_add_buddy)(PurpleAccount *account, const char *username,
3.193 - const char *group, const char *alias);
3.194 - void (*request_add_chat)(PurpleAccount *account, PurpleGroup *group,
3.195 - const char *alias, const char *name);
3.196 - void (*request_add_group)(void);
3.197 -
3.198 - void (*_purple_reserved1)(void);
3.199 - void (*_purple_reserved2)(void);
3.200 - void (*_purple_reserved3)(void);
3.201 - void (*_purple_reserved4)(void);
3.202 -};
3.203 -
3.204 -#ifdef __cplusplus
3.205 -extern "C" {
3.206 -#endif
3.207 -
3.208 -/**************************************************************************/
3.209 -/** @name Buddy List API */
3.210 -/**************************************************************************/
3.211 -/*@{*/
3.212 -
3.213 -/**
3.214 - * Creates a new buddy list
3.215 - *
3.216 - * @return The new buddy list.
3.217 - */
3.218 -PurpleBuddyList *purple_blist_new(void);
3.219 -
3.220 -/**
3.221 - * Sets the main buddy list.
3.222 - *
3.223 - * @param blist The buddy list you want to use.
3.224 - */
3.225 -void purple_set_blist(PurpleBuddyList *blist);
3.226 -
3.227 -/**
3.228 - * Returns the main buddy list.
3.229 - *
3.230 - * @return The main buddy list.
3.231 - */
3.232 -PurpleBuddyList *purple_get_blist(void);
3.233 -
3.234 -/**
3.235 - * Returns the root node of the main buddy list.
3.236 - *
3.237 - * @return The root node.
3.238 - */
3.239 -PurpleBlistNode *purple_blist_get_root(void);
3.240 -
3.241 -/**
3.242 - * Returns the next node of a given node. This function is to be used to iterate
3.243 - * over the tree returned by purple_get_blist.
3.244 - *
3.245 - * @param node A node.
3.246 - * @param offline Whether to include nodes for offline accounts
3.247 - * @return The next node
3.248 - * @see purple_blist_node_get_parent
3.249 - * @see purple_blist_node_get_first_child
3.250 - * @see purple_blist_node_get_sibling_next
3.251 - * @see purple_blist_node_get_sibling_prev
3.252 - */
3.253 -PurpleBlistNode *purple_blist_node_next(PurpleBlistNode *node, gboolean offline);
3.254 -
3.255 -/**
3.256 - * Returns the parent node of a given node.
3.257 - *
3.258 - * @param node A node.
3.259 - * @return The parent node.
3.260 - * @since 2.4.0
3.261 - * @see purple_blist_node_get_first_child
3.262 - * @see purple_blist_node_get_sibling_next
3.263 - * @see purple_blist_node_get_sibling_prev
3.264 - * @see purple_blist_node_next
3.265 - */
3.266 -PurpleBlistNode *purple_blist_node_get_parent(PurpleBlistNode *node);
3.267 -
3.268 -/**
3.269 - * Returns the the first child node of a given node.
3.270 - *
3.271 - * @param node A node.
3.272 - * @return The child node.
3.273 - * @since 2.4.0
3.274 - * @see purple_blist_node_get_parent
3.275 - * @see purple_blist_node_get_sibling_next
3.276 - * @see purple_blist_node_get_sibling_prev
3.277 - * @see purple_blist_node_next
3.278 - */
3.279 -PurpleBlistNode *purple_blist_node_get_first_child(PurpleBlistNode *node);
3.280 -
3.281 -/**
3.282 - * Returns the sibling node of a given node.
3.283 - *
3.284 - * @param node A node.
3.285 - * @return The sibling node.
3.286 - * @since 2.4.0
3.287 - * @see purple_blist_node_get_parent
3.288 - * @see purple_blist_node_get_first_child
3.289 - * @see purple_blist_node_get_sibling_prev
3.290 - * @see purple_blist_node_next
3.291 - */
3.292 -PurpleBlistNode *purple_blist_node_get_sibling_next(PurpleBlistNode *node);
3.293 -
3.294 -/**
3.295 - * Returns the previous sibling node of a given node.
3.296 - *
3.297 - * @param node A node.
3.298 - * @return The sibling node.
3.299 - * @since 2.4.0
3.300 - * @see purple_blist_node_get_parent
3.301 - * @see purple_blist_node_get_first_child
3.302 - * @see purple_blist_node_get_sibling_next
3.303 - * @see purple_blist_node_next
3.304 - */
3.305 -PurpleBlistNode *purple_blist_node_get_sibling_prev(PurpleBlistNode *node);
3.306 -
3.307 -/**
3.308 - * Shows the buddy list, creating a new one if necessary.
3.309 - */
3.310 -void purple_blist_show(void);
3.311 -
3.312 -
3.313 -/**
3.314 - * Destroys the buddy list window.
3.315 - */
3.316 -void purple_blist_destroy(void);
3.317 -
3.318 -/**
3.319 - * Hides or unhides the buddy list.
3.320 - *
3.321 - * @param show Whether or not to show the buddy list
3.322 - */
3.323 -void purple_blist_set_visible(gboolean show);
3.324 -
3.325 -/**
3.326 - * Updates a buddy's status.
3.327 - *
3.328 - * @param buddy The buddy whose status has changed.
3.329 - * @param old_status The status from which we are changing.
3.330 - */
3.331 -void purple_blist_update_buddy_status(PurpleBuddy *buddy, PurpleStatus *old_status);
3.332 -
3.333 -/**
3.334 - * Updates a node's custom icon.
3.335 - *
3.336 - * @param node The PurpleBlistNode whose custom icon has changed.
3.337 - * @since 2.5.0
3.338 - */
3.339 -void purple_blist_update_node_icon(PurpleBlistNode *node);
3.340 -
3.341 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_BLIST_C_)
3.342 -/**
3.343 - * Updates a buddy's icon.
3.344 - *
3.345 - * @param buddy The buddy whose buddy icon has changed
3.346 - * @deprecated Use purple_blist_update_node_icon() instead.
3.347 - */
3.348 -void purple_blist_update_buddy_icon(PurpleBuddy *buddy);
3.349 -#endif
3.350 -
3.351 -/**
3.352 - * Renames a buddy in the buddy list.
3.353 - *
3.354 - * @param buddy The buddy whose name will be changed.
3.355 - * @param name The new name of the buddy.
3.356 - */
3.357 -void purple_blist_rename_buddy(PurpleBuddy *buddy, const char *name);
3.358 -
3.359 -/**
3.360 - * Aliases a contact in the buddy list.
3.361 - *
3.362 - * @param contact The contact whose alias will be changed.
3.363 - * @param alias The contact's alias.
3.364 - */
3.365 -void purple_blist_alias_contact(PurpleContact *contact, const char *alias);
3.366 -
3.367 -/**
3.368 - * Aliases a buddy in the buddy list.
3.369 - *
3.370 - * @param buddy The buddy whose alias will be changed.
3.371 - * @param alias The buddy's alias.
3.372 - */
3.373 -void purple_blist_alias_buddy(PurpleBuddy *buddy, const char *alias);
3.374 -
3.375 -/**
3.376 - * Sets the server-sent alias of a buddy in the buddy list.
3.377 - * PRPLs should call serv_got_alias() instead of this.
3.378 - *
3.379 - * @param buddy The buddy whose alias will be changed.
3.380 - * @param alias The buddy's "official" alias.
3.381 - */
3.382 -void purple_blist_server_alias_buddy(PurpleBuddy *buddy, const char *alias);
3.383 -
3.384 -/**
3.385 - * Aliases a chat in the buddy list.
3.386 - *
3.387 - * @param chat The chat whose alias will be changed.
3.388 - * @param alias The chat's new alias.
3.389 - */
3.390 -void purple_blist_alias_chat(PurpleChat *chat, const char *alias);
3.391 -
3.392 -/**
3.393 - * Renames a group
3.394 - *
3.395 - * @param group The group to rename
3.396 - * @param name The new name
3.397 - */
3.398 -void purple_blist_rename_group(PurpleGroup *group, const char *name);
3.399 -
3.400 -/**
3.401 - * Creates a new chat for the buddy list
3.402 - *
3.403 - * @param account The account this chat will get added to
3.404 - * @param alias The alias of the new chat
3.405 - * @param components The info the prpl needs to join the chat. The
3.406 - * hash function should be g_str_hash() and the
3.407 - * equal function should be g_str_equal().
3.408 - * @return A newly allocated chat
3.409 - */
3.410 -PurpleChat *purple_chat_new(PurpleAccount *account, const char *alias, GHashTable *components);
3.411 -
3.412 -/**
3.413 - * Adds a new chat to the buddy list.
3.414 - *
3.415 - * The chat will be inserted right after node or appended to the end
3.416 - * of group if node is NULL. If both are NULL, the buddy will be added to
3.417 - * the "Chats" group.
3.418 - *
3.419 - * @param chat The new chat who gets added
3.420 - * @param group The group to add the new chat to.
3.421 - * @param node The insertion point
3.422 - */
3.423 -void purple_blist_add_chat(PurpleChat *chat, PurpleGroup *group, PurpleBlistNode *node);
3.424 -
3.425 -/**
3.426 - * Creates a new buddy
3.427 - *
3.428 - * @param account The account this buddy will get added to
3.429 - * @param screenname The screenname of the new buddy
3.430 - * @param alias The alias of the new buddy (or NULL if unaliased)
3.431 - * @return A newly allocated buddy
3.432 - */
3.433 -PurpleBuddy *purple_buddy_new(PurpleAccount *account, const char *screenname, const char *alias);
3.434 -
3.435 -/**
3.436 - * Sets a buddy's icon.
3.437 - *
3.438 - * This should only be called from within Purple. You probably want to
3.439 - * call purple_buddy_icon_set_data().
3.440 - *
3.441 - * @param buddy The buddy.
3.442 - * @param icon The buddy icon.
3.443 - *
3.444 - * @see purple_buddy_icon_set_data()
3.445 - */
3.446 -void purple_buddy_set_icon(PurpleBuddy *buddy, PurpleBuddyIcon *icon);
3.447 -
3.448 -/**
3.449 - * Returns a buddy's account.
3.450 - *
3.451 - * @param buddy The buddy.
3.452 - *
3.453 - * @return The account
3.454 - */
3.455 -PurpleAccount *purple_buddy_get_account(const PurpleBuddy *buddy);
3.456 -
3.457 -/**
3.458 - * Returns a buddy's name
3.459 - *
3.460 - * @param buddy The buddy.
3.461 - *
3.462 - * @return The name.
3.463 - */
3.464 -const char *purple_buddy_get_name(const PurpleBuddy *buddy);
3.465 -
3.466 -/**
3.467 - * Returns a buddy's icon.
3.468 - *
3.469 - * @param buddy The buddy.
3.470 - *
3.471 - * @return The buddy icon.
3.472 - */
3.473 -PurpleBuddyIcon *purple_buddy_get_icon(const PurpleBuddy *buddy);
3.474 -
3.475 -/**
3.476 - * Returns a buddy's contact.
3.477 - *
3.478 - * @param buddy The buddy.
3.479 - *
3.480 - * @return The buddy's contact.
3.481 - */
3.482 -PurpleContact *purple_buddy_get_contact(PurpleBuddy *buddy);
3.483 -
3.484 -/**
3.485 - * Returns a buddy's presence.
3.486 - *
3.487 - * @param buddy The buddy.
3.488 - *
3.489 - * @return The buddy's presence.
3.490 - */
3.491 -PurplePresence *purple_buddy_get_presence(const PurpleBuddy *buddy);
3.492 -
3.493 -/**
3.494 - * Adds a new buddy to the buddy list.
3.495 - *
3.496 - * The buddy will be inserted right after node or prepended to the
3.497 - * group if node is NULL. If both are NULL, the buddy will be added to
3.498 - * the "Buddies" group.
3.499 - *
3.500 - * @param buddy The new buddy who gets added
3.501 - * @param contact The optional contact to place the buddy in.
3.502 - * @param group The group to add the new buddy to.
3.503 - * @param node The insertion point. Pass in NULL to add the node as
3.504 - * the last child in the given group.
3.505 - */
3.506 -void purple_blist_add_buddy(PurpleBuddy *buddy, PurpleContact *contact, PurpleGroup *group, PurpleBlistNode *node);
3.507 -
3.508 -/**
3.509 - * Creates a new group
3.510 - *
3.511 - * You can't have more than one group with the same name. Sorry. If you pass
3.512 - * this the * name of a group that already exists, it will return that group.
3.513 - *
3.514 - * @param name The name of the new group
3.515 - * @return A new group struct
3.516 -*/
3.517 -PurpleGroup *purple_group_new(const char *name);
3.518 -
3.519 -/**
3.520 - * Adds a new group to the buddy list.
3.521 - *
3.522 - * The new group will be inserted after insert or prepended to the list if
3.523 - * node is NULL.
3.524 - *
3.525 - * @param group The group
3.526 - * @param node The insertion point
3.527 - */
3.528 -void purple_blist_add_group(PurpleGroup *group, PurpleBlistNode *node);
3.529 -
3.530 -/**
3.531 - * Creates a new contact
3.532 - *
3.533 - * @return A new contact struct
3.534 - */
3.535 -PurpleContact *purple_contact_new(void);
3.536 -
3.537 -/**
3.538 - * Adds a new contact to the buddy list.
3.539 - *
3.540 - * The new contact will be inserted after insert or prepended to the list if
3.541 - * node is NULL.
3.542 - *
3.543 - * @param contact The contact
3.544 - * @param group The group to add the contact to
3.545 - * @param node The insertion point
3.546 - */
3.547 -void purple_blist_add_contact(PurpleContact *contact, PurpleGroup *group, PurpleBlistNode *node);
3.548 -
3.549 -/**
3.550 - * Merges two contacts
3.551 - *
3.552 - * All of the buddies from source will be moved to target
3.553 - *
3.554 - * @param source The contact to merge
3.555 - * @param node The place to merge to (a buddy or contact)
3.556 - */
3.557 -void purple_blist_merge_contact(PurpleContact *source, PurpleBlistNode *node);
3.558 -
3.559 -/**
3.560 - * Returns the highest priority buddy for a given contact.
3.561 - *
3.562 - * @param contact The contact
3.563 - * @return The highest priority buddy
3.564 - */
3.565 -PurpleBuddy *purple_contact_get_priority_buddy(PurpleContact *contact);
3.566 -
3.567 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_BLIST_C_)
3.568 -/**
3.569 - * Sets the alias for a contact.
3.570 - *
3.571 - * @param contact The contact
3.572 - * @param alias The alias to set, or NULL to unset
3.573 - *
3.574 - * @deprecated Use purple_blist_alias_contact() instead.
3.575 - */
3.576 -void purple_contact_set_alias(PurpleContact *contact, const char *alias);
3.577 -#endif
3.578 -
3.579 -/**
3.580 - * Gets the alias for a contact.
3.581 - *
3.582 - * @param contact The contact
3.583 - * @return The alias, or NULL if it is not set.
3.584 - */
3.585 -const char *purple_contact_get_alias(PurpleContact *contact);
3.586 -
3.587 -/**
3.588 - * Determines whether an account owns any buddies in a given contact
3.589 - *
3.590 - * @param contact The contact to search through.
3.591 - * @param account The account.
3.592 - *
3.593 - * @return TRUE if there are any buddies from account in the contact, or FALSE otherwise.
3.594 - */
3.595 -gboolean purple_contact_on_account(PurpleContact *contact, PurpleAccount *account);
3.596 -
3.597 -/**
3.598 - * Invalidates the priority buddy so that the next call to
3.599 - * purple_contact_get_priority_buddy recomputes it.
3.600 - *
3.601 - * @param contact The contact
3.602 - */
3.603 -void purple_contact_invalidate_priority_buddy(PurpleContact *contact);
3.604 -
3.605 -/**
3.606 - * Removes a buddy from the buddy list and frees the memory allocated to it.
3.607 - * This doesn't actually try to remove the buddy from the server list, nor does
3.608 - * it clean up the prpl_data.
3.609 - *
3.610 - * @param buddy The buddy to be removed
3.611 - */
3.612 -void purple_blist_remove_buddy(PurpleBuddy *buddy);
3.613 -
3.614 -/**
3.615 - * Removes a contact, and any buddies it contains, and frees the memory
3.616 - * allocated to it.
3.617 - *
3.618 - * @param contact The contact to be removed
3.619 - */
3.620 -void purple_blist_remove_contact(PurpleContact *contact);
3.621 -
3.622 -/**
3.623 - * Removes a chat from the buddy list and frees the memory allocated to it.
3.624 - *
3.625 - * @param chat The chat to be removed
3.626 - */
3.627 -void purple_blist_remove_chat(PurpleChat *chat);
3.628 -
3.629 -/**
3.630 - * Removes a group from the buddy list and frees the memory allocated to it and to
3.631 - * its children
3.632 - *
3.633 - * @param group The group to be removed
3.634 - */
3.635 -void purple_blist_remove_group(PurpleGroup *group);
3.636 -
3.637 -/**
3.638 - * Returns the alias of a buddy.
3.639 - *
3.640 - * @param buddy The buddy whose name will be returned.
3.641 - * @return The alias (if set), server alias (if set),
3.642 - * or NULL.
3.643 - */
3.644 -const char *purple_buddy_get_alias_only(PurpleBuddy *buddy);
3.645 -
3.646 -/**
3.647 - * Gets the server alias for a buddy.
3.648 - *
3.649 - * @param buddy The buddy whose name will be returned
3.650 - * @return The server alias, or NULL if it is not set.
3.651 - */
3.652 -const char *purple_buddy_get_server_alias(PurpleBuddy *buddy);
3.653 -
3.654 -/**
3.655 - * Returns the correct name to display for a buddy, taking the contact alias
3.656 - * into account. In order of precedence: the buddy's alias; the buddy's
3.657 - * contact alias; the buddy's server alias; the buddy's user name.
3.658 - *
3.659 - * @param buddy The buddy whose name will be returned
3.660 - * @return The appropriate name or alias, or NULL.
3.661 - *
3.662 - */
3.663 -const char *purple_buddy_get_contact_alias(PurpleBuddy *buddy);
3.664 -
3.665 -/**
3.666 - * Returns the correct alias for this user, ignoring server aliases. Used
3.667 - * when a user-recognizable name is required. In order: buddy's alias; buddy's
3.668 - * contact alias; buddy's user name.
3.669 - *
3.670 - * @param buddy The buddy whose alias will be returned.
3.671 - * @return The appropriate name or alias.
3.672 - */
3.673 -const char *purple_buddy_get_local_alias(PurpleBuddy *buddy);
3.674 -
3.675 -/**
3.676 - * Returns the correct name to display for a buddy. In order of precedence:
3.677 - * the buddy's alias; the buddy's server alias; the buddy's contact alias;
3.678 - * the buddy's user name.
3.679 - *
3.680 - * @param buddy The buddy whose name will be returned.
3.681 - * @return The appropriate name or alias, or NULL
3.682 - */
3.683 -const char *purple_buddy_get_alias(PurpleBuddy *buddy);
3.684 -
3.685 -/**
3.686 - * Returns the correct name to display for a blist chat.
3.687 - *
3.688 - * @param chat The chat whose name will be returned.
3.689 - * @return The alias (if set), or first component value.
3.690 - */
3.691 -const char *purple_chat_get_name(PurpleChat *chat);
3.692 -
3.693 -/**
3.694 - * Finds the buddy struct given a screenname and an account
3.695 - *
3.696 - * @param account The account this buddy belongs to
3.697 - * @param name The buddy's screenname
3.698 - * @return The buddy or NULL if the buddy does not exist
3.699 - */
3.700 -PurpleBuddy *purple_find_buddy(PurpleAccount *account, const char *name);
3.701 -
3.702 -/**
3.703 - * Finds the buddy struct given a screenname, an account, and a group
3.704 - *
3.705 - * @param account The account this buddy belongs to
3.706 - * @param name The buddy's screenname
3.707 - * @param group The group to look in
3.708 - * @return The buddy or NULL if the buddy does not exist in the group
3.709 - */
3.710 -PurpleBuddy *purple_find_buddy_in_group(PurpleAccount *account, const char *name,
3.711 - PurpleGroup *group);
3.712 -
3.713 -/**
3.714 - * Finds all PurpleBuddy structs given a screenname and an account
3.715 - *
3.716 - * @param account The account this buddy belongs to
3.717 - * @param name The buddy's screenname (or NULL to return all buddies in the account)
3.718 - *
3.719 - * @return A GSList of buddies (which must be freed), or NULL if the buddy doesn't exist
3.720 - */
3.721 -GSList *purple_find_buddies(PurpleAccount *account, const char *name);
3.722 -
3.723 -
3.724 -/**
3.725 - * Finds a group by name
3.726 - *
3.727 - * @param name The group's name
3.728 - * @return The group or NULL if the group does not exist
3.729 - */
3.730 -PurpleGroup *purple_find_group(const char *name);
3.731 -
3.732 -/**
3.733 - * Finds a chat by name.
3.734 - *
3.735 - * @param account The chat's account.
3.736 - * @param name The chat's name.
3.737 - *
3.738 - * @return The chat, or @c NULL if the chat does not exist.
3.739 - */
3.740 -PurpleChat *purple_blist_find_chat(PurpleAccount *account, const char *name);
3.741 -
3.742 -/**
3.743 - * Returns the group of which the chat is a member.
3.744 - *
3.745 - * @param chat The chat.
3.746 - *
3.747 - * @return The parent group, or @c NULL if the chat is not in a group.
3.748 - */
3.749 -PurpleGroup *purple_chat_get_group(PurpleChat *chat);
3.750 -
3.751 -/**
3.752 - * Returns the account the chat belongs to.
3.753 - *
3.754 - * @param chat The chat.
3.755 - *
3.756 - * @return The account the chat belongs to.
3.757 - * @since 2.4.0
3.758 - */
3.759 -PurpleAccount *purple_chat_get_account(PurpleChat *chat);
3.760 -
3.761 -/**
3.762 - * Get a hashtable containing information about a chat.
3.763 - *
3.764 - * @param chat The chat.
3.765 - *
3.766 - * @constreturn The hashtable.
3.767 - * @since 2.4.0
3.768 - */
3.769 -GHashTable *purple_chat_get_components(PurpleChat *chat);
3.770 -
3.771 -/**
3.772 - * Returns the group of which the buddy is a member.
3.773 - *
3.774 - * @param buddy The buddy
3.775 - * @return The group or NULL if the buddy is not in a group
3.776 - */
3.777 -PurpleGroup *purple_buddy_get_group(PurpleBuddy *buddy);
3.778 -
3.779 -
3.780 -/**
3.781 - * Returns a list of accounts that have buddies in this group
3.782 - *
3.783 - * @param g The group
3.784 - *
3.785 - * @return A GSList of accounts (which must be freed), or NULL if the group
3.786 - * has no accounts.
3.787 - */
3.788 -GSList *purple_group_get_accounts(PurpleGroup *g);
3.789 -
3.790 -/**
3.791 - * Determines whether an account owns any buddies in a given group
3.792 - *
3.793 - * @param g The group to search through.
3.794 - * @param account The account.
3.795 - *
3.796 - * @return TRUE if there are any buddies in the group, or FALSE otherwise.
3.797 - */
3.798 -gboolean purple_group_on_account(PurpleGroup *g, PurpleAccount *account);
3.799 -
3.800 -/**
3.801 - * Returns the name of a group.
3.802 - *
3.803 - * @param group The group.
3.804 - *
3.805 - * @return The name of the group.
3.806 - */
3.807 -const char *purple_group_get_name(PurpleGroup *group);
3.808 -
3.809 -/**
3.810 - * Called when an account gets signed on. Tells the UI to update all the
3.811 - * buddies.
3.812 - *
3.813 - * @param account The account
3.814 - */
3.815 -void purple_blist_add_account(PurpleAccount *account);
3.816 -
3.817 -
3.818 -/**
3.819 - * Called when an account gets signed off. Sets the presence of all the buddies to 0
3.820 - * and tells the UI to update them.
3.821 - *
3.822 - * @param account The account
3.823 - */
3.824 -void purple_blist_remove_account(PurpleAccount *account);
3.825 -
3.826 -
3.827 -/**
3.828 - * Determines the total size of a group
3.829 - *
3.830 - * @param group The group
3.831 - * @param offline Count buddies in offline accounts
3.832 - * @return The number of buddies in the group
3.833 - */
3.834 -int purple_blist_get_group_size(PurpleGroup *group, gboolean offline);
3.835 -
3.836 -/**
3.837 - * Determines the number of online buddies in a group
3.838 - *
3.839 - * @param group The group
3.840 - * @return The number of online buddies in the group, or 0 if the group is NULL
3.841 - */
3.842 -int purple_blist_get_group_online_count(PurpleGroup *group);
3.843 -
3.844 -/*@}*/
3.845 -
3.846 -/****************************************************************************************/
3.847 -/** @name Buddy list file management API */
3.848 -/****************************************************************************************/
3.849 -
3.850 -/**
3.851 - * Loads the buddy list from ~/.purple/blist.xml.
3.852 - */
3.853 -void purple_blist_load(void);
3.854 -
3.855 -/**
3.856 - * Schedule a save of the blist.xml file. This is used by the privacy
3.857 - * API whenever the privacy settings are changed. If you make a change
3.858 - * to blist.xml using one of the functions in the buddy list API, then
3.859 - * the buddy list is saved automatically, so you should not need to
3.860 - * call this.
3.861 - */
3.862 -void purple_blist_schedule_save(void);
3.863 -
3.864 -/**
3.865 - * Requests from the user information needed to add a buddy to the
3.866 - * buddy list.
3.867 - *
3.868 - * @param account The account the buddy is added to.
3.869 - * @param username The username of the buddy.
3.870 - * @param group The name of the group to place the buddy in.
3.871 - * @param alias The optional alias for the buddy.
3.872 - */
3.873 -void purple_blist_request_add_buddy(PurpleAccount *account, const char *username,
3.874 - const char *group, const char *alias);
3.875 -
3.876 -/**
3.877 - * Requests from the user information needed to add a chat to the
3.878 - * buddy list.
3.879 - *
3.880 - * @param account The account the buddy is added to.
3.881 - * @param group The optional group to add the chat to.
3.882 - * @param alias The optional alias for the chat.
3.883 - * @param name The required chat name.
3.884 - */
3.885 -void purple_blist_request_add_chat(PurpleAccount *account, PurpleGroup *group,
3.886 - const char *alias, const char *name);
3.887 -
3.888 -/**
3.889 - * Requests from the user information needed to add a group to the
3.890 - * buddy list.
3.891 - */
3.892 -void purple_blist_request_add_group(void);
3.893 -
3.894 -/**
3.895 - * Associates a boolean with a node in the buddy list
3.896 - *
3.897 - * @param node The node to associate the data with
3.898 - * @param key The identifier for the data
3.899 - * @param value The value to set
3.900 - */
3.901 -void purple_blist_node_set_bool(PurpleBlistNode *node, const char *key, gboolean value);
3.902 -
3.903 -/**
3.904 - * Retrieves a named boolean setting from a node in the buddy list
3.905 - *
3.906 - * @param node The node to retrieve the data from
3.907 - * @param key The identifier of the data
3.908 - *
3.909 - * @return The value, or FALSE if there is no setting
3.910 - */
3.911 -gboolean purple_blist_node_get_bool(PurpleBlistNode *node, const char *key);
3.912 -
3.913 -/**
3.914 - * Associates an integer with a node in the buddy list
3.915 - *
3.916 - * @param node The node to associate the data with
3.917 - * @param key The identifier for the data
3.918 - * @param value The value to set
3.919 - */
3.920 -void purple_blist_node_set_int(PurpleBlistNode *node, const char *key, int value);
3.921 -
3.922 -/**
3.923 - * Retrieves a named integer setting from a node in the buddy list
3.924 - *
3.925 - * @param node The node to retrieve the data from
3.926 - * @param key The identifier of the data
3.927 - *
3.928 - * @return The value, or 0 if there is no setting
3.929 - */
3.930 -int purple_blist_node_get_int(PurpleBlistNode *node, const char *key);
3.931 -
3.932 -/**
3.933 - * Associates a string with a node in the buddy list
3.934 - *
3.935 - * @param node The node to associate the data with
3.936 - * @param key The identifier for the data
3.937 - * @param value The value to set
3.938 - */
3.939 -void purple_blist_node_set_string(PurpleBlistNode *node, const char *key,
3.940 - const char *value);
3.941 -
3.942 -/**
3.943 - * Retrieves a named string setting from a node in the buddy list
3.944 - *
3.945 - * @param node The node to retrieve the data from
3.946 - * @param key The identifier of the data
3.947 - *
3.948 - * @return The value, or NULL if there is no setting
3.949 - */
3.950 -const char *purple_blist_node_get_string(PurpleBlistNode *node, const char *key);
3.951 -
3.952 -/**
3.953 - * Removes a named setting from a blist node
3.954 - *
3.955 - * @param node The node from which to remove the setting
3.956 - * @param key The name of the setting
3.957 - */
3.958 -void purple_blist_node_remove_setting(PurpleBlistNode *node, const char *key);
3.959 -
3.960 -/**
3.961 - * Set the flags for the given node. Setting a node's flags will overwrite
3.962 - * the old flags, so if you want to save them, you must first call
3.963 - * purple_blist_node_get_flags and modify that appropriately.
3.964 - *
3.965 - * @param node The node on which to set the flags.
3.966 - * @param flags The flags to set. This is a bitmask.
3.967 - */
3.968 -void purple_blist_node_set_flags(PurpleBlistNode *node, PurpleBlistNodeFlags flags);
3.969 -
3.970 -/**
3.971 - * Get the current flags on a given node.
3.972 - *
3.973 - * @param node The node from which to get the flags.
3.974 - *
3.975 - * @return The flags on the node. This is a bitmask.
3.976 - */
3.977 -PurpleBlistNodeFlags purple_blist_node_get_flags(PurpleBlistNode *node);
3.978 -
3.979 -/**
3.980 - * Get the type of a given node.
3.981 - *
3.982 - * @param node The node.
3.983 - *
3.984 - * @return The type of the node.
3.985 - * @since 2.1.0
3.986 - */
3.987 -PurpleBlistNodeType purple_blist_node_get_type(PurpleBlistNode *node);
3.988 -
3.989 -/*@}*/
3.990 -
3.991 -/**
3.992 - * Retrieves the extended menu items for a buddy list node.
3.993 - * @param n The blist node for which to obtain the extended menu items.
3.994 - * @return A list of PurpleMenuAction items, as harvested by the
3.995 - * blist-node-extended-menu signal.
3.996 - */
3.997 -GList *purple_blist_node_get_extended_menu(PurpleBlistNode *n);
3.998 -
3.999 -/**************************************************************************/
3.1000 -/** @name UI Registration Functions */
3.1001 -/**************************************************************************/
3.1002 -/*@{*/
3.1003 -
3.1004 -/**
3.1005 - * Sets the UI operations structure to be used for the buddy list.
3.1006 - *
3.1007 - * @param ops The ops struct.
3.1008 - */
3.1009 -void purple_blist_set_ui_ops(PurpleBlistUiOps *ops);
3.1010 -
3.1011 -/**
3.1012 - * Returns the UI operations structure to be used for the buddy list.
3.1013 - *
3.1014 - * @return The UI operations structure.
3.1015 - */
3.1016 -PurpleBlistUiOps *purple_blist_get_ui_ops(void);
3.1017 -
3.1018 -/*@}*/
3.1019 -
3.1020 -/**************************************************************************/
3.1021 -/** @name Buddy List Subsystem */
3.1022 -/**************************************************************************/
3.1023 -/*@{*/
3.1024 -
3.1025 -/**
3.1026 - * Returns the handle for the buddy list subsystem.
3.1027 - *
3.1028 - * @return The buddy list subsystem handle.
3.1029 - */
3.1030 -void *purple_blist_get_handle(void);
3.1031 -
3.1032 -/**
3.1033 - * Initializes the buddy list subsystem.
3.1034 - */
3.1035 -void purple_blist_init(void);
3.1036 -
3.1037 -/**
3.1038 - * Uninitializes the buddy list subsystem.
3.1039 - */
3.1040 -void purple_blist_uninit(void);
3.1041 -
3.1042 -/*@}*/
3.1043 -
3.1044 -#ifdef __cplusplus
3.1045 -}
3.1046 -#endif
3.1047 -
3.1048 -#endif /* _PURPLE_BLIST_H_ */
4.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/buddy.h Sun Jun 21 22:04:11 2009 -0400
4.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
4.3 @@ -1,124 +0,0 @@
4.4 -/**
4.5 - * @file buddy.h Buddy handlers
4.6 - *
4.7 - * purple
4.8 - *
4.9 - * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
4.10 - *
4.11 - * This program is free software; you can redistribute it and/or modify
4.12 - * it under the terms of the GNU General Public License as published by
4.13 - * the Free Software Foundation; either version 2 of the License, or
4.14 - * (at your option) any later version.
4.15 - *
4.16 - * This program is distributed in the hope that it will be useful,
4.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
4.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
4.19 - * GNU General Public License for more details.
4.20 - *
4.21 - * You should have received a copy of the GNU General Public License
4.22 - * along with this program; if not, write to the Free Software
4.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
4.24 - */
4.25 -#ifndef _PURPLE_JABBER_BUDDY_H_
4.26 -#define _PURPLE_JABBER_BUDDY_H_
4.27 -
4.28 -typedef enum {
4.29 - JABBER_BUDDY_STATE_UNKNOWN = -2,
4.30 - JABBER_BUDDY_STATE_ERROR = -1,
4.31 - JABBER_BUDDY_STATE_UNAVAILABLE = 0,
4.32 - JABBER_BUDDY_STATE_ONLINE,
4.33 - JABBER_BUDDY_STATE_CHAT,
4.34 - JABBER_BUDDY_STATE_AWAY,
4.35 - JABBER_BUDDY_STATE_XA,
4.36 - JABBER_BUDDY_STATE_DND
4.37 -} JabberBuddyState;
4.38 -
4.39 -#include "jabber.h"
4.40 -#include "caps.h"
4.41 -
4.42 -#define AVATARNAMESPACEDATA "http://www.xmpp.org/extensions/xep-0084.html#ns-data"
4.43 -#define AVATARNAMESPACEMETA "http://www.xmpp.org/extensions/xep-0084.html#ns-metadata"
4.44 -
4.45 -typedef struct _JabberBuddy {
4.46 - GList *resources;
4.47 - char *error_msg;
4.48 - enum {
4.49 - JABBER_INVISIBLE_NONE = 0,
4.50 - JABBER_INVISIBLE_SERVER = 1 << 1,
4.51 - JABBER_INVIS_BUDDY = 1 << 2
4.52 - } invisible;
4.53 - enum {
4.54 - JABBER_SUB_NONE = 0,
4.55 - JABBER_SUB_PENDING = 1 << 1,
4.56 - JABBER_SUB_TO = 1 << 2,
4.57 - JABBER_SUB_FROM = 1 << 3,
4.58 - JABBER_SUB_BOTH = (JABBER_SUB_TO | JABBER_SUB_FROM),
4.59 - JABBER_SUB_REMOVE = 1 << 4
4.60 - } subscription;
4.61 -} JabberBuddy;
4.62 -
4.63 -typedef struct _JabberAdHocCommands {
4.64 - char *jid;
4.65 - char *node;
4.66 - char *name;
4.67 -} JabberAdHocCommands;
4.68 -
4.69 -typedef struct _JabberBuddyResource {
4.70 - JabberBuddy *jb;
4.71 - char *name;
4.72 - int priority;
4.73 - JabberBuddyState state;
4.74 - char *status;
4.75 - JabberCapabilities capabilities;
4.76 - char *thread_id;
4.77 - enum {
4.78 - JABBER_CHAT_STATES_UNKNOWN,
4.79 - JABBER_CHAT_STATES_UNSUPPORTED,
4.80 - JABBER_CHAT_STATES_SUPPORTED
4.81 - } chat_states;
4.82 - struct {
4.83 - char *version;
4.84 - char *name;
4.85 - char *os;
4.86 - } client;
4.87 - JabberCapsClientInfo *caps;
4.88 - GList *commands;
4.89 -} JabberBuddyResource;
4.90 -
4.91 -void jabber_buddy_free(JabberBuddy *jb);
4.92 -JabberBuddy *jabber_buddy_find(JabberStream *js, const char *name,
4.93 - gboolean create);
4.94 -JabberBuddyResource *jabber_buddy_find_resource(JabberBuddy *jb,
4.95 - const char *resource);
4.96 -JabberBuddyResource *jabber_buddy_track_resource(JabberBuddy *jb, const char *resource,
4.97 - int priority, JabberBuddyState state, const char *status);
4.98 -void jabber_buddy_resource_free(JabberBuddyResource *jbr);
4.99 -void jabber_buddy_remove_resource(JabberBuddy *jb, const char *resource);
4.100 -const char *jabber_buddy_get_status_msg(JabberBuddy *jb);
4.101 -void jabber_buddy_get_info(PurpleConnection *gc, const char *who);
4.102 -
4.103 -GList *jabber_blist_node_menu(PurpleBlistNode *node);
4.104 -
4.105 -void jabber_set_info(PurpleConnection *gc, const char *info);
4.106 -void jabber_setup_set_info(PurplePluginAction *action);
4.107 -void jabber_set_buddy_icon(PurpleConnection *gc, PurpleStoredImage *img);
4.108 -void jabber_buddy_avatar_update_metadata(JabberStream *js, const char *from, xmlnode *items);
4.109 -
4.110 -const char *jabber_buddy_state_get_name(JabberBuddyState state);
4.111 -const char *jabber_buddy_state_get_status_id(JabberBuddyState state);
4.112 -const char *jabber_buddy_state_get_show(JabberBuddyState state);
4.113 -JabberBuddyState jabber_buddy_status_id_get_state(const char *id);
4.114 -JabberBuddyState jabber_buddy_show_get_state(const char *id);
4.115 -
4.116 -void jabber_user_search(JabberStream *js, const char *directory);
4.117 -void jabber_user_search_begin(PurplePluginAction *);
4.118 -
4.119 -void jabber_buddy_remove_all_pending_buddy_info_requests(JabberStream *js);
4.120 -
4.121 -void jabber_vcard_fetch_mine(JabberStream *js);
4.122 -
4.123 -gboolean jabber_resource_has_capability(const JabberBuddyResource *jbr,
4.124 - const gchar *cap);
4.125 -gboolean jabber_buddy_has_capability(const JabberBuddy *jb, const gchar *cap);
4.126 -
4.127 -#endif /* _PURPLE_JABBER_BUDDY_H_ */
5.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/buddyicon.h Sun Jun 21 22:04:11 2009 -0400
5.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
5.3 @@ -1,443 +0,0 @@
5.4 -/**
5.5 - * @file buddyicon.h Buddy Icon API
5.6 - * @ingroup core
5.7 - */
5.8 -
5.9 -/* purple
5.10 - *
5.11 - * Purple is the legal property of its developers, whose names are too numerous
5.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
5.13 - * source distribution.
5.14 - *
5.15 - * This program is free software; you can redistribute it and/or modify
5.16 - * it under the terms of the GNU General Public License as published by
5.17 - * the Free Software Foundation; either version 2 of the License, or
5.18 - * (at your option) any later version.
5.19 - *
5.20 - * This program is distributed in the hope that it will be useful,
5.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
5.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
5.23 - * GNU General Public License for more details.
5.24 - *
5.25 - * You should have received a copy of the GNU General Public License
5.26 - * along with this program; if not, write to the Free Software
5.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
5.28 - */
5.29 -#ifndef _PURPLE_BUDDYICON_H_
5.30 -#define _PURPLE_BUDDYICON_H_
5.31 -
5.32 -/** An opaque structure representing a buddy icon for a particular user on a
5.33 - * particular #PurpleAccount. Instances are reference-counted; use
5.34 - * purple_buddy_icon_ref() and purple_buddy_icon_unref() to take and release
5.35 - * references.
5.36 - */
5.37 -typedef struct _PurpleBuddyIcon PurpleBuddyIcon;
5.38 -
5.39 -#include "account.h"
5.40 -#include "blist.h"
5.41 -#include "imgstore.h"
5.42 -#include "prpl.h"
5.43 -#include "util.h"
5.44 -
5.45 -#ifdef __cplusplus
5.46 -extern "C" {
5.47 -#endif
5.48 -
5.49 -
5.50 -/**************************************************************************/
5.51 -/** @name Buddy Icon API */
5.52 -/**************************************************************************/
5.53 -/*@{*/
5.54 -
5.55 -/**
5.56 - * Creates a new buddy icon structure and populates it.
5.57 - *
5.58 - * If the buddy icon already exists, you'll get a reference to that structure,
5.59 - * which will have been updated with the data supplied.
5.60 - *
5.61 - * @param account The account the user is on.
5.62 - * @param username The username the icon belongs to.
5.63 - * @param icon_data The buddy icon data.
5.64 - * @param icon_len The buddy icon length.
5.65 - * @param checksum A protocol checksum from the prpl or @c NULL.
5.66 - *
5.67 - * @return The buddy icon structure, with a reference for the caller.
5.68 - */
5.69 -PurpleBuddyIcon *purple_buddy_icon_new(PurpleAccount *account, const char *username,
5.70 - void *icon_data, size_t icon_len,
5.71 - const char *checksum);
5.72 -
5.73 -/**
5.74 - * Increments the reference count on a buddy icon.
5.75 - *
5.76 - * @param icon The buddy icon.
5.77 - *
5.78 - * @return @a icon.
5.79 - */
5.80 -PurpleBuddyIcon *purple_buddy_icon_ref(PurpleBuddyIcon *icon);
5.81 -
5.82 -/**
5.83 - * Decrements the reference count on a buddy icon.
5.84 - *
5.85 - * If the reference count reaches 0, the icon will be destroyed.
5.86 - *
5.87 - * @param icon The buddy icon.
5.88 - *
5.89 - * @return @a icon, or @c NULL if the reference count reached 0.
5.90 - */
5.91 -PurpleBuddyIcon *purple_buddy_icon_unref(PurpleBuddyIcon *icon);
5.92 -
5.93 -/**
5.94 - * Updates every instance of this icon.
5.95 - *
5.96 - * @param icon The buddy icon.
5.97 - */
5.98 -void purple_buddy_icon_update(PurpleBuddyIcon *icon);
5.99 -
5.100 -/**
5.101 - * Sets the buddy icon's data.
5.102 - *
5.103 - * @param icon The buddy icon.
5.104 - * @param data The buddy icon data, which the buddy icon code
5.105 - * takes ownership of and will free.
5.106 - * @param len The length of the data in @a data.
5.107 - * @param checksum A protocol checksum from the prpl or @c NULL.
5.108 - */
5.109 -void
5.110 -purple_buddy_icon_set_data(PurpleBuddyIcon *icon, guchar *data,
5.111 - size_t len, const char *checksum);
5.112 -
5.113 -/**
5.114 - * Returns the buddy icon's account.
5.115 - *
5.116 - * @param icon The buddy icon.
5.117 - *
5.118 - * @return The account.
5.119 - */
5.120 -PurpleAccount *purple_buddy_icon_get_account(const PurpleBuddyIcon *icon);
5.121 -
5.122 -/**
5.123 - * Returns the buddy icon's username.
5.124 - *
5.125 - * @param icon The buddy icon.
5.126 - *
5.127 - * @return The username.
5.128 - */
5.129 -const char *purple_buddy_icon_get_username(const PurpleBuddyIcon *icon);
5.130 -
5.131 -/**
5.132 - * Returns the buddy icon's checksum.
5.133 - *
5.134 - * This function is really only for prpl use.
5.135 - *
5.136 - * @param icon The buddy icon.
5.137 - *
5.138 - * @return The checksum.
5.139 - */
5.140 -const char *purple_buddy_icon_get_checksum(const PurpleBuddyIcon *icon);
5.141 -
5.142 -/**
5.143 - * Returns the buddy icon's data.
5.144 - *
5.145 - * @param icon The buddy icon.
5.146 - * @param len If not @c NULL, the length of the icon data returned will be
5.147 - * set in the location pointed to by this.
5.148 - *
5.149 - * @return A pointer to the icon data.
5.150 - */
5.151 -gconstpointer purple_buddy_icon_get_data(const PurpleBuddyIcon *icon, size_t *len);
5.152 -
5.153 -/**
5.154 - * Returns an extension corresponding to the buddy icon's file type.
5.155 - *
5.156 - * @param icon The buddy icon.
5.157 - *
5.158 - * @return The icon's extension, "icon" if unknown, or @c NULL if
5.159 - * the image data has disappeared.
5.160 - */
5.161 -const char *purple_buddy_icon_get_extension(const PurpleBuddyIcon *icon);
5.162 -
5.163 -/**
5.164 - * Returns a full path to an icon.
5.165 - *
5.166 - * If the icon has data and the file exists in the cache, this will return
5.167 - * a full path to the cache file.
5.168 - *
5.169 - * In general, it is not appropriate to be poking in the icon cache
5.170 - * directly. If you find yourself wanting to use this function, think
5.171 - * very long and hard about it, and then don't.
5.172 - *
5.173 - * @param icon The buddy icon
5.174 - *
5.175 - * @return A full path to the file, or @c NULL under various conditions.
5.176 - */
5.177 -char *purple_buddy_icon_get_full_path(PurpleBuddyIcon *icon);
5.178 -
5.179 -/*@}*/
5.180 -
5.181 -/**************************************************************************/
5.182 -/** @name Buddy Icon Subsystem API */
5.183 -/**************************************************************************/
5.184 -/*@{*/
5.185 -
5.186 -/**
5.187 - * Sets a buddy icon for a user.
5.188 - *
5.189 - * @param account The account the user is on.
5.190 - * @param username The username of the user.
5.191 - * @param icon_data The buddy icon data, which the buddy icon code
5.192 - * takes ownership of and will free.
5.193 - * @param icon_len The length of the icon data.
5.194 - * @param checksum A protocol checksum from the prpl or @c NULL.
5.195 - *
5.196 - * @return The buddy icon set, or NULL if no icon was set.
5.197 - */
5.198 -void
5.199 -purple_buddy_icons_set_for_user(PurpleAccount *account, const char *username,
5.200 - void *icon_data, size_t icon_len,
5.201 - const char *checksum);
5.202 -
5.203 -/**
5.204 - * Returns the checksum for the buddy icon of a specified buddy.
5.205 - *
5.206 - * This avoids loading the icon image data from the cache if it's
5.207 - * not already loaded for some other reason.
5.208 - *
5.209 - * @param buddy The buddy
5.210 - *
5.211 - * @return The checksum.
5.212 - */
5.213 -const char *
5.214 -purple_buddy_icons_get_checksum_for_user(PurpleBuddy *buddy);
5.215 -
5.216 -/**
5.217 - * Returns the buddy icon information for a user.
5.218 - *
5.219 - * @param account The account the user is on.
5.220 - * @param username The username of the user.
5.221 - *
5.222 - * @return The icon (with a reference for the caller) if found, or @c NULL if
5.223 - * not found.
5.224 - */
5.225 -PurpleBuddyIcon *
5.226 -purple_buddy_icons_find(PurpleAccount *account, const char *username);
5.227 -
5.228 -/**
5.229 - * Returns the buddy icon image for an account.
5.230 - *
5.231 - * The caller owns a reference to the image in the store, and must dereference
5.232 - * the image with purple_imgstore_unref() for it to be freed.
5.233 - *
5.234 - * This function deals with loading the icon from the cache, if
5.235 - * needed, so it should be called in any case where you want the
5.236 - * appropriate icon.
5.237 - *
5.238 - * @param account The account
5.239 - *
5.240 - * @return The account's buddy icon image.
5.241 - */
5.242 -PurpleStoredImage *
5.243 -purple_buddy_icons_find_account_icon(PurpleAccount *account);
5.244 -
5.245 -/**
5.246 - * Sets a buddy icon for an account.
5.247 - *
5.248 - * This function will deal with saving a record of the icon,
5.249 - * caching the data, etc.
5.250 - *
5.251 - * @param account The account for which to set a custom icon.
5.252 - * @param icon_data The image data of the icon, which the
5.253 - * buddy icon code will free.
5.254 - * @param icon_len The length of the data in @a icon_data.
5.255 - *
5.256 - * @return The icon that was set. The caller does NOT own
5.257 - * a reference to this, and must call purple_imgstore_ref()
5.258 - * if it wants one.
5.259 - */
5.260 -PurpleStoredImage *
5.261 -purple_buddy_icons_set_account_icon(PurpleAccount *account,
5.262 - guchar *icon_data, size_t icon_len);
5.263 -
5.264 -/**
5.265 - * Returns the timestamp of when the icon was set.
5.266 - *
5.267 - * This is intended for use in protocols that require a timestamp for
5.268 - * buddy icon update reasons.
5.269 - *
5.270 - * @param account The account
5.271 - *
5.272 - * @return The time the icon was set, or 0 if an error occurred.
5.273 - */
5.274 -time_t
5.275 -purple_buddy_icons_get_account_icon_timestamp(PurpleAccount *account);
5.276 -
5.277 -/**
5.278 - * Returns a boolean indicating if a given blist node has a custom buddy icon.
5.279 - *
5.280 - * @param node The blist node.
5.281 - *
5.282 - * @return A boolean indicating if @a node has a custom buddy icon.
5.283 - * @since 2.5.0
5.284 - */
5.285 -gboolean
5.286 -purple_buddy_icons_node_has_custom_icon(PurpleBlistNode *node);
5.287 -
5.288 -/**
5.289 - * Returns the custom buddy icon image for a blist node.
5.290 - *
5.291 - * The caller owns a reference to the image in the store, and must dereference
5.292 - * the image with purple_imgstore_unref() for it to be freed.
5.293 - *
5.294 - * This function deals with loading the icon from the cache, if
5.295 - * needed, so it should be called in any case where you want the
5.296 - * appropriate icon.
5.297 - *
5.298 - * @param node The node.
5.299 - *
5.300 - * @return The custom buddy icon.
5.301 - * @since 2.5.0
5.302 - */
5.303 -PurpleStoredImage *
5.304 -purple_buddy_icons_node_find_custom_icon(PurpleBlistNode *node);
5.305 -
5.306 -/**
5.307 - * Sets a custom buddy icon for a blist node.
5.308 - *
5.309 - * This function will deal with saving a record of the icon, caching the data,
5.310 - * etc.
5.311 - *
5.312 - * @param node The blist node for which to set a custom icon.
5.313 - * @param icon_data The image data of the icon, which the buddy icon code will
5.314 - * free. Use NULL to unset the icon.
5.315 - * @param icon_len The length of the data in @a icon_data.
5.316 - *
5.317 - * @return The icon that was set. The caller does NOT own a reference to this,
5.318 - * and must call purple_imgstore_ref() if it wants one.
5.319 - * @since 2.5.0
5.320 - */
5.321 -PurpleStoredImage *
5.322 -purple_buddy_icons_node_set_custom_icon(PurpleBlistNode *node,
5.323 - guchar *icon_data, size_t icon_len);
5.324 -
5.325 -/**
5.326 - * Sets a custom buddy icon for a blist node.
5.327 - *
5.328 - * Convenience wrapper around purple_buddy_icons_node_set_custom_icon.
5.329 - * @see purple_buddy_icons_node_set_custom_icon()
5.330 - *
5.331 - * @param node The blist node for which to set a custom icon.
5.332 - * @param filename The path to the icon to set for the blist node. Use NULL
5.333 - * to unset the custom icon.
5.334 - *
5.335 - * @return The icon that was set. The caller does NOT own a reference to this,
5.336 - * and must call purple_imgstore_ref() if it wants one.
5.337 - * @since 2.5.0
5.338 - */
5.339 -PurpleStoredImage *
5.340 -purple_buddy_icons_node_set_custom_icon_from_file(PurpleBlistNode *node,
5.341 - const gchar *filename);
5.342 -
5.343 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_BUDDYICON_C_)
5.344 -/**
5.345 - * PurpleContact version of purple_buddy_icons_node_has_custom_icon.
5.346 - *
5.347 - * @copydoc purple_buddy_icons_node_has_custom_icon()
5.348 - *
5.349 - * @deprecated Use purple_buddy_icons_node_has_custom_icon instead.
5.350 - */
5.351 -gboolean
5.352 -purple_buddy_icons_has_custom_icon(PurpleContact *contact);
5.353 -
5.354 -/**
5.355 - * PurpleContact version of purple_buddy_icons_node_find_custom_icon.
5.356 - *
5.357 - * @copydoc purple_buddy_icons_node_find_custom_icon()
5.358 - *
5.359 - * @deprecated Use purple_buddy_icons_node_find_custom_icon instead.
5.360 - */
5.361 -PurpleStoredImage *
5.362 -purple_buddy_icons_find_custom_icon(PurpleContact *contact);
5.363 -
5.364 -/**
5.365 - * PurpleContact version of purple_buddy_icons_node_set_custom_icon.
5.366 - *
5.367 - * @copydoc purple_buddy_icons_node_set_custom_icon()
5.368 - *
5.369 - * @deprecated Use purple_buddy_icons_node_set_custom_icon instead.
5.370 - */
5.371 -PurpleStoredImage *
5.372 -purple_buddy_icons_set_custom_icon(PurpleContact *contact,
5.373 - guchar *icon_data, size_t icon_len);
5.374 -#endif
5.375 -
5.376 -/**
5.377 - * Sets whether or not buddy icon caching is enabled.
5.378 - *
5.379 - * @param caching TRUE of buddy icon caching should be enabled, or
5.380 - * FALSE otherwise.
5.381 - */
5.382 -void purple_buddy_icons_set_caching(gboolean caching);
5.383 -
5.384 -/**
5.385 - * Returns whether or not buddy icon caching should be enabled.
5.386 - *
5.387 - * The default is TRUE, unless otherwise specified by
5.388 - * purple_buddy_icons_set_caching().
5.389 - *
5.390 - * @return TRUE if buddy icon caching is enabled, or FALSE otherwise.
5.391 - */
5.392 -gboolean purple_buddy_icons_is_caching(void);
5.393 -
5.394 -/**
5.395 - * Sets the directory used to store buddy icon cache files.
5.396 - *
5.397 - * @param cache_dir The directory to store buddy icon cache files to.
5.398 - */
5.399 -void purple_buddy_icons_set_cache_dir(const char *cache_dir);
5.400 -
5.401 -/**
5.402 - * Returns the directory used to store buddy icon cache files.
5.403 - *
5.404 - * The default directory is PURPLEDIR/icons, unless otherwise specified
5.405 - * by purple_buddy_icons_set_cache_dir().
5.406 - *
5.407 - * @return The directory to store buddy icon cache files to.
5.408 - */
5.409 -const char *purple_buddy_icons_get_cache_dir(void);
5.410 -
5.411 -/**
5.412 - * Returns the buddy icon subsystem handle.
5.413 - *
5.414 - * @return The subsystem handle.
5.415 - */
5.416 -void *purple_buddy_icons_get_handle(void);
5.417 -
5.418 -/**
5.419 - * Initializes the buddy icon subsystem.
5.420 - */
5.421 -void purple_buddy_icons_init(void);
5.422 -
5.423 -/**
5.424 - * Uninitializes the buddy icon subsystem.
5.425 - */
5.426 -void purple_buddy_icons_uninit(void);
5.427 -
5.428 -/*@}*/
5.429 -
5.430 -/**************************************************************************/
5.431 -/** @name Buddy Icon Helper API */
5.432 -/**************************************************************************/
5.433 -/*@{*/
5.434 -
5.435 -/**
5.436 - * Gets display size for a buddy icon
5.437 - */
5.438 -void purple_buddy_icon_get_scale_size(PurpleBuddyIconSpec *spec, int *width, int *height);
5.439 -
5.440 -/*@}*/
5.441 -
5.442 -#ifdef __cplusplus
5.443 -}
5.444 -#endif
5.445 -
5.446 -#endif /* _PURPLE_BUDDYICON_H_ */
6.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/buddylist.h Sun Jun 21 22:04:11 2009 -0400
6.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
6.3 @@ -1,65 +0,0 @@
6.4 -/**
6.5 - * @file buddylist.h
6.6 - *
6.7 - * purple
6.8 - *
6.9 - * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
6.10 - *
6.11 - * This program is free software; you can redistribute it and/or modify
6.12 - * it under the terms of the GNU General Public License as published by
6.13 - * the Free Software Foundation; either version 2 of the License, or
6.14 - * (at your option) any later version.
6.15 - *
6.16 - * This program is distributed in the hope that it will be useful,
6.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
6.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
6.19 - * GNU General Public License for more details.
6.20 - *
6.21 - * You should have received a copy of the GNU General Public License
6.22 - * along with this program; if not, write to the Free Software
6.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
6.24 - */
6.25 -
6.26 -
6.27 -#ifndef _PURPLE_GG_BUDDYLIST_H
6.28 -#define _PURPLE_GG_BUDDYLIST_H
6.29 -
6.30 -#include "connection.h"
6.31 -#include "account.h"
6.32 -
6.33 -void
6.34 -ggp_buddylist_send(PurpleConnection *gc);
6.35 -
6.36 -/**
6.37 - * Load buddylist from server into the rooster.
6.38 - *
6.39 - * @param gc PurpleConnection
6.40 - * @param buddylist Pointer to the buddylist that will be loaded.
6.41 - */
6.42 -/* void ggp_buddylist_load(PurpleConnection *gc, char *buddylist) {{{ */
6.43 -void
6.44 -ggp_buddylist_load(PurpleConnection *gc, char *buddylist);
6.45 -
6.46 -/**
6.47 - * Set offline status for all buddies.
6.48 - *
6.49 - * @param gc Connection handler
6.50 - */
6.51 -void
6.52 -ggp_buddylist_offline(PurpleConnection *gc);
6.53 -
6.54 -/**
6.55 - * Get all the buddies in the current account.
6.56 - *
6.57 - * @param account Current account.
6.58 - *
6.59 - * @return List of buddies.
6.60 - */
6.61 -char *
6.62 -ggp_buddylist_dump(PurpleAccount *account);
6.63 -
6.64 -
6.65 -#endif /* _PURPLE_GG_BUDDYLIST_H */
6.66 -
6.67 -
6.68 -/* vim: set ts=8 sts=0 sw=8 noet: */
7.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/caps.h Sun Jun 21 22:04:11 2009 -0400
7.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
7.3 @@ -1,49 +0,0 @@
7.4 -/*
7.5 - * purple - Jabber Protocol Plugin
7.6 - *
7.7 - * Copyright (C) 2007, Andreas Monitzer <andy@monitzer.com>
7.8 - *
7.9 - * This program is free software; you can redistribute it and/or modify
7.10 - * it under the terms of the GNU General Public License as published by
7.11 - * the Free Software Foundation; either version 2 of the License, or
7.12 - * (at your option) any later version.
7.13 - *
7.14 - * This program is distributed in the hope that it will be useful,
7.15 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
7.16 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
7.17 - * GNU General Public License for more details.
7.18 - *
7.19 - * You should have received a copy of the GNU General Public License
7.20 - * along with this program; if not, write to the Free Software
7.21 - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
7.22 - *
7.23 - */
7.24 -
7.25 -#ifndef _PURPLE_JABBER_CAPS_H_
7.26 -#define _PURPLE_JABBER_CAPS_H_
7.27 -
7.28 -typedef struct _JabberCapsClientInfo JabberCapsClientInfo;
7.29 -
7.30 -#include "jabber.h"
7.31 -
7.32 -/* Implementation of XEP-0115 */
7.33 -
7.34 -typedef struct _JabberCapsIdentity {
7.35 - char *category;
7.36 - char *type;
7.37 - char *name;
7.38 -} JabberCapsIdentity;
7.39 -
7.40 -struct _JabberCapsClientInfo {
7.41 - GList *identities; /* JabberCapsIdentity */
7.42 - GList *features; /* char * */
7.43 -};
7.44 -
7.45 -typedef void (*jabber_caps_get_info_cb)(JabberCapsClientInfo *info, gpointer user_data);
7.46 -
7.47 -void jabber_caps_init(void);
7.48 -
7.49 -void jabber_caps_get_info(JabberStream *js, const char *who, const char *node, const char *ver, const char *ext, jabber_caps_get_info_cb cb, gpointer user_data);
7.50 -void jabber_caps_free_clientinfo(JabberCapsClientInfo *clientinfo);
7.51 -
7.52 -#endif /* _PURPLE_JABBER_CAPS_H_ */
8.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/certificate.h Sun Jun 21 22:04:11 2009 -0400
8.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
8.3 @@ -1,802 +0,0 @@
8.4 -/**
8.5 - * @file certificate.h Public-Key Certificate API
8.6 - * @ingroup core
8.7 - * @see @ref certificate-signals
8.8 - * @since 2.2.0
8.9 - */
8.10 -
8.11 -/*
8.12 - *
8.13 - * purple
8.14 - *
8.15 - * Purple is the legal property of its developers, whose names are too numerous
8.16 - * to list here. Please refer to the COPYRIGHT file distributed with this
8.17 - * source distribution.
8.18 - *
8.19 - * This program is free software; you can redistribute it and/or modify
8.20 - * it under the terms of the GNU General Public License as published by
8.21 - * the Free Software Foundation; either version 2 of the License, or
8.22 - * (at your option) any later version.
8.23 - *
8.24 - * This program is distributed in the hope that it will be useful,
8.25 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
8.26 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
8.27 - * GNU General Public License for more details.
8.28 - *
8.29 - * You should have received a copy of the GNU General Public License
8.30 - * along with this program; if not, write to the Free Software
8.31 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
8.32 - */
8.33 -
8.34 -#ifndef _PURPLE_CERTIFICATE_H
8.35 -#define _PURPLE_CERTIFICATE_H
8.36 -
8.37 -#include <time.h>
8.38 -
8.39 -#include <glib.h>
8.40 -
8.41 -#ifdef __cplusplus
8.42 -extern "C" {
8.43 -#endif /* __cplusplus */
8.44 -
8.45 -
8.46 -typedef enum
8.47 -{
8.48 - PURPLE_CERTIFICATE_INVALID = 0,
8.49 - PURPLE_CERTIFICATE_VALID = 1
8.50 -} PurpleCertificateVerificationStatus;
8.51 -
8.52 -typedef struct _PurpleCertificate PurpleCertificate;
8.53 -typedef struct _PurpleCertificatePool PurpleCertificatePool;
8.54 -typedef struct _PurpleCertificateScheme PurpleCertificateScheme;
8.55 -typedef struct _PurpleCertificateVerifier PurpleCertificateVerifier;
8.56 -typedef struct _PurpleCertificateVerificationRequest PurpleCertificateVerificationRequest;
8.57 -
8.58 -/**
8.59 - * Callback function for the results of a verification check
8.60 - * @param st Status code
8.61 - * @param userdata User-defined data
8.62 - */
8.63 -typedef void (*PurpleCertificateVerifiedCallback)
8.64 - (PurpleCertificateVerificationStatus st,
8.65 - gpointer userdata);
8.66 -
8.67 -/** A certificate instance
8.68 - *
8.69 - * An opaque data structure representing a single certificate under some
8.70 - * CertificateScheme
8.71 - */
8.72 -struct _PurpleCertificate
8.73 -{
8.74 - /** Scheme this certificate is under */
8.75 - PurpleCertificateScheme * scheme;
8.76 - /** Opaque pointer to internal data */
8.77 - gpointer data;
8.78 -};
8.79 -
8.80 -/**
8.81 - * Database for retrieval or storage of Certificates
8.82 - *
8.83 - * More or less a hash table; all lookups and writes are controlled by a string
8.84 - * key.
8.85 - */
8.86 -struct _PurpleCertificatePool
8.87 -{
8.88 - /** Scheme this Pool operates for */
8.89 - gchar *scheme_name;
8.90 - /** Internal name to refer to the pool by */
8.91 - gchar *name;
8.92 -
8.93 - /** User-friendly name for this type
8.94 - * ex: N_("SSL Servers")
8.95 - * When this is displayed anywhere, it should be i18ned
8.96 - * ex: _(pool->fullname)
8.97 - */
8.98 - gchar *fullname;
8.99 -
8.100 - /** Internal pool data */
8.101 - gpointer data;
8.102 -
8.103 - /**
8.104 - * Set up the Pool's internal state
8.105 - *
8.106 - * Upon calling purple_certificate_register_pool() , this function will
8.107 - * be called. May be NULL.
8.108 - * @return TRUE if the initialization succeeded, otherwise FALSE
8.109 - */
8.110 - gboolean (* init)(void);
8.111 -
8.112 - /**
8.113 - * Uninit the Pool's internal state
8.114 - *
8.115 - * Will be called by purple_certificate_unregister_pool() . May be NULL
8.116 - */
8.117 - void (* uninit)(void);
8.118 -
8.119 - /** Check for presence of a certificate in the pool using unique ID */
8.120 - gboolean (* cert_in_pool)(const gchar *id);
8.121 - /** Retrieve a PurpleCertificate from the pool */
8.122 - PurpleCertificate * (* get_cert)(const gchar *id);
8.123 - /** Add a certificate to the pool. Must overwrite any other
8.124 - * certificates sharing the same ID in the pool.
8.125 - * @return TRUE if the operation succeeded, otherwise FALSE
8.126 - */
8.127 - gboolean (* put_cert)(const gchar *id, PurpleCertificate *crt);
8.128 - /** Delete a certificate from the pool */
8.129 - gboolean (* delete_cert)(const gchar *id);
8.130 -
8.131 - /** Returns a list of IDs stored in the pool */
8.132 - GList * (* get_idlist)(void);
8.133 -
8.134 - void (*_purple_reserved1)(void);
8.135 - void (*_purple_reserved2)(void);
8.136 - void (*_purple_reserved3)(void);
8.137 - void (*_purple_reserved4)(void);
8.138 -};
8.139 -
8.140 -/** A certificate type
8.141 - *
8.142 - * A CertificateScheme must implement all of the fields in the structure,
8.143 - * and register it using purple_certificate_register_scheme()
8.144 - *
8.145 - * There may be only ONE CertificateScheme provided for each certificate
8.146 - * type, as specified by the "name" field.
8.147 - */
8.148 -struct _PurpleCertificateScheme
8.149 -{
8.150 - /** Name of the certificate type
8.151 - * ex: "x509", "pgp", etc.
8.152 - * This must be globally unique - you may not register more than one
8.153 - * CertificateScheme of the same name at a time.
8.154 - */
8.155 - gchar * name;
8.156 -
8.157 - /** User-friendly name for this type
8.158 - * ex: N_("X.509 Certificates")
8.159 - * When this is displayed anywhere, it should be i18ned
8.160 - * ex: _(scheme->fullname)
8.161 - */
8.162 - gchar * fullname;
8.163 -
8.164 - /** Imports a certificate from a file
8.165 - *
8.166 - * @param filename File to import the certificate from
8.167 - * @return Pointer to the newly allocated Certificate struct
8.168 - * or NULL on failure.
8.169 - */
8.170 - PurpleCertificate * (* import_certificate)(const gchar * filename);
8.171 -
8.172 - /**
8.173 - * Exports a certificate to a file
8.174 - *
8.175 - * @param filename File to export the certificate to
8.176 - * @param crt Certificate to export
8.177 - * @return TRUE if the export succeeded, otherwise FALSE
8.178 - * @see purple_certificate_export()
8.179 - */
8.180 - gboolean (* export_certificate)(const gchar *filename, PurpleCertificate *crt);
8.181 -
8.182 - /**
8.183 - * Duplicates a certificate
8.184 - *
8.185 - * Certificates are generally assumed to be read-only, so feel free to
8.186 - * do any sort of reference-counting magic you want here. If this ever
8.187 - * changes, please remember to change the magic accordingly.
8.188 - * @return Reference to the new copy
8.189 - */
8.190 - PurpleCertificate * (* copy_certificate)(PurpleCertificate *crt);
8.191 -
8.192 - /** Destroys and frees a Certificate structure
8.193 - *
8.194 - * Destroys a Certificate's internal data structures and calls
8.195 - * free(crt)
8.196 - *
8.197 - * @param crt Certificate instance to be destroyed. It WILL NOT be
8.198 - * destroyed if it is not of the correct
8.199 - * CertificateScheme. Can be NULL
8.200 - */
8.201 - void (* destroy_certificate)(PurpleCertificate * crt);
8.202 -
8.203 - /** Find whether "crt" has a valid signature from issuer "issuer"
8.204 - * @see purple_certificate_signed_by() */
8.205 - gboolean (*signed_by)(PurpleCertificate *crt, PurpleCertificate *issuer);
8.206 - /**
8.207 - * Retrieves the certificate public key fingerprint using SHA1
8.208 - *
8.209 - * @param crt Certificate instance
8.210 - * @return Binary representation of SHA1 hash - must be freed using
8.211 - * g_byte_array_free()
8.212 - */
8.213 - GByteArray * (* get_fingerprint_sha1)(PurpleCertificate *crt);
8.214 -
8.215 - /**
8.216 - * Retrieves a unique certificate identifier
8.217 - *
8.218 - * @param crt Certificate instance
8.219 - * @return Newly allocated string that can be used to uniquely
8.220 - * identify the certificate.
8.221 - */
8.222 - gchar * (* get_unique_id)(PurpleCertificate *crt);
8.223 -
8.224 - /**
8.225 - * Retrieves a unique identifier for the certificate's issuer
8.226 - *
8.227 - * @param crt Certificate instance
8.228 - * @return Newly allocated string that can be used to uniquely
8.229 - * identify the issuer's certificate.
8.230 - */
8.231 - gchar * (* get_issuer_unique_id)(PurpleCertificate *crt);
8.232 -
8.233 - /**
8.234 - * Gets the certificate subject's name
8.235 - *
8.236 - * For X.509, this is the "Common Name" field, as we're only using it
8.237 - * for hostname verification at the moment
8.238 - *
8.239 - * @see purple_certificate_get_subject_name()
8.240 - *
8.241 - * @param crt Certificate instance
8.242 - * @return Newly allocated string with the certificate subject.
8.243 - */
8.244 - gchar * (* get_subject_name)(PurpleCertificate *crt);
8.245 -
8.246 - /**
8.247 - * Check the subject name against that on the certificate
8.248 - * @see purple_certificate_check_subject_name()
8.249 - * @return TRUE if it is a match, else FALSE
8.250 - */
8.251 - gboolean (* check_subject_name)(PurpleCertificate *crt, const gchar *name);
8.252 -
8.253 - /** Retrieve the certificate activation/expiration times */
8.254 - gboolean (* get_times)(PurpleCertificate *crt, time_t *activation, time_t *expiration);
8.255 -
8.256 - void (*_purple_reserved1)(void);
8.257 - void (*_purple_reserved2)(void);
8.258 - void (*_purple_reserved3)(void);
8.259 - void (*_purple_reserved4)(void);
8.260 -};
8.261 -
8.262 -/** A set of operations used to provide logic for verifying a Certificate's
8.263 - * authenticity.
8.264 - *
8.265 - * A Verifier provider must fill out these fields, then register it using
8.266 - * purple_certificate_register_verifier()
8.267 - *
8.268 - * The (scheme_name, name) value must be unique for each Verifier - you may not
8.269 - * register more than one Verifier of the same name for each Scheme
8.270 - */
8.271 -struct _PurpleCertificateVerifier
8.272 -{
8.273 - /** Name of the scheme this Verifier operates on
8.274 - *
8.275 - * The scheme will be looked up by name when a Request is generated
8.276 - * using this Verifier
8.277 - */
8.278 - gchar *scheme_name;
8.279 -
8.280 - /** Name of the Verifier - case insensitive */
8.281 - gchar *name;
8.282 -
8.283 - /**
8.284 - * Start the verification process
8.285 - *
8.286 - * To be called from purple_certificate_verify once it has
8.287 - * constructed the request. This will use the information in the
8.288 - * given VerificationRequest to check the certificate and callback
8.289 - * the requester with the verification results.
8.290 - *
8.291 - * @param vrq Request to process
8.292 - */
8.293 - void (* start_verification)(PurpleCertificateVerificationRequest *vrq);
8.294 -
8.295 - /**
8.296 - * Destroy a completed Request under this Verifier
8.297 - * The function pointed to here is only responsible for cleaning up
8.298 - * whatever PurpleCertificateVerificationRequest::data points to.
8.299 - * It should not call free(vrq)
8.300 - *
8.301 - * @param vrq Request to destroy
8.302 - */
8.303 - void (* destroy_request)(PurpleCertificateVerificationRequest *vrq);
8.304 -
8.305 - void (*_purple_reserved1)(void);
8.306 - void (*_purple_reserved2)(void);
8.307 - void (*_purple_reserved3)(void);
8.308 - void (*_purple_reserved4)(void);
8.309 -};
8.310 -
8.311 -/** Structure for a single certificate request
8.312 - *
8.313 - * Useful for keeping track of the state of a verification that involves
8.314 - * several steps
8.315 - */
8.316 -struct _PurpleCertificateVerificationRequest
8.317 -{
8.318 - /** Reference to the verification logic used */
8.319 - PurpleCertificateVerifier *verifier;
8.320 - /** Reference to the scheme used.
8.321 - *
8.322 - * This is looked up from the Verifier when the Request is generated
8.323 - */
8.324 - PurpleCertificateScheme *scheme;
8.325 -
8.326 - /**
8.327 - * Name to check that the certificate is issued to
8.328 - *
8.329 - * For X.509 certificates, this is the Common Name
8.330 - */
8.331 - gchar *subject_name;
8.332 -
8.333 - /** List of certificates in the chain to be verified (such as that returned by purple_ssl_get_peer_certificates )
8.334 - *
8.335 - * This is most relevant for X.509 certificates used in SSL sessions.
8.336 - * The list order should be: certificate, issuer, issuer's issuer, etc.
8.337 - */
8.338 - GList *cert_chain;
8.339 -
8.340 - /** Internal data used by the Verifier code */
8.341 - gpointer data;
8.342 -
8.343 - /** Function to call with the verification result */
8.344 - PurpleCertificateVerifiedCallback cb;
8.345 - /** Data to pass to the post-verification callback */
8.346 - gpointer cb_data;
8.347 -};
8.348 -
8.349 -/*****************************************************************************/
8.350 -/** @name Certificate Verification Functions */
8.351 -/*****************************************************************************/
8.352 -/*@{*/
8.353 -
8.354 -/**
8.355 - * Constructs a verification request and passed control to the specified Verifier
8.356 - *
8.357 - * It is possible that the callback will be called immediately upon calling
8.358 - * this function. Plan accordingly.
8.359 - *
8.360 - * @param verifier Verification logic to use.
8.361 - * @see purple_certificate_find_verifier()
8.362 - *
8.363 - * @param subject_name Name that should match the first certificate in the
8.364 - * chain for the certificate to be valid. Will be strdup'd
8.365 - * into the Request struct
8.366 - *
8.367 - * @param cert_chain Certificate chain to check. If there is more than one
8.368 - * certificate in the chain (X.509), the peer's
8.369 - * certificate comes first, then the issuer/signer's
8.370 - * certificate, etc. The whole list is duplicated into the
8.371 - * Request struct.
8.372 - *
8.373 - * @param cb Callback function to be called with whether the
8.374 - * certificate was approved or not.
8.375 - * @param cb_data User-defined data for the above.
8.376 - */
8.377 -void
8.378 -purple_certificate_verify (PurpleCertificateVerifier *verifier,
8.379 - const gchar *subject_name, GList *cert_chain,
8.380 - PurpleCertificateVerifiedCallback cb,
8.381 - gpointer cb_data);
8.382 -
8.383 -/**
8.384 - * Completes and destroys a VerificationRequest
8.385 - *
8.386 - * @param vrq Request to conclude
8.387 - * @param st Success/failure code to pass to the request's
8.388 - * completion callback.
8.389 - */
8.390 -void
8.391 -purple_certificate_verify_complete(PurpleCertificateVerificationRequest *vrq,
8.392 - PurpleCertificateVerificationStatus st);
8.393 -
8.394 -/*@}*/
8.395 -
8.396 -/*****************************************************************************/
8.397 -/** @name Certificate Functions */
8.398 -/*****************************************************************************/
8.399 -/*@{*/
8.400 -
8.401 -/**
8.402 - * Makes a duplicate of a certificate
8.403 - *
8.404 - * @param crt Instance to duplicate
8.405 - * @return Pointer to new instance
8.406 - */
8.407 -PurpleCertificate *
8.408 -purple_certificate_copy(PurpleCertificate *crt);
8.409 -
8.410 -/**
8.411 - * Duplicates an entire list of certificates
8.412 - *
8.413 - * @param crt_list List to duplicate
8.414 - * @return New list copy
8.415 - */
8.416 -GList *
8.417 -purple_certificate_copy_list(GList *crt_list);
8.418 -
8.419 -/**
8.420 - * Destroys and free()'s a Certificate
8.421 - *
8.422 - * @param crt Instance to destroy. May be NULL.
8.423 - */
8.424 -void
8.425 -purple_certificate_destroy (PurpleCertificate *crt);
8.426 -
8.427 -/**
8.428 - * Destroy an entire list of Certificate instances and the containing list
8.429 - *
8.430 - * @param crt_list List of certificates to destroy. May be NULL.
8.431 - */
8.432 -void
8.433 -purple_certificate_destroy_list (GList * crt_list);
8.434 -
8.435 -/**
8.436 - * Check whether 'crt' has a valid signature made by 'issuer'
8.437 - *
8.438 - * @param crt Certificate instance to check signature of
8.439 - * @param issuer Certificate thought to have signed 'crt'
8.440 - *
8.441 - * @return TRUE if 'crt' has a valid signature made by 'issuer',
8.442 - * otherwise FALSE
8.443 - * @todo Find a way to give the reason (bad signature, not the issuer, etc.)
8.444 - */
8.445 -gboolean
8.446 -purple_certificate_signed_by(PurpleCertificate *crt, PurpleCertificate *issuer);
8.447 -
8.448 -/**
8.449 - * Check that a certificate chain is valid
8.450 - *
8.451 - * Uses purple_certificate_signed_by() to verify that each PurpleCertificate
8.452 - * in the chain carries a valid signature from the next. A single-certificate
8.453 - * chain is considered to be valid.
8.454 - *
8.455 - * @param chain List of PurpleCertificate instances comprising the chain,
8.456 - * in the order certificate, issuer, issuer's issuer, etc.
8.457 - * @return TRUE if the chain is valid. See description.
8.458 - * @todo Specify which certificate in the chain caused a failure
8.459 - */
8.460 -gboolean
8.461 -purple_certificate_check_signature_chain(GList *chain);
8.462 -
8.463 -/**
8.464 - * Imports a PurpleCertificate from a file
8.465 - *
8.466 - * @param scheme Scheme to import under
8.467 - * @param filename File path to import from
8.468 - * @return Pointer to a new PurpleCertificate, or NULL on failure
8.469 - */
8.470 -PurpleCertificate *
8.471 -purple_certificate_import(PurpleCertificateScheme *scheme, const gchar *filename);
8.472 -
8.473 -/**
8.474 - * Exports a PurpleCertificate to a file
8.475 - *
8.476 - * @param filename File to export the certificate to
8.477 - * @param crt Certificate to export
8.478 - * @return TRUE if the export succeeded, otherwise FALSE
8.479 - */
8.480 -gboolean
8.481 -purple_certificate_export(const gchar *filename, PurpleCertificate *crt);
8.482 -
8.483 -
8.484 -/**
8.485 - * Retrieves the certificate public key fingerprint using SHA1.
8.486 - *
8.487 - * @param crt Certificate instance
8.488 - * @return Binary representation of the hash. You are responsible for free()ing
8.489 - * this.
8.490 - * @see purple_base16_encode_chunked()
8.491 - */
8.492 -GByteArray *
8.493 -purple_certificate_get_fingerprint_sha1(PurpleCertificate *crt);
8.494 -
8.495 -/**
8.496 - * Get a unique identifier for the certificate
8.497 - *
8.498 - * @param crt Certificate instance
8.499 - * @return String representing the certificate uniquely. Must be g_free()'ed
8.500 - */
8.501 -gchar *
8.502 -purple_certificate_get_unique_id(PurpleCertificate *crt);
8.503 -
8.504 -/**
8.505 - * Get a unique identifier for the certificate's issuer
8.506 - *
8.507 - * @param crt Certificate instance
8.508 - * @return String representing the certificate's issuer uniquely. Must be
8.509 - * g_free()'ed
8.510 - */
8.511 -gchar *
8.512 -purple_certificate_get_issuer_unique_id(PurpleCertificate *crt);
8.513 -
8.514 -/**
8.515 - * Gets the certificate subject's name
8.516 - *
8.517 - * For X.509, this is the "Common Name" field, as we're only using it
8.518 - * for hostname verification at the moment
8.519 - *
8.520 - * @param crt Certificate instance
8.521 - * @return Newly allocated string with the certificate subject.
8.522 - */
8.523 -gchar *
8.524 -purple_certificate_get_subject_name(PurpleCertificate *crt);
8.525 -
8.526 -/**
8.527 - * Check the subject name against that on the certificate
8.528 - * @param crt Certificate instance
8.529 - * @param name Name to check.
8.530 - * @return TRUE if it is a match, else FALSE
8.531 - */
8.532 -gboolean
8.533 -purple_certificate_check_subject_name(PurpleCertificate *crt, const gchar *name);
8.534 -
8.535 -/**
8.536 - * Get the expiration/activation times.
8.537 - *
8.538 - * @param crt Certificate instance
8.539 - * @param activation Reference to store the activation time at. May be NULL
8.540 - * if you don't actually want it.
8.541 - * @param expiration Reference to store the expiration time at. May be NULL
8.542 - * if you don't actually want it.
8.543 - * @return TRUE if the requested values were obtained, otherwise FALSE.
8.544 - */
8.545 -gboolean
8.546 -purple_certificate_get_times(PurpleCertificate *crt, time_t *activation, time_t *expiration);
8.547 -
8.548 -/*@}*/
8.549 -
8.550 -/*****************************************************************************/
8.551 -/** @name Certificate Pool Functions */
8.552 -/*****************************************************************************/
8.553 -/*@{*/
8.554 -/**
8.555 - * Helper function for generating file paths in ~/.purple/certificates for
8.556 - * CertificatePools that use them.
8.557 - *
8.558 - * All components will be escaped for filesystem friendliness.
8.559 - *
8.560 - * @param pool CertificatePool to build a path for
8.561 - * @param id Key to look up a Certificate by. May be NULL.
8.562 - * @return A newly allocated path of the form
8.563 - * ~/.purple/certificates/scheme_name/pool_name/unique_id
8.564 - */
8.565 -gchar *
8.566 -purple_certificate_pool_mkpath(PurpleCertificatePool *pool, const gchar *id);
8.567 -
8.568 -/**
8.569 - * Determines whether a pool can be used.
8.570 - *
8.571 - * Checks whether the associated CertificateScheme is loaded.
8.572 - *
8.573 - * @param pool Pool to check
8.574 - *
8.575 - * @return TRUE if the pool can be used, otherwise FALSE
8.576 - */
8.577 -gboolean
8.578 -purple_certificate_pool_usable(PurpleCertificatePool *pool);
8.579 -
8.580 -/**
8.581 - * Looks up the scheme the pool operates under
8.582 - *
8.583 - * @param pool Pool to get the scheme of
8.584 - *
8.585 - * @return Pointer to the pool's scheme, or NULL if it isn't loaded.
8.586 - * @see purple_certificate_pool_usable()
8.587 - */
8.588 -PurpleCertificateScheme *
8.589 -purple_certificate_pool_get_scheme(PurpleCertificatePool *pool);
8.590 -
8.591 -/**
8.592 - * Check for presence of an ID in a pool.
8.593 - * @param pool Pool to look in
8.594 - * @param id ID to look for
8.595 - * @return TRUE if the ID is in the pool, else FALSE
8.596 - */
8.597 -gboolean
8.598 -purple_certificate_pool_contains(PurpleCertificatePool *pool, const gchar *id);
8.599 -
8.600 -/**
8.601 - * Retrieve a certificate from a pool.
8.602 - * @param pool Pool to fish in
8.603 - * @param id ID to look up
8.604 - * @return Retrieved certificate, or NULL if it wasn't there
8.605 - */
8.606 -PurpleCertificate *
8.607 -purple_certificate_pool_retrieve(PurpleCertificatePool *pool, const gchar *id);
8.608 -
8.609 -/**
8.610 - * Add a certificate to a pool
8.611 - *
8.612 - * Any pre-existing certificate of the same ID will be overwritten.
8.613 - *
8.614 - * @param pool Pool to add to
8.615 - * @param id ID to store the certificate with
8.616 - * @param crt Certificate to store
8.617 - * @return TRUE if the operation succeeded, otherwise FALSE
8.618 - */
8.619 -gboolean
8.620 -purple_certificate_pool_store(PurpleCertificatePool *pool, const gchar *id, PurpleCertificate *crt);
8.621 -
8.622 -/**
8.623 - * Remove a certificate from a pool
8.624 - *
8.625 - * @param pool Pool to remove from
8.626 - * @param id ID to remove
8.627 - * @return TRUE if the operation succeeded, otherwise FALSE
8.628 - */
8.629 -gboolean
8.630 -purple_certificate_pool_delete(PurpleCertificatePool *pool, const gchar *id);
8.631 -
8.632 -/**
8.633 - * Get the list of IDs currently in the pool.
8.634 - *
8.635 - * @param pool Pool to enumerate
8.636 - * @return GList pointing to newly-allocated id strings. Free using
8.637 - * purple_certificate_pool_destroy_idlist()
8.638 - */
8.639 -GList *
8.640 -purple_certificate_pool_get_idlist(PurpleCertificatePool *pool);
8.641 -
8.642 -/**
8.643 - * Destroys the result given by purple_certificate_pool_get_idlist()
8.644 - *
8.645 - * @param idlist ID List to destroy
8.646 - */
8.647 -void
8.648 -purple_certificate_pool_destroy_idlist(GList *idlist);
8.649 -
8.650 -/*@}*/
8.651 -
8.652 -/*****************************************************************************/
8.653 -/** @name Certificate Subsystem API */
8.654 -/*****************************************************************************/
8.655 -/*@{*/
8.656 -
8.657 -/**
8.658 - * Initialize the certificate system
8.659 - */
8.660 -void
8.661 -purple_certificate_init(void);
8.662 -
8.663 -/**
8.664 - * Un-initialize the certificate system
8.665 - */
8.666 -void
8.667 -purple_certificate_uninit(void);
8.668 -
8.669 -/**
8.670 - * Get the Certificate subsystem handle for signalling purposes
8.671 - */
8.672 -gpointer
8.673 -purple_certificate_get_handle(void);
8.674 -
8.675 -/** Look up a registered CertificateScheme by name
8.676 - * @param name The scheme name. Case insensitive.
8.677 - * @return Pointer to the located Scheme, or NULL if it isn't found.
8.678 - */
8.679 -PurpleCertificateScheme *
8.680 -purple_certificate_find_scheme(const gchar *name);
8.681 -
8.682 -/**
8.683 - * Get all registered CertificateSchemes
8.684 - *
8.685 - * @return GList pointing to all registered CertificateSchemes . This value
8.686 - * is owned by libpurple
8.687 - */
8.688 -GList *
8.689 -purple_certificate_get_schemes(void);
8.690 -
8.691 -/** Register a CertificateScheme with libpurple
8.692 - *
8.693 - * No two schemes can be registered with the same name; this function enforces
8.694 - * that.
8.695 - *
8.696 - * @param scheme Pointer to the scheme to register.
8.697 - * @return TRUE if the scheme was successfully added, otherwise FALSE
8.698 - */
8.699 -gboolean
8.700 -purple_certificate_register_scheme(PurpleCertificateScheme *scheme);
8.701 -
8.702 -/** Unregister a CertificateScheme from libpurple
8.703 - *
8.704 - * @param scheme Scheme to unregister.
8.705 - * If the scheme is not registered, this is a no-op.
8.706 - *
8.707 - * @return TRUE if the unregister completed successfully
8.708 - */
8.709 -gboolean
8.710 -purple_certificate_unregister_scheme(PurpleCertificateScheme *scheme);
8.711 -
8.712 -/** Look up a registered PurpleCertificateVerifier by scheme and name
8.713 - * @param scheme_name Scheme name. Case insensitive.
8.714 - * @param ver_name The verifier name. Case insensitive.
8.715 - * @return Pointer to the located Verifier, or NULL if it isn't found.
8.716 - */
8.717 -PurpleCertificateVerifier *
8.718 -purple_certificate_find_verifier(const gchar *scheme_name, const gchar *ver_name);
8.719 -
8.720 -/**
8.721 - * Get the list of registered CertificateVerifiers
8.722 - *
8.723 - * @return GList of all registered PurpleCertificateVerifier. This value
8.724 - * is owned by libpurple
8.725 - */
8.726 -GList *
8.727 -purple_certificate_get_verifiers(void);
8.728 -
8.729 -/**
8.730 - * Register a CertificateVerifier with libpurple
8.731 - *
8.732 - * @param vr Verifier to register.
8.733 - * @return TRUE if register succeeded, otherwise FALSE
8.734 - */
8.735 -gboolean
8.736 -purple_certificate_register_verifier(PurpleCertificateVerifier *vr);
8.737 -
8.738 -/**
8.739 - * Unregister a CertificateVerifier with libpurple
8.740 - *
8.741 - * @param vr Verifier to unregister.
8.742 - * @return TRUE if unregister succeeded, otherwise FALSE
8.743 - */
8.744 -gboolean
8.745 -purple_certificate_unregister_verifier(PurpleCertificateVerifier *vr);
8.746 -
8.747 -/** Look up a registered PurpleCertificatePool by scheme and name
8.748 - * @param scheme_name Scheme name. Case insensitive.
8.749 - * @param pool_name Pool name. Case insensitive.
8.750 - * @return Pointer to the located Pool, or NULL if it isn't found.
8.751 - */
8.752 -PurpleCertificatePool *
8.753 -purple_certificate_find_pool(const gchar *scheme_name, const gchar *pool_name);
8.754 -
8.755 -/**
8.756 - * Get the list of registered Pools
8.757 - *
8.758 - * @return GList of all registered PurpleCertificatePool s. This value
8.759 - * is owned by libpurple
8.760 - */
8.761 -GList *
8.762 -purple_certificate_get_pools(void);
8.763 -
8.764 -/**
8.765 - * Register a CertificatePool with libpurple and call its init function
8.766 - *
8.767 - * @param pool Pool to register.
8.768 - * @return TRUE if the register succeeded, otherwise FALSE
8.769 - */
8.770 -gboolean
8.771 -purple_certificate_register_pool(PurpleCertificatePool *pool);
8.772 -
8.773 -/**
8.774 - * Unregister a CertificatePool with libpurple and call its uninit function
8.775 - *
8.776 - * @param pool Pool to unregister.
8.777 - * @return TRUE if the unregister succeeded, otherwise FALSE
8.778 - */
8.779 -gboolean
8.780 -purple_certificate_unregister_pool(PurpleCertificatePool *pool);
8.781 -
8.782 -/*@}*/
8.783 -
8.784 -
8.785 -/**
8.786 - * Displays a window showing X.509 certificate information
8.787 - *
8.788 - * @param crt Certificate under an "x509" Scheme
8.789 - * @todo Will break on CA certs, as they have no Common Name
8.790 - */
8.791 -void
8.792 -purple_certificate_display_x509(PurpleCertificate *crt);
8.793 -
8.794 -/**
8.795 - * Add a search path for certificates.
8.796 - *
8.797 - * @param path Path to search for certificates.
8.798 - */
8.799 -void purple_certificate_add_ca_search_path(const char *path);
8.800 -
8.801 -#ifdef __cplusplus
8.802 -}
8.803 -#endif /* __cplusplus */
8.804 -
8.805 -#endif /* _PURPLE_CERTIFICATE_H */
9.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/cipher.h Sun Jun 21 22:04:11 2009 -0400
9.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
9.3 @@ -1,505 +0,0 @@
9.4 -/**
9.5 - * @file cipher.h Purple Cipher API
9.6 - * @ingroup core
9.7 - * @see @ref cipher-signals
9.8 - */
9.9 -
9.10 -/* purple
9.11 - *
9.12 - * Purple is the legal property of its developers, whose names are too numerous
9.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
9.14 - * source distribution.
9.15 - *
9.16 - * This program is free software; you can redistribute it and/or modify
9.17 - * it under the terms of the GNU General Public License as published by
9.18 - * the Free Software Foundation; either version 2 of the License, or
9.19 - * (at your option) any later version.
9.20 - *
9.21 - * This program is distributed in the hope that it will be useful,
9.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
9.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9.24 - * GNU General Public License for more details.
9.25 - *
9.26 - * You should have received a copy of the GNU General Public License
9.27 - * along with this program; if not, write to the Free Software
9.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
9.29 - */
9.30 -#ifndef PURPLE_CIPHER_H
9.31 -#define PURPLE_CIPHER_H
9.32 -
9.33 -#include <glib.h>
9.34 -
9.35 -#define PURPLE_CIPHER(obj) ((PurpleCipher *)(obj)) /**< PurpleCipher typecast helper */
9.36 -#define PURPLE_CIPHER_OPS(obj) ((PurpleCipherOps *)(obj)) /**< PurpleCipherInfo typecase helper */
9.37 -#define PURPLE_CIPHER_CONTEXT(obj) ((PurpleCipherContext *)(obj)) /**< PurpleCipherContext typecast helper */
9.38 -
9.39 -typedef struct _PurpleCipher PurpleCipher; /**< A handle to a PurpleCipher */
9.40 -typedef struct _PurpleCipherOps PurpleCipherOps; /**< Ops for a PurpleCipher */
9.41 -typedef struct _PurpleCipherContext PurpleCipherContext; /**< A context for a PurpleCipher */
9.42 -
9.43 -/**
9.44 - * Modes for batch encrypters
9.45 - */
9.46 -typedef enum _PurpleCipherBatchMode {
9.47 - PURPLE_CIPHER_BATCH_MODE_ECB,
9.48 - PURPLE_CIPHER_BATCH_MODE_CBC
9.49 -} PurpleCipherBatchMode;
9.50 -
9.51 -/**
9.52 - * The operation flags for a cipher
9.53 - */
9.54 -typedef enum _PurpleCipherCaps {
9.55 - PURPLE_CIPHER_CAPS_SET_OPT = 1 << 1, /**< Set option flag */
9.56 - PURPLE_CIPHER_CAPS_GET_OPT = 1 << 2, /**< Get option flag */
9.57 - PURPLE_CIPHER_CAPS_INIT = 1 << 3, /**< Init flag */
9.58 - PURPLE_CIPHER_CAPS_RESET = 1 << 4, /**< Reset flag */
9.59 - PURPLE_CIPHER_CAPS_UNINIT = 1 << 5, /**< Uninit flag */
9.60 - PURPLE_CIPHER_CAPS_SET_IV = 1 << 6, /**< Set IV flag */
9.61 - PURPLE_CIPHER_CAPS_APPEND = 1 << 7, /**< Append flag */
9.62 - PURPLE_CIPHER_CAPS_DIGEST = 1 << 8, /**< Digest flag */
9.63 - PURPLE_CIPHER_CAPS_ENCRYPT = 1 << 9, /**< Encrypt flag */
9.64 - PURPLE_CIPHER_CAPS_DECRYPT = 1 << 10, /**< Decrypt flag */
9.65 - PURPLE_CIPHER_CAPS_SET_SALT = 1 << 11, /**< Set salt flag */
9.66 - PURPLE_CIPHER_CAPS_GET_SALT_SIZE = 1 << 12, /**< Get salt size flag */
9.67 - PURPLE_CIPHER_CAPS_SET_KEY = 1 << 13, /**< Set key flag */
9.68 - PURPLE_CIPHER_CAPS_GET_KEY_SIZE = 1 << 14, /**< Get key size flag */
9.69 - PURPLE_CIPHER_CAPS_SET_BATCH_MODE = 1 << 15, /**< Set batch mode flag */
9.70 - PURPLE_CIPHER_CAPS_GET_BATCH_MODE = 1 << 16, /**< Get batch mode flag */
9.71 - PURPLE_CIPHER_CAPS_GET_BLOCK_SIZE = 1 << 17, /**< The get block size flag */
9.72 - PURPLE_CIPHER_CAPS_SET_KEY_WITH_LEN = 1 << 18, /**< The set key with length flag */
9.73 - PURPLE_CIPHER_CAPS_UNKNOWN = 1 << 19 /**< Unknown */
9.74 -} PurpleCipherCaps;
9.75 -
9.76 -/**
9.77 - * The operations of a cipher. Every cipher must implement one of these.
9.78 - */
9.79 -struct _PurpleCipherOps {
9.80 - /** The set option function */
9.81 - void (*set_option)(PurpleCipherContext *context, const gchar *name, void *value);
9.82 -
9.83 - /** The get option function */
9.84 - void *(*get_option)(PurpleCipherContext *context, const gchar *name);
9.85 -
9.86 - /** The init function */
9.87 - void (*init)(PurpleCipherContext *context, void *extra);
9.88 -
9.89 - /** The reset function */
9.90 - void (*reset)(PurpleCipherContext *context, void *extra);
9.91 -
9.92 - /** The uninit function */
9.93 - void (*uninit)(PurpleCipherContext *context);
9.94 -
9.95 - /** The set initialization vector function */
9.96 - void (*set_iv)(PurpleCipherContext *context, guchar *iv, size_t len);
9.97 -
9.98 - /** The append data function */
9.99 - void (*append)(PurpleCipherContext *context, const guchar *data, size_t len);
9.100 -
9.101 - /** The digest function */
9.102 - gboolean (*digest)(PurpleCipherContext *context, size_t in_len, guchar digest[], size_t *out_len);
9.103 -
9.104 - /** The encrypt function */
9.105 - int (*encrypt)(PurpleCipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
9.106 -
9.107 - /** The decrypt function */
9.108 - int (*decrypt)(PurpleCipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
9.109 -
9.110 - /** The set salt function */
9.111 - void (*set_salt)(PurpleCipherContext *context, guchar *salt);
9.112 -
9.113 - /** The get salt size function */
9.114 - size_t (*get_salt_size)(PurpleCipherContext *context);
9.115 -
9.116 - /** The set key function */
9.117 - void (*set_key)(PurpleCipherContext *context, const guchar *key);
9.118 -
9.119 - /** The get key size function */
9.120 - size_t (*get_key_size)(PurpleCipherContext *context);
9.121 -
9.122 - /** The set batch mode function */
9.123 - void (*set_batch_mode)(PurpleCipherContext *context, PurpleCipherBatchMode mode);
9.124 -
9.125 - /** The get batch mode function */
9.126 - PurpleCipherBatchMode (*get_batch_mode)(PurpleCipherContext *context);
9.127 -
9.128 - /** The get block size function */
9.129 - size_t (*get_block_size)(PurpleCipherContext *context);
9.130 -
9.131 - /** The set key with length function */
9.132 - void (*set_key_with_len)(PurpleCipherContext *context, const guchar *key, size_t len);
9.133 -};
9.134 -
9.135 -#ifdef __cplusplus
9.136 -extern "C" {
9.137 -#endif /* __cplusplus */
9.138 -
9.139 -/*****************************************************************************/
9.140 -/** @name PurpleCipher API */
9.141 -/*****************************************************************************/
9.142 -/*@{*/
9.143 -
9.144 -/**
9.145 - * Gets a cipher's name
9.146 - *
9.147 - * @param cipher The cipher handle
9.148 - *
9.149 - * @return The cipher's name
9.150 - */
9.151 -const gchar *purple_cipher_get_name(PurpleCipher *cipher);
9.152 -
9.153 -/**
9.154 - * Gets a cipher's capabilities
9.155 - *
9.156 - * @param cipher The cipher handle
9.157 - *
9.158 - * @return The cipher's info
9.159 - */
9.160 -guint purple_cipher_get_capabilities(PurpleCipher *cipher);
9.161 -
9.162 -/**
9.163 - * Gets a digest from a cipher
9.164 - *
9.165 - * @param name The cipher's name
9.166 - * @param data The data to hash
9.167 - * @param data_len The length of the data
9.168 - * @param in_len The length of the buffer
9.169 - * @param digest The returned digest
9.170 - * @param out_len The length written
9.171 - *
9.172 - * @return @c TRUE if successful, @c FALSE otherwise
9.173 - */
9.174 -gboolean purple_cipher_digest_region(const gchar *name, const guchar *data, size_t data_len, size_t in_len, guchar digest[], size_t *out_len);
9.175 -
9.176 -/*@}*/
9.177 -/******************************************************************************/
9.178 -/** @name PurpleCiphers API */
9.179 -/******************************************************************************/
9.180 -/*@{*/
9.181 -
9.182 -/**
9.183 - * Finds a cipher by it's name
9.184 - *
9.185 - * @param name The name of the cipher to find
9.186 - *
9.187 - * @return The cipher handle or @c NULL
9.188 - */
9.189 -PurpleCipher *purple_ciphers_find_cipher(const gchar *name);
9.190 -
9.191 -/**
9.192 - * Registers a cipher as a usable cipher
9.193 - *
9.194 - * @param name The name of the new cipher
9.195 - * @param ops The cipher ops to register
9.196 - *
9.197 - * @return The handle to the new cipher or @c NULL if it failed
9.198 - */
9.199 -PurpleCipher *purple_ciphers_register_cipher(const gchar *name, PurpleCipherOps *ops);
9.200 -
9.201 -/**
9.202 - * Unregisters a cipher
9.203 - *
9.204 - * @param cipher The cipher handle to unregister
9.205 - *
9.206 - * @return Whether or not the cipher was successfully unloaded
9.207 - */
9.208 -gboolean purple_ciphers_unregister_cipher(PurpleCipher *cipher);
9.209 -
9.210 -/**
9.211 - * Gets the list of ciphers
9.212 - *
9.213 - * @return The list of available ciphers
9.214 - * @note This list should not be modified, it is owned by the cipher core
9.215 - */
9.216 -GList *purple_ciphers_get_ciphers(void);
9.217 -
9.218 -/*@}*/
9.219 -/******************************************************************************/
9.220 -/** @name PurpleCipher Subsystem API */
9.221 -/******************************************************************************/
9.222 -/*@{*/
9.223 -
9.224 -/**
9.225 - * Gets the handle to the cipher subsystem
9.226 - *
9.227 - * @return The handle to the cipher subsystem
9.228 - */
9.229 -gpointer purple_ciphers_get_handle(void);
9.230 -
9.231 -/**
9.232 - * Initializes the cipher core
9.233 - */
9.234 -void purple_ciphers_init(void);
9.235 -
9.236 -/**
9.237 - * Uninitializes the cipher core
9.238 - */
9.239 -void purple_ciphers_uninit(void);
9.240 -
9.241 -/*@}*/
9.242 -/******************************************************************************/
9.243 -/** @name PurpleCipherContext API */
9.244 -/******************************************************************************/
9.245 -/*@{*/
9.246 -
9.247 -/**
9.248 - * Sets the value an option on a cipher context
9.249 - *
9.250 - * @param context The cipher context
9.251 - * @param name The name of the option
9.252 - * @param value The value to set
9.253 - */
9.254 -void purple_cipher_context_set_option(PurpleCipherContext *context, const gchar *name, gpointer value);
9.255 -
9.256 -/**
9.257 - * Gets the vale of an option on a cipher context
9.258 - *
9.259 - * @param context The cipher context
9.260 - * @param name The name of the option
9.261 - * @return The value of the option
9.262 - */
9.263 -gpointer purple_cipher_context_get_option(PurpleCipherContext *context, const gchar *name);
9.264 -
9.265 -/**
9.266 - * Creates a new cipher context and initializes it
9.267 - *
9.268 - * @param cipher The cipher to use
9.269 - * @param extra Extra data for the specific cipher
9.270 - *
9.271 - * @return The new cipher context
9.272 - */
9.273 -PurpleCipherContext *purple_cipher_context_new(PurpleCipher *cipher, void *extra);
9.274 -
9.275 -/**
9.276 - * Creates a new cipher context by the cipher name and initializes it
9.277 - *
9.278 - * @param name The cipher's name
9.279 - * @param extra Extra data for the specific cipher
9.280 - *
9.281 - * @return The new cipher context
9.282 - */
9.283 -PurpleCipherContext *purple_cipher_context_new_by_name(const gchar *name, void *extra);
9.284 -
9.285 -/**
9.286 - * Resets a cipher context to it's default value
9.287 - * @note If you have set an IV you will have to set it after resetting
9.288 - *
9.289 - * @param context The context to reset
9.290 - * @param extra Extra data for the specific cipher
9.291 - */
9.292 -void purple_cipher_context_reset(PurpleCipherContext *context, gpointer extra);
9.293 -
9.294 -/**
9.295 - * Destorys a cipher context and deinitializes it
9.296 - *
9.297 - * @param context The cipher context to destory
9.298 - */
9.299 -void purple_cipher_context_destroy(PurpleCipherContext *context);
9.300 -
9.301 -/**
9.302 - * Sets the initialization vector for a context
9.303 - * @note This should only be called right after a cipher context is created or reset
9.304 - *
9.305 - * @param context The context to set the IV to
9.306 - * @param iv The initialization vector to set
9.307 - * @param len The len of the IV
9.308 - */
9.309 -void purple_cipher_context_set_iv(PurpleCipherContext *context, guchar *iv, size_t len);
9.310 -
9.311 -/**
9.312 - * Appends data to the context
9.313 - *
9.314 - * @param context The context to append data to
9.315 - * @param data The data to append
9.316 - * @param len The length of the data
9.317 - */
9.318 -void purple_cipher_context_append(PurpleCipherContext *context, const guchar *data, size_t len);
9.319 -
9.320 -/**
9.321 - * Digests a context
9.322 - *
9.323 - * @param context The context to digest
9.324 - * @param in_len The length of the buffer
9.325 - * @param digest The return buffer for the digest
9.326 - * @param out_len The length of the returned value
9.327 - */
9.328 -gboolean purple_cipher_context_digest(PurpleCipherContext *context, size_t in_len, guchar digest[], size_t *out_len);
9.329 -
9.330 -/**
9.331 - * Converts a guchar digest into a hex string
9.332 - *
9.333 - * @param context The context to get a digest from
9.334 - * @param in_len The length of the buffer
9.335 - * @param digest_s The return buffer for the string digest
9.336 - * @param out_len The length of the returned value
9.337 - */
9.338 -gboolean purple_cipher_context_digest_to_str(PurpleCipherContext *context, size_t in_len, gchar digest_s[], size_t *out_len);
9.339 -
9.340 -/**
9.341 - * Encrypts data using the context
9.342 - *
9.343 - * @param context The context
9.344 - * @param data The data to encrypt
9.345 - * @param len The length of the data
9.346 - * @param output The output buffer
9.347 - * @param outlen The len of data that was outputed
9.348 - *
9.349 - * @return A cipher specific status code
9.350 - */
9.351 -gint purple_cipher_context_encrypt(PurpleCipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
9.352 -
9.353 -/**
9.354 - * Decrypts data using the context
9.355 - *
9.356 - * @param context The context
9.357 - * @param data The data to encrypt
9.358 - * @param len The length of the returned value
9.359 - * @param output The output buffer
9.360 - * @param outlen The len of data that was outputed
9.361 - *
9.362 - * @return A cipher specific status code
9.363 - */
9.364 -gint purple_cipher_context_decrypt(PurpleCipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
9.365 -
9.366 -/**
9.367 - * Sets the salt on a context
9.368 - *
9.369 - * @param context The context whose salt to set
9.370 - * @param salt The salt
9.371 - */
9.372 -void purple_cipher_context_set_salt(PurpleCipherContext *context, guchar *salt);
9.373 -
9.374 -/**
9.375 - * Gets the size of the salt if the cipher supports it
9.376 - *
9.377 - * @param context The context whose salt size to get
9.378 - *
9.379 - * @return The size of the salt
9.380 - */
9.381 -size_t purple_cipher_context_get_salt_size(PurpleCipherContext *context);
9.382 -
9.383 -/**
9.384 - * Sets the key on a context
9.385 - *
9.386 - * @param context The context whose key to set
9.387 - * @param key The key
9.388 - */
9.389 -void purple_cipher_context_set_key(PurpleCipherContext *context, const guchar *key);
9.390 -
9.391 -/**
9.392 - * Gets the key size for a context
9.393 - *
9.394 - * @param context The context whose key size to get
9.395 - *
9.396 - * @return The size of the key
9.397 - */
9.398 -size_t purple_cipher_context_get_key_size(PurpleCipherContext *context);
9.399 -
9.400 -/**
9.401 - * Sets the batch mode of a context
9.402 - *
9.403 - * @param context The context whose batch mode to set
9.404 - * @param mode The batch mode under which the cipher should operate
9.405 - *
9.406 - */
9.407 -void purple_cipher_context_set_batch_mode(PurpleCipherContext *context, PurpleCipherBatchMode mode);
9.408 -
9.409 -/**
9.410 - * Gets the batch mode of a context
9.411 - *
9.412 - * @param context The context whose batch mode to get
9.413 - *
9.414 - * @return The batch mode under which the cipher is operating
9.415 - */
9.416 -PurpleCipherBatchMode purple_cipher_context_get_batch_mode(PurpleCipherContext *context);
9.417 -
9.418 -/**
9.419 - * Gets the block size of a context
9.420 - *
9.421 - * @param context The context whose block size to get
9.422 - *
9.423 - * @return The block size of the context
9.424 - */
9.425 -size_t purple_cipher_context_get_block_size(PurpleCipherContext *context);
9.426 -
9.427 -/**
9.428 - * Sets the key with a given length on a context
9.429 - *
9.430 - * @param context The context whose key to set
9.431 - * @param key The key
9.432 - * @param len The length of the key
9.433 - *
9.434 - */
9.435 -void purple_cipher_context_set_key_with_len(PurpleCipherContext *context, const guchar *key, size_t len);
9.436 -
9.437 -/**
9.438 - * Sets the cipher data for a context
9.439 - *
9.440 - * @param context The context whose cipher data to set
9.441 - * @param data The cipher data to set
9.442 - */
9.443 -void purple_cipher_context_set_data(PurpleCipherContext *context, gpointer data);
9.444 -
9.445 -/**
9.446 - * Gets the cipher data for a context
9.447 - *
9.448 - * @param context The context whose cipher data to get
9.449 - *
9.450 - * @return The cipher data
9.451 - */
9.452 -gpointer purple_cipher_context_get_data(PurpleCipherContext *context);
9.453 -
9.454 -/*@}*/
9.455 -/*****************************************************************************/
9.456 -/** @name Purple Cipher HTTP Digest Helper Functions */
9.457 -/*****************************************************************************/
9.458 -/*@{*/
9.459 -
9.460 -/**
9.461 - * Calculates a session key for HTTP Digest authentation
9.462 - *
9.463 - * See RFC 2617 for more information.
9.464 - *
9.465 - * @param algorithm The hash algorithm to use
9.466 - * @param username The username provided by the user
9.467 - * @param realm The authentication realm provided by the server
9.468 - * @param password The password provided by the user
9.469 - * @param nonce The nonce provided by the server
9.470 - * @param client_nonce The nonce provided by the client
9.471 - *
9.472 - * @return The session key, or @c NULL if an error occurred.
9.473 - */
9.474 -gchar *purple_cipher_http_digest_calculate_session_key(
9.475 - const gchar *algorithm, const gchar *username,
9.476 - const gchar *realm, const gchar *password,
9.477 - const gchar *nonce, const gchar *client_nonce);
9.478 -
9.479 -/** Calculate a response for HTTP Digest authentication
9.480 - *
9.481 - * See RFC 2617 for more information.
9.482 - *
9.483 - * @param algorithm The hash algorithm to use
9.484 - * @param method The HTTP method in use
9.485 - * @param digest_uri The URI from the initial request
9.486 - * @param qop The "quality of protection"
9.487 - * @param entity The entity body
9.488 - * @param nonce The nonce provided by the server
9.489 - * @param nonce_count The nonce count
9.490 - * @param client_nonce The nonce provided by the client
9.491 - * @param session_key The session key from purple_cipher_http_digest_calculate_session_key()
9.492 - *
9.493 - * @return The hashed response, or @c NULL if an error occurred.
9.494 - */
9.495 -gchar *purple_cipher_http_digest_calculate_response(
9.496 - const gchar *algorithm, const gchar *method,
9.497 - const gchar *digest_uri, const gchar *qop,
9.498 - const gchar *entity, const gchar *nonce,
9.499 - const gchar *nonce_count, const gchar *client_nonce,
9.500 - const gchar *session_key);
9.501 -
9.502 -/*@}*/
9.503 -
9.504 -#ifdef __cplusplus
9.505 -}
9.506 -#endif /* __cplusplus */
9.507 -
9.508 -#endif /* PURPLE_CIPHER_H */
10.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/circbuffer.h Sun Jun 21 22:04:11 2009 -0400
10.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
10.3 @@ -1,118 +0,0 @@
10.4 -/**
10.5 - * @file circbuffer.h Buffer Utility Functions
10.6 - * @ingroup core
10.7 - */
10.8 -
10.9 -/* Purple is the legal property of its developers, whose names are too numerous
10.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
10.11 - * source distribution.
10.12 - *
10.13 - * This program is free software; you can redistribute it and/or modify
10.14 - * it under the terms of the GNU General Public License as published by
10.15 - * the Free Software Foundation; either version 2 of the License, or
10.16 - * (at your option) any later version.
10.17 - *
10.18 - * This program is distributed in the hope that it will be useful,
10.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
10.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10.21 - * GNU General Public License for more details.
10.22 - *
10.23 - * You should have received a copy of the GNU General Public License
10.24 - * along with this program; if not, write to the Free Software
10.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
10.26 - */
10.27 -#ifndef _CIRCBUFFER_H
10.28 -#define _CIRCBUFFER_H
10.29 -
10.30 -#include <glib.h>
10.31 -
10.32 -#ifdef __cplusplus
10.33 -extern "C" {
10.34 -#endif
10.35 -
10.36 -typedef struct _PurpleCircBuffer {
10.37 -
10.38 - /** A pointer to the starting address of our chunk of memory. */
10.39 - gchar *buffer;
10.40 -
10.41 - /** The incremental amount to increase this buffer by when
10.42 - * the buffer is not big enough to hold incoming data, in bytes. */
10.43 - gsize growsize;
10.44 -
10.45 - /** The length of this buffer, in bytes. */
10.46 - gsize buflen;
10.47 -
10.48 - /** The number of bytes of this buffer that contain unread data. */
10.49 - gsize bufused;
10.50 -
10.51 - /** A pointer to the next byte where new incoming data is
10.52 - * buffered to. */
10.53 - gchar *inptr;
10.54 -
10.55 - /** A pointer to the next byte of buffered data that should be
10.56 - * read by the consumer. */
10.57 - gchar *outptr;
10.58 -
10.59 -} PurpleCircBuffer;
10.60 -
10.61 -/**
10.62 - * Creates a new circular buffer. This will not allocate any memory for the
10.63 - * actual buffer until data is appended to it.
10.64 - *
10.65 - * @param growsize The amount that the buffer should grow the first time data
10.66 - * is appended and every time more space is needed. Pass in
10.67 - * "0" to use the default of 256 bytes.
10.68 - *
10.69 - * @return The new PurpleCircBuffer. This should be freed with
10.70 - * purple_circ_buffer_destroy when you are done with it
10.71 - */
10.72 -PurpleCircBuffer *purple_circ_buffer_new(gsize growsize);
10.73 -
10.74 -/**
10.75 - * Dispose of the PurpleCircBuffer and free any memory used by it (including any
10.76 - * memory used by the internal buffer).
10.77 - *
10.78 - * @param buf The PurpleCircBuffer to free
10.79 - */
10.80 -void purple_circ_buffer_destroy(PurpleCircBuffer *buf);
10.81 -
10.82 -/**
10.83 - * Append data to the PurpleCircBuffer. This will grow the internal
10.84 - * buffer to fit the added data, if needed.
10.85 - *
10.86 - * @param buf The PurpleCircBuffer to which to append the data
10.87 - * @param src pointer to the data to copy into the buffer
10.88 - * @param len number of bytes to copy into the buffer
10.89 - */
10.90 -void purple_circ_buffer_append(PurpleCircBuffer *buf, gconstpointer src, gsize len);
10.91 -
10.92 -/**
10.93 - * Determine the maximum number of contiguous bytes that can be read from the
10.94 - * PurpleCircBuffer.
10.95 - * Note: This may not be the total number of bytes that are buffered - a
10.96 - * subsequent call after calling purple_circ_buffer_mark_read() may indicate more
10.97 - * data is available to read.
10.98 - *
10.99 - * @param buf the PurpleCircBuffer for which to determine the maximum contiguous
10.100 - * bytes that can be read.
10.101 - *
10.102 - * @return the number of bytes that can be read from the PurpleCircBuffer
10.103 - */
10.104 -gsize purple_circ_buffer_get_max_read(const PurpleCircBuffer *buf);
10.105 -
10.106 -/**
10.107 - * Mark the number of bytes that have been read from the buffer.
10.108 - *
10.109 - * @param buf The PurpleCircBuffer to mark bytes read from
10.110 - * @param len The number of bytes to mark as read
10.111 - *
10.112 - * @return TRUE if we successfully marked the bytes as having been read, FALSE
10.113 - * otherwise.
10.114 - */
10.115 -gboolean purple_circ_buffer_mark_read(PurpleCircBuffer *buf, gsize len);
10.116 -
10.117 -#ifdef __cplusplus
10.118 -}
10.119 -#endif
10.120 -
10.121 -#endif /* _CIRCBUFFER_H */
11.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/cmdproc.h Sun Jun 21 22:04:11 2009 -0400
11.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
11.3 @@ -1,76 +0,0 @@
11.4 -/**
11.5 - * @file cmdproc.h MSN command processor functions
11.6 - *
11.7 - * purple
11.8 - *
11.9 - * Purple is the legal property of its developers, whose names are too numerous
11.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
11.11 - * source distribution.
11.12 - *
11.13 - * This program is free software; you can redistribute it and/or modify
11.14 - * it under the terms of the GNU General Public License as published by
11.15 - * the Free Software Foundation; either version 2 of the License, or
11.16 - * (at your option) any later version.
11.17 - *
11.18 - * This program is distributed in the hope that it will be useful,
11.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
11.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11.21 - * GNU General Public License for more details.
11.22 - *
11.23 - * You should have received a copy of the GNU General Public License
11.24 - * along with this program; if not, write to the Free Software
11.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
11.26 - */
11.27 -#ifndef _MSN_CMDPROC_H_
11.28 -#define _MSN_CMDPROC_H_
11.29 -
11.30 -typedef struct _MsnCmdProc MsnCmdProc;
11.31 -
11.32 -#include "session.h"
11.33 -#include "servconn.h"
11.34 -#include "error.h"
11.35 -#include "command.h"
11.36 -#include "table.h"
11.37 -#include "history.h"
11.38 -
11.39 -struct _MsnCmdProc
11.40 -{
11.41 - MsnSession *session;
11.42 - MsnServConn *servconn;
11.43 -
11.44 - GQueue *txqueue;
11.45 -
11.46 - MsnCommand *last_cmd;
11.47 -
11.48 - MsnTable *cbs_table;
11.49 -
11.50 - MsnHistory *history;
11.51 -
11.52 - GHashTable *multiparts; /**< Multi-part message ID's */
11.53 -
11.54 - void *data; /**< Extra data, like the switchboard. */
11.55 -};
11.56 -
11.57 -MsnCmdProc *msn_cmdproc_new(MsnSession *session);
11.58 -void msn_cmdproc_destroy(MsnCmdProc *cmdproc);
11.59 -
11.60 -void msn_cmdproc_process_queue(MsnCmdProc *cmdproc);
11.61 -
11.62 -void msn_cmdproc_send_trans(MsnCmdProc *cmdproc, MsnTransaction *trans);
11.63 -void msn_cmdproc_queue_trans(MsnCmdProc *cmdproc,
11.64 - MsnTransaction *trans);
11.65 -void msn_cmdproc_send(MsnCmdProc *cmdproc, const char *command,
11.66 - const char *format, ...);
11.67 -void msn_cmdproc_send_quick(MsnCmdProc *cmdproc, const char *command,
11.68 - const char *format, ...);
11.69 -
11.70 -void msn_cmdproc_process_msg(MsnCmdProc *cmdproc,
11.71 - MsnMessage *msg);
11.72 -void msn_cmdproc_process_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd);
11.73 -void msn_cmdproc_process_cmd_text(MsnCmdProc *cmdproc, const char *command);
11.74 -void msn_cmdproc_process_payload(MsnCmdProc *cmdproc,
11.75 - char *payload, int payload_len);
11.76 -
11.77 -void msn_cmdproc_disconnect(MsnCmdProc *cmdproc);
11.78 -
11.79 -#endif /* _MSN_CMDPROC_H_ */
12.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/cmds.h Sun Jun 21 22:04:11 2009 -0400
12.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
12.3 @@ -1,250 +0,0 @@
12.4 -/**
12.5 - * @file cmds.h Commands API
12.6 - * @ingroup core
12.7 - * @see @ref cmd-signals
12.8 - */
12.9 -
12.10 -/* Copyright (C) 2003 Timothy Ringenbach <omarvo@hotmail.com>
12.11 - *
12.12 - * This program is free software; you can redistribute it and/or modify
12.13 - * it under the terms of the GNU General Public License as published by
12.14 - * the Free Software Foundation; either version 2 of the License, or
12.15 - * (at your option) any later version.
12.16 - *
12.17 - * This program is distributed in the hope that it will be useful,
12.18 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
12.19 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12.20 - * GNU General Public License for more details.
12.21 - *
12.22 - * You should have received a copy of the GNU General Public License
12.23 - * along with this program; if not, write to the Free Software
12.24 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
12.25 - *
12.26 - */
12.27 -#ifndef _PURPLE_CMDS_H_
12.28 -#define _PURPLE_CMDS_H_
12.29 -
12.30 -#include "conversation.h"
12.31 -
12.32 -/**************************************************************************/
12.33 -/** @name Structures */
12.34 -/**************************************************************************/
12.35 -/*@{*/
12.36 -
12.37 -/** The possible results of running a command with purple_cmd_do_command(). */
12.38 -typedef enum _PurpleCmdStatus {
12.39 - PURPLE_CMD_STATUS_OK,
12.40 - PURPLE_CMD_STATUS_FAILED,
12.41 - PURPLE_CMD_STATUS_NOT_FOUND,
12.42 - PURPLE_CMD_STATUS_WRONG_ARGS,
12.43 - PURPLE_CMD_STATUS_WRONG_PRPL,
12.44 - PURPLE_CMD_STATUS_WRONG_TYPE
12.45 -} PurpleCmdStatus;
12.46 -
12.47 -/** Commands registered with the core return one of these values when run.
12.48 - * Normally, a command will want to return one of the first two; in some
12.49 - * unusual cases, you might want to have several functions called for a
12.50 - * particular command; in this case, they should return
12.51 - * #PURPLE_CMD_RET_CONTINUE to cause the core to fall through to other
12.52 - * commands with the same name.
12.53 - */
12.54 -typedef enum _PurpleCmdRet {
12.55 - PURPLE_CMD_RET_OK, /**< Everything's okay; Don't look for another command to call. */
12.56 - PURPLE_CMD_RET_FAILED, /**< The command failed, but stop looking.*/
12.57 - PURPLE_CMD_RET_CONTINUE /**< Continue, looking for other commands with the same name to call. */
12.58 -} PurpleCmdRet;
12.59 -
12.60 -#define PURPLE_CMD_FUNC(func) ((PurpleCmdFunc)func)
12.61 -
12.62 -/** A function implementing a command, as passed to purple_cmd_register().
12.63 - *
12.64 - * @todo document the arguments to these functions.
12.65 - * */
12.66 -typedef PurpleCmdRet (*PurpleCmdFunc)(PurpleConversation *, const gchar *cmd,
12.67 - gchar **args, gchar **error, void *data);
12.68 -/** A unique integer representing a command registered with
12.69 - * purple_cmd_register(), which can subsequently be passed to
12.70 - * purple_cmd_unregister() to unregister that command.
12.71 - */
12.72 -typedef guint PurpleCmdId;
12.73 -
12.74 -typedef enum _PurpleCmdPriority {
12.75 - PURPLE_CMD_P_VERY_LOW = -1000,
12.76 - PURPLE_CMD_P_LOW = 0,
12.77 - PURPLE_CMD_P_DEFAULT = 1000,
12.78 - PURPLE_CMD_P_PRPL = 2000,
12.79 - PURPLE_CMD_P_PLUGIN = 3000,
12.80 - PURPLE_CMD_P_ALIAS = 4000,
12.81 - PURPLE_CMD_P_HIGH = 5000,
12.82 - PURPLE_CMD_P_VERY_HIGH = 6000
12.83 -} PurpleCmdPriority;
12.84 -
12.85 -/** Flags used to set various properties of commands. Every command should
12.86 - * have at least one of #PURPLE_CMD_FLAG_IM and #PURPLE_CMD_FLAG_CHAT set in
12.87 - * order to be even slighly useful.
12.88 - *
12.89 - * @see purple_cmd_register
12.90 - */
12.91 -typedef enum _PurpleCmdFlag {
12.92 - /** Command is usable in IMs. */
12.93 - PURPLE_CMD_FLAG_IM = 0x01,
12.94 - /** Command is usable in multi-user chats. */
12.95 - PURPLE_CMD_FLAG_CHAT = 0x02,
12.96 - /** Command is usable only for a particular prpl. */
12.97 - PURPLE_CMD_FLAG_PRPL_ONLY = 0x04,
12.98 - /** Incorrect arguments to this command should be accepted anyway. */
12.99 - PURPLE_CMD_FLAG_ALLOW_WRONG_ARGS = 0x08
12.100 -} PurpleCmdFlag;
12.101 -
12.102 -
12.103 -/*@}*/
12.104 -
12.105 -#ifdef __cplusplus
12.106 -extern "C" {
12.107 -#endif
12.108 -
12.109 -/**************************************************************************/
12.110 -/** @name Commands API */
12.111 -/**************************************************************************/
12.112 -/*@{*/
12.113 -
12.114 -/**
12.115 - * Register a new command with the core.
12.116 - *
12.117 - * The command will only happen if commands are enabled,
12.118 - * which is a UI pref. UIs don't have to support commands at all.
12.119 - *
12.120 - * @param cmd The command. This should be a UTF-8 (or ASCII) string, with no spaces
12.121 - * or other white space.
12.122 - * @param args A string of characters describing to libpurple how to parse this
12.123 - * command's arguments. If what the user types doesn't match this
12.124 - * pattern, libpurple will keep looking for another command, unless
12.125 - * the flag #PURPLE_CMD_FLAG_ALLOW_WRONG_ARGS is passed in @a f.
12.126 - * This string should contain no whitespace, and use a single
12.127 - * character for each argument. The recognized characters are:
12.128 - * <ul>
12.129 - * <li><tt>'w'</tt>: Matches a single word.</li>
12.130 - * <li><tt>'W'</tt>: Matches a single word, with formatting.</li>
12.131 - * <li><tt>'s'</tt>: Matches the rest of the arguments after this
12.132 - * point, as a single string.</li>
12.133 - * <li><tt>'S'</tt>: Same as <tt>'s'</tt> but with formatting.</li>
12.134 - * </ul>
12.135 - * If args is the empty string, then the command accepts no arguments.
12.136 - * The args passed to the callback @a func will be a @c NULL
12.137 - * terminated array of @c NULL terminated strings, and will always
12.138 - * match the number of arguments asked for, unless
12.139 - * #PURPLE_CMD_FLAG_ALLOW_WRONG_ARGS is passed.
12.140 - * @param p This is the priority. Higher priority commands will be run first,
12.141 - * and usually the first command will stop any others from being
12.142 - * called.
12.143 - * @param f Flags specifying various options about this command, combined with
12.144 - * <tt>|</tt> (bitwise OR). You need to at least pass one of
12.145 - * #PURPLE_CMD_FLAG_IM or #PURPLE_CMD_FLAG_CHAT (you may pass both) in
12.146 - * order for the command to ever actually be called.
12.147 - * @param prpl_id If the #PURPLE_CMD_FLAG_PRPL_ONLY flag is set, this is the id
12.148 - * of the prpl to which the command applies (such as
12.149 - * <tt>"prpl-msn"</tt>). If the flag is not set, this parameter
12.150 - * is ignored; pass @c NULL (or a humourous string of your
12.151 - * choice!).
12.152 - * @param func This is the function to call when someone enters this command.
12.153 - * @param helpstr a whitespace sensitive, UTF-8, HTML string describing how to
12.154 - * use the command. The preferred format of this string is the
12.155 - * command's name, followed by a space and any arguments it
12.156 - * accepts (if it takes any arguments, otherwise no space),
12.157 - * followed by a colon, two spaces, and a description of the
12.158 - * command in sentence form. Do not include a slash before the
12.159 - * command name.
12.160 - * @param data User defined data to pass to the #PurpleCmdFunc @a f.
12.161 - * @return A #PurpleCmdId, which is only used for calling
12.162 - * #purple_cmd_unregister, or @a 0 on failure.
12.163 - */
12.164 -PurpleCmdId purple_cmd_register(const gchar *cmd, const gchar *args, PurpleCmdPriority p, PurpleCmdFlag f,
12.165 - const gchar *prpl_id, PurpleCmdFunc func, const gchar *helpstr, void *data);
12.166 -
12.167 -/**
12.168 - * Unregister a command with the core.
12.169 - *
12.170 - * All registered commands must be unregistered, if they're registered by a plugin
12.171 - * or something else that might go away. Normally this is called when the plugin
12.172 - * unloads itself.
12.173 - *
12.174 - * @param id The #PurpleCmdId to unregister, as returned by #purple_cmd_register.
12.175 - */
12.176 -void purple_cmd_unregister(PurpleCmdId id);
12.177 -
12.178 -/**
12.179 - * Do a command.
12.180 - *
12.181 - * Normally the UI calls this to perform a command. This might also be useful
12.182 - * if aliases are ever implemented.
12.183 - *
12.184 - * @param conv The conversation the command was typed in.
12.185 - * @param cmdline The command the user typed (including all arguments) as a single string.
12.186 - * The caller doesn't have to do any parsing, except removing the command
12.187 - * prefix, which the core has no knowledge of. cmd should not contain any
12.188 - * formatting, and should be in plain text (no html entities).
12.189 - * @param markup This is the same as cmd, but is the formatted version. It should be in
12.190 - * HTML, with < > and &, at least, escaped to html entities, and should
12.191 - * include both the default formatting and any extra manual formatting.
12.192 - * @param errormsg If the command failed errormsg is filled in with the appropriate error
12.193 - * message. It must be freed by the caller with g_free().
12.194 - * @return A #PurpleCmdStatus indicating if the command succeeded or failed.
12.195 - */
12.196 -PurpleCmdStatus purple_cmd_do_command(PurpleConversation *conv, const gchar *cmdline,
12.197 - const gchar *markup, gchar **errormsg);
12.198 -
12.199 -/**
12.200 - * List registered commands.
12.201 - *
12.202 - * Returns a <tt>GList</tt> (which must be freed by the caller) of all commands
12.203 - * that are valid in the context of @a conv, or all commands, if @a conv is @c
12.204 - * NULL. Don't keep this list around past the main loop, or anything else that
12.205 - * might unregister a command, as the <tt>const char *</tt>'s used get freed
12.206 - * then.
12.207 - *
12.208 - * @param conv The conversation, or @c NULL.
12.209 - * @return A @c GList of <tt>const char *</tt>, which must be freed with
12.210 - * <tt>g_list_free()</tt>.
12.211 - */
12.212 -GList *purple_cmd_list(PurpleConversation *conv);
12.213 -
12.214 -/**
12.215 - * Get the help string for a command.
12.216 - *
12.217 - * Returns the help strings for a given command in the form of a GList,
12.218 - * one node for each matching command.
12.219 - *
12.220 - * @param conv The conversation, or @c NULL for no context.
12.221 - * @param cmd The command. No wildcards accepted, but returns help for all
12.222 - * commands if @c NULL.
12.223 - * @return A <tt>GList</tt> of <tt>const char *</tt>s, which is the help string
12.224 - * for that command.
12.225 - */
12.226 -GList *purple_cmd_help(PurpleConversation *conv, const gchar *cmd);
12.227 -
12.228 -/**
12.229 - * Get the handle for the commands API
12.230 - * @return The handle
12.231 - * @since 2.5.0
12.232 - */
12.233 -gpointer purple_cmds_get_handle(void);
12.234 -
12.235 -/**
12.236 - * Initialize the commands subsystem.
12.237 - * @since 2.5.0
12.238 - */
12.239 -void purple_cmds_init(void);
12.240 -
12.241 -/**
12.242 - * Uninitialize the commands subsystem.
12.243 - * @since 2.5.0
12.244 - */
12.245 -void purple_cmds_uninit(void);
12.246 -
12.247 -/*@}*/
12.248 -
12.249 -#ifdef __cplusplus
12.250 -}
12.251 -#endif
12.252 -
12.253 -#endif /* _PURPLE_CMDS_H_ */
13.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/command.h Sun Jun 21 22:04:11 2009 -0400
13.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
13.3 @@ -1,62 +0,0 @@
13.4 -/**
13.5 - * @file command.h MSN command functions
13.6 - *
13.7 - * purple
13.8 - *
13.9 - * Purple is the legal property of its developers, whose names are too numerous
13.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
13.11 - * source distribution.
13.12 - *
13.13 - * This program is free software; you can redistribute it and/or modify
13.14 - * it under the terms of the GNU General Public License as published by
13.15 - * the Free Software Foundation; either version 2 of the License, or
13.16 - * (at your option) any later version.
13.17 - *
13.18 - * This program is distributed in the hope that it will be useful,
13.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
13.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13.21 - * GNU General Public License for more details.
13.22 - *
13.23 - * You should have received a copy of the GNU General Public License
13.24 - * along with this program; if not, write to the Free Software
13.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
13.26 - */
13.27 -#ifndef _MSN_COMMAND_H
13.28 -#define _MSN_COMMAND_H
13.29 -
13.30 -typedef struct _MsnCommand MsnCommand;
13.31 -
13.32 -#include "cmdproc.h"
13.33 -#include "transaction.h"
13.34 -
13.35 -typedef void (*MsnPayloadCb)(MsnCmdProc *cmdproc, MsnCommand *cmd,
13.36 - char *payload, size_t len);
13.37 -
13.38 -/**
13.39 - * A received command.
13.40 - */
13.41 -struct _MsnCommand
13.42 -{
13.43 - unsigned int trId;
13.44 -
13.45 - char *command;
13.46 - char **params;
13.47 - int param_count;
13.48 -
13.49 - int ref_count;
13.50 -
13.51 - MsnTransaction *trans;
13.52 -
13.53 - char *payload;
13.54 - size_t payload_len;
13.55 -
13.56 - MsnPayloadCb payload_cb;
13.57 - void *payload_cbdata;
13.58 -};
13.59 -
13.60 -MsnCommand *msn_command_from_string(const char *string);
13.61 -void msn_command_destroy(MsnCommand *cmd);
13.62 -MsnCommand *msn_command_ref(MsnCommand *cmd);
13.63 -MsnCommand *msn_command_unref(MsnCommand *cmd);
13.64 -
13.65 -#endif /* _MSN_COMMAND_H */
14.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/connection.h Sun Jun 21 22:04:11 2009 -0400
14.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
14.3 @@ -1,582 +0,0 @@
14.4 -/**
14.5 - * @file connection.h Connection API
14.6 - * @ingroup core
14.7 - * @see @ref connection-signals
14.8 - */
14.9 -
14.10 -/* purple
14.11 - *
14.12 - * Purple is the legal property of its developers, whose names are too numerous
14.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
14.14 - * source distribution.
14.15 - *
14.16 - * This program is free software; you can redistribute it and/or modify
14.17 - * it under the terms of the GNU General Public License as published by
14.18 - * the Free Software Foundation; either version 2 of the License, or
14.19 - * (at your option) any later version.
14.20 - *
14.21 - * This program is distributed in the hope that it will be useful,
14.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
14.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14.24 - * GNU General Public License for more details.
14.25 - *
14.26 - * You should have received a copy of the GNU General Public License
14.27 - * along with this program; if not, write to the Free Software
14.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
14.29 - */
14.30 -#ifndef _PURPLE_CONNECTION_H_
14.31 -#define _PURPLE_CONNECTION_H_
14.32 -
14.33 -/** @copydoc _PurpleConnection */
14.34 -typedef struct _PurpleConnection PurpleConnection;
14.35 -
14.36 -/**
14.37 - * Flags to change behavior of the client for a given connection.
14.38 - */
14.39 -typedef enum
14.40 -{
14.41 - PURPLE_CONNECTION_HTML = 0x0001, /**< Connection sends/receives in 'HTML'. */
14.42 - PURPLE_CONNECTION_NO_BGCOLOR = 0x0002, /**< Connection does not send/receive
14.43 - background colors. */
14.44 - PURPLE_CONNECTION_AUTO_RESP = 0x0004, /**< Send auto responses when away. */
14.45 - PURPLE_CONNECTION_FORMATTING_WBFO = 0x0008, /**< The text buffer must be formatted as a whole */
14.46 - PURPLE_CONNECTION_NO_NEWLINES = 0x0010, /**< No new lines are allowed in outgoing messages */
14.47 - PURPLE_CONNECTION_NO_FONTSIZE = 0x0020, /**< Connection does not send/receive font sizes */
14.48 - PURPLE_CONNECTION_NO_URLDESC = 0x0040, /**< Connection does not support descriptions with links */
14.49 - PURPLE_CONNECTION_NO_IMAGES = 0x0080, /**< Connection does not support sending of images */
14.50 - PURPLE_CONNECTION_ALLOW_CUSTOM_SMILEY = 0x0100 /**< Connection supports sending and receiving custom smileys */
14.51 -
14.52 -} PurpleConnectionFlags;
14.53 -
14.54 -typedef enum
14.55 -{
14.56 - PURPLE_DISCONNECTED = 0, /**< Disconnected. */
14.57 - PURPLE_CONNECTED, /**< Connected. */
14.58 - PURPLE_CONNECTING /**< Connecting. */
14.59 -
14.60 -} PurpleConnectionState;
14.61 -
14.62 -/** Possible errors that can cause a connection to be closed.
14.63 - * @since 2.3.0
14.64 - */
14.65 -typedef enum
14.66 -{
14.67 - /** There was an error sending or receiving on the network socket, or
14.68 - * there was some protocol error (such as the server sending malformed
14.69 - * data).
14.70 - */
14.71 - PURPLE_CONNECTION_ERROR_NETWORK_ERROR = 0,
14.72 - /** The username supplied was not valid. */
14.73 - PURPLE_CONNECTION_ERROR_INVALID_USERNAME = 1,
14.74 - /** The username, password or some other credential was incorrect. Use
14.75 - * #PURPLE_CONNECTION_ERROR_INVALID_USERNAME instead if the username
14.76 - * is known to be invalid.
14.77 - */
14.78 - PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED = 2,
14.79 - /** libpurple doesn't speak any of the authentication methods the
14.80 - * server offered.
14.81 - */
14.82 - PURPLE_CONNECTION_ERROR_AUTHENTICATION_IMPOSSIBLE = 3,
14.83 - /** libpurple was built without SSL support, and the connection needs
14.84 - * SSL.
14.85 - */
14.86 - PURPLE_CONNECTION_ERROR_NO_SSL_SUPPORT = 4,
14.87 - /** There was an error negotiating SSL on this connection, or the
14.88 - * server does not support encryption but an account option was set to
14.89 - * require it.
14.90 - */
14.91 - PURPLE_CONNECTION_ERROR_ENCRYPTION_ERROR = 5,
14.92 - /** Someone is already connected to the server using the name you are
14.93 - * trying to connect with.
14.94 - */
14.95 - PURPLE_CONNECTION_ERROR_NAME_IN_USE = 6,
14.96 -
14.97 - /** The username/server/other preference for the account isn't valid.
14.98 - * For instance, on IRC the screen name cannot contain white space.
14.99 - * This reason should not be used for incorrect passwords etc: use
14.100 - * #PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED for that.
14.101 - *
14.102 - * @todo This reason really shouldn't be necessary. Usernames and
14.103 - * other account preferences should be validated when the
14.104 - * account is created.
14.105 - */
14.106 - PURPLE_CONNECTION_ERROR_INVALID_SETTINGS = 7,
14.107 -
14.108 - /** The server did not provide a SSL certificate. */
14.109 - PURPLE_CONNECTION_ERROR_CERT_NOT_PROVIDED = 8,
14.110 - /** The server's SSL certificate could not be trusted. */
14.111 - PURPLE_CONNECTION_ERROR_CERT_UNTRUSTED = 9,
14.112 - /** The server's SSL certificate has expired. */
14.113 - PURPLE_CONNECTION_ERROR_CERT_EXPIRED = 10,
14.114 - /** The server's SSL certificate is not yet valid. */
14.115 - PURPLE_CONNECTION_ERROR_CERT_NOT_ACTIVATED = 11,
14.116 - /** The server's SSL certificate did not match its hostname. */
14.117 - PURPLE_CONNECTION_ERROR_CERT_HOSTNAME_MISMATCH = 12,
14.118 - /** The server's SSL certificate does not have the expected
14.119 - * fingerprint.
14.120 - */
14.121 - PURPLE_CONNECTION_ERROR_CERT_FINGERPRINT_MISMATCH = 13,
14.122 - /** The server's SSL certificate is self-signed. */
14.123 - PURPLE_CONNECTION_ERROR_CERT_SELF_SIGNED = 14,
14.124 - /** There was some other error validating the server's SSL certificate.
14.125 - */
14.126 - PURPLE_CONNECTION_ERROR_CERT_OTHER_ERROR = 15,
14.127 -
14.128 - /** Some other error occurred which fits into none of the other
14.129 - * categories.
14.130 - */
14.131 - /* purple_connection_error_reason() in connection.c uses the fact that
14.132 - * this is the last member of the enum when sanity-checking; if other
14.133 - * reasons are added after it, the check must be updated.
14.134 - */
14.135 - PURPLE_CONNECTION_ERROR_OTHER_ERROR = 16
14.136 -} PurpleConnectionError;
14.137 -
14.138 -/** Holds the type of an error along with its description. */
14.139 -typedef struct
14.140 -{
14.141 - /** The type of error. */
14.142 - PurpleConnectionError type;
14.143 - /** A localised, human-readable description of the error. */
14.144 - char *description;
14.145 -} PurpleConnectionErrorInfo;
14.146 -
14.147 -#include <time.h>
14.148 -
14.149 -#include "account.h"
14.150 -#include "plugin.h"
14.151 -#include "status.h"
14.152 -#include "sslconn.h"
14.153 -
14.154 -/** Connection UI operations. Used to notify the user of changes to
14.155 - * connections, such as being disconnected, and to respond to the
14.156 - * underlying network connection appearing and disappearing. UIs should
14.157 - * call #purple_connections_set_ui_ops() with an instance of this struct.
14.158 - *
14.159 - * @see @ref ui-ops
14.160 - */
14.161 -typedef struct
14.162 -{
14.163 - /** When an account is connecting, this operation is called to notify
14.164 - * the UI of what is happening, as well as which @a step out of @a
14.165 - * step_count has been reached (which might be displayed as a progress
14.166 - * bar).
14.167 - * @see #purple_connection_update_progress
14.168 - */
14.169 - void (*connect_progress)(PurpleConnection *gc,
14.170 - const char *text,
14.171 - size_t step,
14.172 - size_t step_count);
14.173 -
14.174 - /** Called when a connection is established (just before the
14.175 - * @ref signed-on signal).
14.176 - */
14.177 - void (*connected)(PurpleConnection *gc);
14.178 - /** Called when a connection is ended (between the @ref signing-off
14.179 - * and @ref signed-off signals).
14.180 - */
14.181 - void (*disconnected)(PurpleConnection *gc);
14.182 -
14.183 - /** Used to display connection-specific notices. (Pidgin's Gtk user
14.184 - * interface implements this as a no-op; #purple_connection_notice(),
14.185 - * which uses this operation, is not used by any of the protocols
14.186 - * shipped with libpurple.)
14.187 - */
14.188 - void (*notice)(PurpleConnection *gc, const char *text);
14.189 -
14.190 - /** Called when an error causes a connection to be disconnected.
14.191 - * Called before #disconnected.
14.192 - * @param text a localized error message.
14.193 - * @see #purple_connection_error
14.194 - * @deprecated in favour of
14.195 - * #PurpleConnectionUiOps.report_disconnect_reason.
14.196 - */
14.197 - void (*report_disconnect)(PurpleConnection *gc, const char *text);
14.198 -
14.199 - /** Called when libpurple discovers that the computer's network
14.200 - * connection is active. On Linux, this uses Network Manager if
14.201 - * available; on Windows, it uses Win32's network change notification
14.202 - * infrastructure.
14.203 - */
14.204 - void (*network_connected)(void);
14.205 - /** Called when libpurple discovers that the computer's network
14.206 - * connection has gone away.
14.207 - */
14.208 - void (*network_disconnected)(void);
14.209 -
14.210 - /** Called when an error causes a connection to be disconnected.
14.211 - * Called before #disconnected. This op is intended to replace
14.212 - * #report_disconnect. If both are implemented, this will be called
14.213 - * first; however, there's no real reason to implement both.
14.214 - * @param reason why the connection ended, if known, or
14.215 - * #PURPLE_CONNECTION_ERROR_OTHER_ERROR, if not.
14.216 - * @param text a localized message describing the disconnection
14.217 - * in more detail to the user.
14.218 - * @see #purple_connection_error_reason
14.219 - * @since 2.3.0
14.220 - */
14.221 - void (*report_disconnect_reason)(PurpleConnection *gc,
14.222 - PurpleConnectionError reason,
14.223 - const char *text);
14.224 -
14.225 - void (*_purple_reserved1)(void);
14.226 - void (*_purple_reserved2)(void);
14.227 - void (*_purple_reserved3)(void);
14.228 -} PurpleConnectionUiOps;
14.229 -
14.230 -
14.231 -/* Represents an active connection on an account. */
14.232 -struct _PurpleConnection
14.233 -{
14.234 - PurplePlugin *prpl; /**< The protocol plugin. */
14.235 - PurpleConnectionFlags flags; /**< Connection flags. */
14.236 -
14.237 - PurpleConnectionState state; /**< The connection state. */
14.238 -
14.239 - PurpleAccount *account; /**< The account being connected to. */
14.240 - char *password; /**< The password used. */
14.241 - int inpa; /**< The input watcher. */
14.242 -
14.243 - GSList *buddy_chats; /**< A list of active chats
14.244 - (#PurpleConversation structs of type
14.245 - #PURPLE_CONV_TYPE_CHAT). */
14.246 - void *proto_data; /**< Protocol-specific data. */
14.247 -
14.248 - char *display_name; /**< How you appear to other people. */
14.249 - guint keepalive; /**< Keep-alive. */
14.250 -
14.251 - /** Wants to Die state. This is set when the user chooses to log out, or
14.252 - * when the protocol is disconnected and should not be automatically
14.253 - * reconnected (incorrect password, etc.). prpls should rely on
14.254 - * purple_connection_error_reason() to set this for them rather than
14.255 - * setting it themselves.
14.256 - * @see purple_connection_error_is_fatal
14.257 - */
14.258 - gboolean wants_to_die;
14.259 -
14.260 - guint disconnect_timeout; /**< Timer used for nasty stack tricks */
14.261 - time_t last_received; /**< When we last received a packet. Set by the
14.262 - prpl to avoid sending unneeded keepalives */
14.263 -};
14.264 -
14.265 -#ifdef __cplusplus
14.266 -extern "C" {
14.267 -#endif
14.268 -
14.269 -/**************************************************************************/
14.270 -/** @name Connection API */
14.271 -/**************************************************************************/
14.272 -/*@{*/
14.273 -
14.274 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_CONNECTION_C_)
14.275 -/**
14.276 - * This function should only be called by purple_account_connect()
14.277 - * in account.c. If you're trying to sign on an account, use that
14.278 - * function instead.
14.279 - *
14.280 - * Creates a connection to the specified account and either connects
14.281 - * or attempts to register a new account. If you are logging in,
14.282 - * the connection uses the current active status for this account.
14.283 - * So if you want to sign on as "away," for example, you need to
14.284 - * have called purple_account_set_status(account, "away").
14.285 - * (And this will call purple_account_connect() automatically).
14.286 - *
14.287 - * @param account The account the connection should be connecting to.
14.288 - * @param regist Whether we are registering a new account or just
14.289 - * trying to do a normal signon.
14.290 - * @param password The password to use.
14.291 - *
14.292 - * @deprecated As this is internal, we should make it private in 3.0.0.
14.293 - */
14.294 -void purple_connection_new(PurpleAccount *account, gboolean regist,
14.295 - const char *password);
14.296 -#endif
14.297 -
14.298 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_CONNECTION_C_)
14.299 -/**
14.300 - * This function should only be called by purple_account_unregister()
14.301 - * in account.c.
14.302 - *
14.303 - * Tries to unregister the account on the server. If the account is not
14.304 - * connected, also creates a new connection.
14.305 - *
14.306 - * @param account The account to unregister
14.307 - * @param password The password to use.
14.308 - * @param cb Optional callback to be called when unregistration is complete
14.309 - * @param user_data user data to pass to the callback
14.310 - *
14.311 - * @deprecated As this is internal, we should make it private in 3.0.0.
14.312 - */
14.313 -void purple_connection_new_unregister(PurpleAccount *account, const char *password, PurpleAccountUnregistrationCb cb, void *user_data);
14.314 -#endif
14.315 -
14.316 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_CONNECTION_C_)
14.317 -/**
14.318 - * Disconnects and destroys a PurpleConnection.
14.319 - *
14.320 - * This function should only be called by purple_account_disconnect()
14.321 - * in account.c. If you're trying to sign off an account, use that
14.322 - * function instead.
14.323 - *
14.324 - * @param gc The purple connection to destroy.
14.325 - *
14.326 - * @deprecated As this is internal, we should make it private in 3.0.0.
14.327 - */
14.328 -void purple_connection_destroy(PurpleConnection *gc);
14.329 -#endif
14.330 -
14.331 -/**
14.332 - * Sets the connection state. PRPLs should call this and pass in
14.333 - * the state #PURPLE_CONNECTED when the account is completely
14.334 - * signed on. What does it mean to be completely signed on? If
14.335 - * the core can call prpl->set_status, and it successfully changes
14.336 - * your status, then the account is online.
14.337 - *
14.338 - * @param gc The connection.
14.339 - * @param state The connection state.
14.340 - */
14.341 -void purple_connection_set_state(PurpleConnection *gc, PurpleConnectionState state);
14.342 -
14.343 -/**
14.344 - * Sets the connection's account.
14.345 - *
14.346 - * @param gc The connection.
14.347 - * @param account The account.
14.348 - */
14.349 -void purple_connection_set_account(PurpleConnection *gc, PurpleAccount *account);
14.350 -
14.351 -/**
14.352 - * Sets the connection's displayed name.
14.353 - *
14.354 - * @param gc The connection.
14.355 - * @param name The displayed name.
14.356 - */
14.357 -void purple_connection_set_display_name(PurpleConnection *gc, const char *name);
14.358 -
14.359 -/**
14.360 - * Returns the connection state.
14.361 - *
14.362 - * @param gc The connection.
14.363 - *
14.364 - * @return The connection state.
14.365 - */
14.366 -PurpleConnectionState purple_connection_get_state(const PurpleConnection *gc);
14.367 -
14.368 -/**
14.369 - * Returns TRUE if the account is connected, otherwise returns FALSE.
14.370 - *
14.371 - * @return TRUE if the account is connected, otherwise returns FALSE.
14.372 - */
14.373 -#define PURPLE_CONNECTION_IS_CONNECTED(gc) \
14.374 - (purple_connection_get_state(gc) == PURPLE_CONNECTED)
14.375 -
14.376 -/**
14.377 - * Returns the connection's account.
14.378 - *
14.379 - * @param gc The connection.
14.380 - *
14.381 - * @return The connection's account.
14.382 - */
14.383 -PurpleAccount *purple_connection_get_account(const PurpleConnection *gc);
14.384 -
14.385 -/**
14.386 - * Returns the protocol plugin managing a connection.
14.387 - *
14.388 - * @param gc The connection.
14.389 - *
14.390 - * @return The protocol plugin.
14.391 - * @since 2.4.0
14.392 - */
14.393 -PurplePlugin * purple_connection_get_prpl(const PurpleConnection *gc);
14.394 -
14.395 -/**
14.396 - * Returns the connection's password.
14.397 - *
14.398 - * @param gc The connection.
14.399 - *
14.400 - * @return The connection's password.
14.401 - */
14.402 -const char *purple_connection_get_password(const PurpleConnection *gc);
14.403 -
14.404 -/**
14.405 - * Returns the connection's displayed name.
14.406 - *
14.407 - * @param gc The connection.
14.408 - *
14.409 - * @return The connection's displayed name.
14.410 - */
14.411 -const char *purple_connection_get_display_name(const PurpleConnection *gc);
14.412 -
14.413 -/**
14.414 - * Updates the connection progress.
14.415 - *
14.416 - * @param gc The connection.
14.417 - * @param text Information on the current step.
14.418 - * @param step The current step.
14.419 - * @param count The total number of steps.
14.420 - */
14.421 -void purple_connection_update_progress(PurpleConnection *gc, const char *text,
14.422 - size_t step, size_t count);
14.423 -
14.424 -/**
14.425 - * Displays a connection-specific notice.
14.426 - *
14.427 - * @param gc The connection.
14.428 - * @param text The notice text.
14.429 - */
14.430 -void purple_connection_notice(PurpleConnection *gc, const char *text);
14.431 -
14.432 -/**
14.433 - * Closes a connection with an error.
14.434 - *
14.435 - * @param gc The connection.
14.436 - * @param reason The error text, which may not be @c NULL.
14.437 - * @deprecated in favour of #purple_connection_error_reason. Calling
14.438 - * @c purple_connection_error(gc, text) is equivalent to calling
14.439 - * @c purple_connection_error_reason(gc, reason, text) where @c reason is
14.440 - * #PURPLE_CONNECTION_ERROR_OTHER_ERROR if @c gc->wants_to_die is @c TRUE, and
14.441 - * #PURPLE_CONNECTION_ERROR_NETWORK_ERROR if not. (This is to keep
14.442 - * auto-reconnection behaviour the same when using old prpls which don't use
14.443 - * reasons yet.)
14.444 - */
14.445 -void purple_connection_error(PurpleConnection *gc, const char *reason);
14.446 -
14.447 -/**
14.448 - * Closes a connection with an error and a human-readable description of the
14.449 - * error. It also sets @c gc->wants_to_die to the value of
14.450 - * #purple_connection_error_is_fatal(@a reason), mainly for
14.451 - * backwards-compatibility.
14.452 - *
14.453 - * @param gc the connection which is closing.
14.454 - * @param reason why the connection is closing.
14.455 - * @param description a non-@c NULL localized description of the error.
14.456 - * @since 2.3.0
14.457 - */
14.458 -void
14.459 -purple_connection_error_reason (PurpleConnection *gc,
14.460 - PurpleConnectionError reason,
14.461 - const char *description);
14.462 -
14.463 -/**
14.464 - * Closes a connection due to an SSL error; this is basically a shortcut to
14.465 - * turning the #PurpleSslErrorType into a #PurpleConnectionError and a
14.466 - * human-readable string and then calling purple_connection_error_reason().
14.467 - * @since 2.3.0
14.468 - */
14.469 -void
14.470 -purple_connection_ssl_error (PurpleConnection *gc,
14.471 - PurpleSslErrorType ssl_error);
14.472 -
14.473 -/**
14.474 - * Reports whether a disconnection reason is fatal (in which case the account
14.475 - * should probably not be automatically reconnected) or transient (so
14.476 - * auto-reconnection is a good idea).
14.477 - * For instance, #PURPLE_CONNECTION_ERROR_NETWORK_ERROR is a temporary error,
14.478 - * which might be caused by losing the network connection, so <tt>
14.479 - * purple_connection_error_is_fatal (PURPLE_CONNECTION_ERROR_NETWORK_ERROR)</tt>
14.480 - * is @c FALSE. On the other hand,
14.481 - * #PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED probably indicates a
14.482 - * misconfiguration of the account which needs the user to go fix it up, so
14.483 - * <tt> purple_connection_error_is_fatal
14.484 - * (PURPLE_CONNECTION_ERROR_AUTHENTICATION_FAILED)</tt> is @c TRUE.
14.485 - *
14.486 - * (This function is meant to replace checking PurpleConnection.wants_to_die.)
14.487 - *
14.488 - * @return @c TRUE if the account should not be automatically reconnected, and
14.489 - * @c FALSE otherwise.
14.490 - * @since 2.3.0
14.491 - */
14.492 -gboolean
14.493 -purple_connection_error_is_fatal (PurpleConnectionError reason);
14.494 -
14.495 -/*@}*/
14.496 -
14.497 -/**************************************************************************/
14.498 -/** @name Connections API */
14.499 -/**************************************************************************/
14.500 -/*@{*/
14.501 -
14.502 -/**
14.503 - * Disconnects from all connections.
14.504 - */
14.505 -void purple_connections_disconnect_all(void);
14.506 -
14.507 -/**
14.508 - * Returns a list of all active connections. This does not
14.509 - * include connections that are in the process of connecting.
14.510 - *
14.511 - * @constreturn A list of all active connections.
14.512 - */
14.513 -GList *purple_connections_get_all(void);
14.514 -
14.515 -/**
14.516 - * Returns a list of all connections in the process of connecting.
14.517 - *
14.518 - * @constreturn A list of connecting connections.
14.519 - */
14.520 -GList *purple_connections_get_connecting(void);
14.521 -
14.522 -/**
14.523 - * Checks if gc is still a valid pointer to a gc.
14.524 - *
14.525 - * @return @c TRUE if gc is valid.
14.526 - */
14.527 -/*
14.528 - * TODO: Eventually this bad boy will be removed, because it is
14.529 - * a gross fix for a crashy problem.
14.530 - */
14.531 -#define PURPLE_CONNECTION_IS_VALID(gc) (g_list_find(purple_connections_get_all(), (gc)) != NULL)
14.532 -
14.533 -/*@}*/
14.534 -
14.535 -/**************************************************************************/
14.536 -/** @name UI Registration Functions */
14.537 -/**************************************************************************/
14.538 -/*@{*/
14.539 -
14.540 -/**
14.541 - * Sets the UI operations structure to be used for connections.
14.542 - *
14.543 - * @param ops The UI operations structure.
14.544 - */
14.545 -void purple_connections_set_ui_ops(PurpleConnectionUiOps *ops);
14.546 -
14.547 -/**
14.548 - * Returns the UI operations structure used for connections.
14.549 - *
14.550 - * @return The UI operations structure in use.
14.551 - */
14.552 -PurpleConnectionUiOps *purple_connections_get_ui_ops(void);
14.553 -
14.554 -/*@}*/
14.555 -
14.556 -/**************************************************************************/
14.557 -/** @name Connections Subsystem */
14.558 -/**************************************************************************/
14.559 -/*@{*/
14.560 -
14.561 -/**
14.562 - * Initializes the connections subsystem.
14.563 - */
14.564 -void purple_connections_init(void);
14.565 -
14.566 -/**
14.567 - * Uninitializes the connections subsystem.
14.568 - */
14.569 -void purple_connections_uninit(void);
14.570 -
14.571 -/**
14.572 - * Returns the handle to the connections subsystem.
14.573 - *
14.574 - * @return The connections subsystem handle.
14.575 - */
14.576 -void *purple_connections_get_handle(void);
14.577 -
14.578 -/*@}*/
14.579 -
14.580 -
14.581 -#ifdef __cplusplus
14.582 -}
14.583 -#endif
14.584 -
14.585 -#endif /* _PURPLE_CONNECTION_H_ */
15.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/contact.h Sun Jun 21 22:04:11 2009 -0400
15.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
15.3 @@ -1,699 +0,0 @@
15.4 -/**
15.5 - * @file contact.h Header file for contact.c
15.6 - * Author
15.7 - * MaYuan<mayuan2006@gmail.com>
15.8 - * purple
15.9 - *
15.10 - * Purple is the legal property of its developers, whose names are too numerous
15.11 - * to list here. Please refer to the COPYRIGHT file distributed with this
15.12 - * source distribution.
15.13 - *
15.14 - * This program is free software; you can redistribute it and/or modify
15.15 - * it under the terms of the GNU General Public License as published by
15.16 - * the Free Software Foundation; either version 2 of the License, or
15.17 - * (at your option) any later version.
15.18 - *
15.19 - * This program is distributed in the hope that it will be useful,
15.20 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
15.21 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15.22 - * GNU General Public License for more details.
15.23 - *
15.24 - * You should have received a copy of the GNU General Public License
15.25 - * along with this program; if not, write to the Free Software
15.26 - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
15.27 - */
15.28 -#ifndef _MSN_CONTACT_H_
15.29 -#define _MSN_CONTACT_H_
15.30 -
15.31 -#include "session.h"
15.32 -#include "soap.h"
15.33 -
15.34 -#define MSN_APPLICATION_ID "CFE80F9D-180F-4399-82AB-413F33A1FA11"
15.35 -
15.36 -#define MSN_CONTACT_SERVER "omega.contacts.msn.com"
15.37 -
15.38 -/* Get Contact List */
15.39 -
15.40 -#define MSN_GET_CONTACT_POST_URL "/abservice/SharingService.asmx"
15.41 -#define MSN_GET_CONTACT_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/FindMembership"
15.42 -
15.43 -#define MSN_GET_CONTACT_UPDATE_XML \
15.44 - "<View>Full</View>"\
15.45 - "<deltasOnly>true</deltasOnly>"\
15.46 - "<lastChange>%s</lastChange>"
15.47 -
15.48 -#define MSN_GET_CONTACT_TEMPLATE "<?xml version='1.0' encoding='utf-8'?>"\
15.49 -"<soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">"\
15.50 - "<soap:Header xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">"\
15.51 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.52 - "<ApplicationId xmlns=\"http://www.msn.com/webservices/AddressBook\">" MSN_APPLICATION_ID "</ApplicationId>"\
15.53 - "<IsMigration xmlns=\"http://www.msn.com/webservices/AddressBook\">false</IsMigration>"\
15.54 - "<PartnerScenario xmlns=\"http://www.msn.com/webservices/AddressBook\">%s</PartnerScenario>"\
15.55 - "</ABApplicationHeader>"\
15.56 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.57 - "<ManagedGroupRequest xmlns=\"http://www.msn.com/webservices/AddressBook\">false</ManagedGroupRequest>"\
15.58 - "<TicketToken>EMPTY</TicketToken>"\
15.59 - "</ABAuthHeader>"\
15.60 - "</soap:Header>"\
15.61 - "<soap:Body xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">"\
15.62 - "<FindMembership xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.63 - "<serviceFilter xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.64 - "<Types xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.65 - "<ServiceType xmlns=\"http://www.msn.com/webservices/AddressBook\">Messenger</ServiceType>"\
15.66 - "<ServiceType xmlns=\"http://www.msn.com/webservices/AddressBook\">Invitation</ServiceType>"\
15.67 - "<ServiceType xmlns=\"http://www.msn.com/webservices/AddressBook\">SocialNetwork</ServiceType>"\
15.68 - "<ServiceType xmlns=\"http://www.msn.com/webservices/AddressBook\">Space</ServiceType>"\
15.69 - "<ServiceType xmlns=\"http://www.msn.com/webservices/AddressBook\">Profile</ServiceType>"\
15.70 - "</Types>"\
15.71 - "</serviceFilter>"\
15.72 - "%s"\
15.73 - "</FindMembership>"\
15.74 - "</soap:Body>"\
15.75 -"</soap:Envelope>"
15.76 -
15.77 -/************************************************
15.78 - * Address Book SOAP
15.79 - * *********************************************/
15.80 -
15.81 -#define MSN_ADDRESS_BOOK_POST_URL "/abservice/abservice.asmx"
15.82 -
15.83 -/* Create AddressBook template */
15.84 -#define MSN_ADD_ADDRESSBOOK_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABAdd"
15.85 -
15.86 -#define MSN_ADD_ADDRESSBOOK_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.87 -"<soap:Envelope"\
15.88 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.89 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.90 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.91 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.92 - "<soap:Header>"\
15.93 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.94 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.95 - "<IsMigration>false</IsMigration>"\
15.96 - "<PartnerScenario>Initial</PartnerScenario>"\
15.97 - "</ABApplicationHeader>"\
15.98 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.99 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.100 - "<TicketToken>EMPTY</TicketToken>"\
15.101 - "</ABAuthHeader>"\
15.102 - "</soap:Header>"\
15.103 - "<soap:Body>"\
15.104 - "<ABAdd xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.105 - "<abInfo>"\
15.106 - "<name/>"\
15.107 - "<ownerPuid>0</ownerPuid>"\
15.108 - "<ownerEmail>%s</ownerEmail>"\
15.109 - "<fDefault>true</fDefault>"\
15.110 - "</abInfo>"\
15.111 - "</ABAdd>"\
15.112 - "</soap:Body>"\
15.113 -"</soap:Envelope>"
15.114 -
15.115 -/* Get AddressBook */
15.116 -#define MSN_GET_ADDRESS_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABFindAll"
15.117 -#define MSN_GET_ADDRESS_FULL_TIME "0001-01-01T00:00:00.0000000-08:00"
15.118 -#define MSN_GET_ADDRESS_UPDATE_XML \
15.119 - "<deltasOnly>true</deltasOnly>"\
15.120 - "<lastChange>%s</lastChange>"
15.121 -
15.122 -#define MSN_GET_GLEAM_UPDATE_XML \
15.123 - "%s"\
15.124 - "<dynamicItemView>Gleam</dynamicItemView>"\
15.125 - "<dynamicItemLastChange>%s</dynamicItemLastChange>"
15.126 -
15.127 -#define MSN_GET_ADDRESS_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.128 -"<soap:Envelope"\
15.129 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.130 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.131 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.132 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.133 - "<soap:Header>"\
15.134 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.135 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.136 - "<IsMigration>false</IsMigration>"\
15.137 - "<PartnerScenario>%s</PartnerScenario>"\
15.138 - "</ABApplicationHeader>"\
15.139 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.140 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.141 - "<TicketToken>EMPTY</TicketToken>"\
15.142 - "</ABAuthHeader>"\
15.143 - "</soap:Header>"\
15.144 - "<soap:Body>"\
15.145 - "<ABFindAll xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.146 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.147 - "<abView>Full</abView>"\
15.148 - "%s"\
15.149 - "</ABFindAll>"\
15.150 - "</soap:Body>"\
15.151 -"</soap:Envelope>"
15.152 -
15.153 -
15.154 -/*Gleams SOAP request template*/
15.155 -#define MSN_GET_GLEAMS_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABFindAll"
15.156 -#define MSN_GLEAMS_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.157 -"<soap:Envelope"\
15.158 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.159 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.160 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.161 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.162 - "<soap:Header>"\
15.163 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.164 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.165 - "<IsMigration>false</IsMigration>"\
15.166 - "<PartnerScenario>Initial</PartnerScenario>"\
15.167 - "</ABApplicationHeader>"\
15.168 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.169 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.170 - "<TicketToken>EMPTY</TicketToken>"\
15.171 - "</ABAuthHeader>"\
15.172 - "</soap:Header>"\
15.173 - "<soap:Body>"\
15.174 - "<ABFindAll xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.175 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.176 - "<abView>Full</abView>"\
15.177 - "<dynamicItemView>Gleam</dynamicItemView>"\
15.178 - "<dynamicItemLastChange>0001-01-01T00:00:00.0000000-08:00</dynamicItemLastChange>"\
15.179 - "</ABFindAll>"\
15.180 - "</soap:Body>"\
15.181 -"</soap:Envelope>"
15.182 -
15.183 -
15.184 -/*******************************************************
15.185 - * Contact Management SOAP actions
15.186 - *******************************************************/
15.187 -
15.188 -/* Add a new contact */
15.189 -#define MSN_CONTACT_ADD_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABContactAdd"
15.190 -#define MSN_CONTACT_LIVE_PENDING_XML \
15.191 - "<Contact xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.192 - "<contactInfo>"\
15.193 - "<contactType>LivePending</contactType>"\
15.194 - "<passportName>%s</passportName>"\
15.195 - "<isMessengerUser>true</isMessengerUser>"\
15.196 - "</contactInfo>"\
15.197 - "</Contact>"
15.198 -
15.199 -#define MSN_CONTACT_XML \
15.200 - "<Contact xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.201 - "<contactInfo>"\
15.202 - "<passportName>%s</passportName>"\
15.203 - "<isSmtp>false</isSmtp>"\
15.204 - "<isMessengerUser>true</isMessengerUser>"\
15.205 - "</contactInfo>"\
15.206 - "</Contact>"
15.207 -
15.208 -#define MSN_CONTACT_DISPLAYNAME_XML \
15.209 - "<Contact xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.210 - "<contactInfo>"\
15.211 - "<displayName>%s</displayName>"\
15.212 - "<passportName>%s</passportName>"\
15.213 - "<isMessengerUser>true</isMessengerUser>"\
15.214 - "</contactInfo>"\
15.215 - "</Contact>"
15.216 -
15.217 -#define MSN_CONTACT_ID_XML \
15.218 - "<Contact>"\
15.219 - "<contactId>%s</contactId>"\
15.220 - "</Contact>"
15.221 -
15.222 -#define MSN_CONTACT_EMAIL_XML \
15.223 - "<Contact>"\
15.224 - "<contactInfo>"\
15.225 - "<emails>"\
15.226 - "<ContactEmail>"\
15.227 - "<contactEmailType>%s</contactEmailType>"\
15.228 - "<email>%s</email>"\
15.229 - "<isMessengerEnabled>true</isMessengerEnabled>"\
15.230 - "<Capability>%d</Capability>"\
15.231 - "<MessengerEnabledExternally>false</MessengerEnabledExternally>"\
15.232 - "<propertiesChanged/>"\
15.233 - "</ContactEmail>"\
15.234 - "</emails>"\
15.235 - "</contactInfo>"\
15.236 - "</Contact>"
15.237 -
15.238 -#define MSN_ADD_CONTACT_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.239 -"<soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.240 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.241 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.242 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.243 - "<soap:Header>"\
15.244 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.245 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.246 - "<IsMigration>false</IsMigration>"\
15.247 - "<PartnerScenario>ContactSave</PartnerScenario>"\
15.248 - "</ABApplicationHeader>"\
15.249 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.250 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.251 - "<TicketToken>EMPTY</TicketToken>"\
15.252 - "</ABAuthHeader>"\
15.253 - "</soap:Header>"\
15.254 - "<soap:Body>"\
15.255 - "<ABContactAdd xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.256 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.257 - "<contacts>%s</contacts>"\
15.258 - "<options>"\
15.259 - "<EnableAllowListManagement>true</EnableAllowListManagement>"\
15.260 - "</options>"\
15.261 - "</ABContactAdd>"\
15.262 - "</soap:Body>"\
15.263 -"</soap:Envelope>"
15.264 -
15.265 -/* Add a contact to a group */
15.266 -#define MSN_ADD_CONTACT_GROUP_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABGroupContactAdd"
15.267 -#define MSN_ADD_CONTACT_GROUP_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.268 -"<soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.269 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.270 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.271 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.272 - "<soap:Header>"\
15.273 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.274 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.275 - "<IsMigration>false</IsMigration>"\
15.276 - "<PartnerScenario>ContactSave</PartnerScenario>"\
15.277 - "</ABApplicationHeader>"\
15.278 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.279 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.280 - "<TicketToken>EMPTY</TicketToken>"\
15.281 - "</ABAuthHeader>"\
15.282 - "</soap:Header>"\
15.283 - "<soap:Body>"\
15.284 - "<ABGroupContactAdd xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.285 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.286 - "<groupFilter>"\
15.287 - "<groupIds>"\
15.288 - "<guid>%s</guid>"\
15.289 - "</groupIds>"\
15.290 - "</groupFilter>"\
15.291 - "<contacts>%s</contacts>"\
15.292 - "<groupContactAddOptions>"\
15.293 - "<fGenerateMissingQuickName>true</fGenerateMissingQuickName>"\
15.294 - "<EnableAllowListManagement>true</EnableAllowListManagement>"\
15.295 - "</groupContactAddOptions>"\
15.296 - "</ABGroupContactAdd>"\
15.297 - "</soap:Body>"\
15.298 -"</soap:Envelope>"
15.299 -
15.300 -/* Delete a contact from the Contact List */
15.301 -#define MSN_CONTACT_DEL_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABContactDelete"
15.302 -#define MSN_DEL_CONTACT_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.303 -"<soap:Envelope"\
15.304 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.305 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.306 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.307 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.308 - "<soap:Header>"\
15.309 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.310 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.311 - "<IsMigration>false</IsMigration>"\
15.312 - "<PartnerScenario>Timer</PartnerScenario>"\
15.313 - "</ABApplicationHeader>"\
15.314 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.315 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.316 - "<TicketToken>EMPTY</TicketToken>"\
15.317 - "</ABAuthHeader>"\
15.318 - "</soap:Header>"\
15.319 - "<soap:Body>"\
15.320 - "<ABContactDelete xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.321 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.322 - "<contacts>%s</contacts>"\
15.323 - "</ABContactDelete>"\
15.324 - "</soap:Body>"\
15.325 -"</soap:Envelope>"
15.326 -
15.327 -/* Remove a contact from a group */
15.328 -#define MSN_CONTACT_DEL_GROUP_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABGroupContactDelete"
15.329 -#define MSN_CONTACT_DEL_GROUP_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.330 -"<soap:Envelope"\
15.331 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.332 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.333 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.334 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.335 - "<soap:Header>"\
15.336 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.337 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.338 - "<IsMigration>false</IsMigration>"\
15.339 - "<PartnerScenario>Timer</PartnerScenario>"\
15.340 - "</ABApplicationHeader>"\
15.341 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.342 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.343 - "<TicketToken>EMPTY</TicketToken>"\
15.344 - "</ABAuthHeader>"\
15.345 - "</soap:Header>"\
15.346 - "<soap:Body>"\
15.347 - "<ABGroupContactDelete xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.348 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.349 - "<contacts>%s</contacts>"\
15.350 - "<groupFilter>"\
15.351 - "<groupIds>"\
15.352 - "<guid>%s</guid>"\
15.353 - "</groupIds>"\
15.354 - "</groupFilter>"\
15.355 - "</ABGroupContactDelete>"\
15.356 - "</soap:Body>"\
15.357 -"</soap:Envelope>"
15.358 -
15.359 -
15.360 -/* Update Contact Information */
15.361 -#define MSN_CONTACT_UPDATE_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABContactUpdate"
15.362 -#define MSN_CONTACT_UPDATE_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.363 -"<soap:Envelope"\
15.364 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.365 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.366 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.367 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.368 - "<soap:Header>"\
15.369 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.370 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.371 - "<IsMigration>false</IsMigration>"\
15.372 - "<PartnerScenario>Timer</PartnerScenario>"\
15.373 - "</ABApplicationHeader>"\
15.374 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.375 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.376 - "<TicketToken>EMPTY</TicketToken>"\
15.377 - "</ABAuthHeader>"\
15.378 - "</soap:Header>"\
15.379 - "<soap:Body>"\
15.380 - "<ABContactUpdate xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.381 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.382 - "<contacts>"\
15.383 - "<Contact xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.384 - ""\
15.385 - "</Contact>"\
15.386 - "</contacts>"\
15.387 - "</ABContactUpdate>"\
15.388 - "</soap:Body>"\
15.389 -"</soap:Envelope>"
15.390 -
15.391 -/*******************************************************
15.392 - * Add/Delete contact from lists SOAP actions
15.393 - *******************************************************/
15.394 -
15.395 -/* block means delete from allow list and add contact to block list */
15.396 -#define MSN_SHARE_POST_URL "/abservice/SharingService.asmx"
15.397 -
15.398 -#define MSN_ADD_MEMBER_TO_LIST_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/AddMember"
15.399 -#define MSN_DELETE_MEMBER_FROM_LIST_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/DeleteMember"
15.400 -
15.401 -#define MSN_MEMBER_PASSPORT_XML \
15.402 - "<Member xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:type=\"%s\">"\
15.403 - "<Type>%s</Type>"\
15.404 - "<State>Accepted</State>"\
15.405 - "<%s>%s</%s>"\
15.406 - "</Member>"
15.407 -
15.408 -#define MSN_MEMBER_MEMBERSHIPID_XML \
15.409 - "<Member xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:type=\"%s\">"\
15.410 - "<Type>%s</Type>"\
15.411 - "<MembershipId>%u</MembershipId>"\
15.412 - "<State>Accepted</State>"\
15.413 - "</Member>"
15.414 -
15.415 -/* first delete contact from allow list */
15.416 -
15.417 -#define MSN_CONTACT_DELETE_FROM_LIST_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.418 -"<soap:Envelope"\
15.419 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.420 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.421 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.422 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.423 - "<soap:Header>"\
15.424 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.425 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.426 - "<IsMigration>false</IsMigration>"\
15.427 - "<PartnerScenario>%s</PartnerScenario>"\
15.428 - "</ABApplicationHeader>"\
15.429 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.430 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.431 - "<TicketToken>EMPTY</TicketToken>"\
15.432 - "</ABAuthHeader>"\
15.433 - "</soap:Header>"\
15.434 - "<soap:Body>"\
15.435 - "<DeleteMember xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.436 - "<serviceHandle>"\
15.437 - "<Id>0</Id>"\
15.438 - "<Type>Messenger</Type>"\
15.439 - "<ForeignId></ForeignId>"\
15.440 - "</serviceHandle>"\
15.441 - "<memberships>"\
15.442 - "<Membership>"\
15.443 - "<MemberRole>%s</MemberRole>"\
15.444 - "<Members>"\
15.445 - "%s"\
15.446 - "</Members>"\
15.447 - "</Membership>"\
15.448 - "</memberships>"\
15.449 - "</DeleteMember>"\
15.450 - "</soap:Body>"\
15.451 -"</soap:Envelope>"
15.452 -
15.453 -#define MSN_CONTACT_ADD_TO_LIST_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.454 -"<soap:Envelope"\
15.455 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.456 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.457 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.458 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.459 - "<soap:Header>"\
15.460 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.461 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.462 - "<IsMigration>false</IsMigration>"\
15.463 - "<PartnerScenario>%s</PartnerScenario>"\
15.464 - "</ABApplicationHeader>"\
15.465 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.466 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.467 - "<TicketToken>EMPTY</TicketToken>"\
15.468 - "</ABAuthHeader>"\
15.469 - "</soap:Header>"\
15.470 - "<soap:Body>"\
15.471 - "<AddMember xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.472 - "<serviceHandle>"\
15.473 - "<Id>0</Id>"\
15.474 - "<Type>Messenger</Type>"\
15.475 - "<ForeignId></ForeignId>"\
15.476 - "</serviceHandle>"\
15.477 - "<memberships>"\
15.478 - "<Membership>"\
15.479 - "<MemberRole>%s</MemberRole>"\
15.480 - "<Members>"\
15.481 - "%s"\
15.482 - "</Members>"\
15.483 - "</Membership>"\
15.484 - "</memberships>"\
15.485 - "</AddMember>"\
15.486 - "</soap:Body>"\
15.487 -"</soap:Envelope>"
15.488 -
15.489 -
15.490 -
15.491 -/*******************************************************
15.492 - * Group management SOAP actions
15.493 - *******************************************************/
15.494 -
15.495 -/* add a group */
15.496 -#define MSN_GROUP_ADD_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABGroupAdd"
15.497 -#define MSN_GROUP_ADD_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.498 -"<soap:Envelope"\
15.499 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.500 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.501 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.502 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.503 - "<soap:Header>"\
15.504 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.505 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.506 - "<IsMigration>false</IsMigration>"\
15.507 - "<PartnerScenario>GroupSave</PartnerScenario>"\
15.508 - "</ABApplicationHeader>"\
15.509 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.510 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.511 - "<TicketToken>EMPTY</TicketToken>"\
15.512 - "</ABAuthHeader>"\
15.513 - "</soap:Header>"\
15.514 - "<soap:Body>"\
15.515 - "<ABGroupAdd xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.516 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.517 - "<groupAddOptions>"\
15.518 - "<fRenameOnMsgrConflict>false</fRenameOnMsgrConflict>"\
15.519 - "</groupAddOptions>"\
15.520 - "<groupInfo>"\
15.521 - "<GroupInfo>"\
15.522 - "<name>%s</name>"\
15.523 - "<groupType>C8529CE2-6EAD-434d-881F-341E17DB3FF8</groupType>"\
15.524 - "<fMessenger>false</fMessenger>"\
15.525 - "<annotations>"\
15.526 - "<Annotation>"\
15.527 - "<Name>MSN.IM.Display</Name>"\
15.528 - "<Value>1</Value>"\
15.529 - "</Annotation>"\
15.530 - "</annotations>"\
15.531 - "</GroupInfo>"\
15.532 - "</groupInfo>"\
15.533 - "</ABGroupAdd>"\
15.534 - "</soap:Body>"\
15.535 -"</soap:Envelope>"
15.536 -
15.537 -/* delete a group */
15.538 -#define MSN_GROUP_DEL_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABGroupDelete"
15.539 -#define MSN_GROUP_DEL_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.540 -"<soap:Envelope"\
15.541 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.542 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.543 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.544 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.545 - "<soap:Header>"\
15.546 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.547 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.548 - "<IsMigration>false</IsMigration>"\
15.549 - "<PartnerScenario>Timer</PartnerScenario>"\
15.550 - "</ABApplicationHeader>"\
15.551 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.552 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.553 - "<TicketToken>EMPTY</TicketToken>"\
15.554 - "</ABAuthHeader>"\
15.555 - "</soap:Header>"\
15.556 - "<soap:Body>"\
15.557 - "<ABGroupDelete xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.558 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.559 - "<groupFilter>"\
15.560 - "<groupIds>"\
15.561 - "<guid>%s</guid>"\
15.562 - "</groupIds>"\
15.563 - "</groupFilter>"\
15.564 - "</ABGroupDelete>"\
15.565 - "</soap:Body>"\
15.566 -"</soap:Envelope>"
15.567 -
15.568 -/* change a group's name */
15.569 -#define MSN_GROUP_RENAME_SOAP_ACTION "http://www.msn.com/webservices/AddressBook/ABGroupUpdate"
15.570 -#define MSN_GROUP_RENAME_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
15.571 -"<soap:Envelope"\
15.572 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\""\
15.573 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
15.574 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
15.575 - " xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\">"\
15.576 - "<soap:Header>"\
15.577 - "<ABApplicationHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.578 - "<ApplicationId>" MSN_APPLICATION_ID "</ApplicationId>"\
15.579 - "<IsMigration>false</IsMigration>"\
15.580 - "<PartnerScenario>Timer</PartnerScenario>"\
15.581 - "</ABApplicationHeader>"\
15.582 - "<ABAuthHeader xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.583 - "<ManagedGroupRequest>false</ManagedGroupRequest>"\
15.584 - "<TicketToken>EMPTY</TicketToken>"\
15.585 - "</ABAuthHeader>"\
15.586 - "</soap:Header>"\
15.587 - "<soap:Body>"\
15.588 - "<ABGroupUpdate xmlns=\"http://www.msn.com/webservices/AddressBook\">"\
15.589 - "<abId>00000000-0000-0000-0000-000000000000</abId>"\
15.590 - "<groups>"\
15.591 - "<Group>"\
15.592 - "<groupId>%s</groupId>"\
15.593 - "<groupInfo>"\
15.594 - "<name>%s</name>"\
15.595 - "</groupInfo>"\
15.596 - "<propertiesChanged>GroupName </propertiesChanged>"\
15.597 - "</Group>"\
15.598 - "</groups>"\
15.599 - "</ABGroupUpdate>"\
15.600 - "</soap:Body>"\
15.601 -"</soap:Envelope>"
15.602 -
15.603 -typedef enum
15.604 -{
15.605 - MSN_ADD_BUDDY = 0x01,
15.606 - MSN_MOVE_BUDDY = 0x02,
15.607 - MSN_ACCEPTED_BUDDY = 0x04,
15.608 - MSN_DENIED_BUDDY = 0x08,
15.609 - MSN_ADD_GROUP = 0x10,
15.610 - MSN_DEL_GROUP = 0x20,
15.611 - MSN_RENAME_GROUP = 0x40,
15.612 - MSN_UPDATE_INFO = 0x80
15.613 -} MsnCallbackAction;
15.614 -
15.615 -typedef enum
15.616 -{
15.617 - MSN_PS_INITIAL,
15.618 - MSN_PS_SAVE_CONTACT,
15.619 - MSN_PS_PENDING_LIST,
15.620 - MSN_PS_CONTACT_API,
15.621 - MSN_PS_BLOCK_UNBLOCK
15.622 -} MsnSoapPartnerScenario;
15.623 -
15.624 -typedef struct _MsnCallbackState MsnCallbackState;
15.625 -
15.626 -struct _MsnCallbackState
15.627 -{
15.628 - gchar * who;
15.629 - gchar * uid;
15.630 - gchar * old_group_name;
15.631 - gchar * new_group_name;
15.632 - gchar * guid;
15.633 - MsnListId list_id;
15.634 - MsnCallbackAction action;
15.635 - MsnSession *session;
15.636 - xmlnode *body;
15.637 - xmlnode *token;
15.638 - const gchar *post_action;
15.639 - const gchar *post_url;
15.640 - MsnSoapCallback cb;
15.641 - /* For msn_get_contact_list only */
15.642 - MsnSoapPartnerScenario partner_scenario;
15.643 -};
15.644 -
15.645 -typedef enum
15.646 -{
15.647 - MSN_UPDATE_DISPLAY, /* Real display name */
15.648 - MSN_UPDATE_ALIAS, /* Aliased display name */
15.649 - MSN_UPDATE_COMMENT
15.650 -} MsnContactUpdateType;
15.651 -
15.652 -/************************************************
15.653 - * function prototype
15.654 - ************************************************/
15.655 -MsnCallbackState * msn_callback_state_new(MsnSession *session);
15.656 -MsnCallbackState * msn_callback_state_dup(MsnCallbackState *state);
15.657 -void msn_callback_state_free(MsnCallbackState *state);
15.658 -void msn_callback_state_set_who(MsnCallbackState *state, const gchar *who);
15.659 -void msn_callback_state_set_uid(MsnCallbackState *state, const gchar *uid);
15.660 -void msn_callback_state_set_old_group_name(MsnCallbackState *state,
15.661 - const gchar *old_group_name);
15.662 -void msn_callback_state_set_new_group_name(MsnCallbackState *state,
15.663 - const gchar *new_group_name);
15.664 -void msn_callback_state_set_guid(MsnCallbackState *state, const gchar *guid);
15.665 -void msn_callback_state_set_list_id(MsnCallbackState *state, MsnListId list_id);
15.666 -void msn_callback_state_set_action(MsnCallbackState *state,
15.667 - MsnCallbackAction action);
15.668 -
15.669 -void msn_contact_connect(MsnSession *session);
15.670 -void msn_get_contact_list(MsnSession *session,
15.671 - const MsnSoapPartnerScenario partner_scenario,
15.672 - const char *update);
15.673 -void msn_get_address_book(MsnSession *session,
15.674 - const MsnSoapPartnerScenario partner_scenario,
15.675 - const char * update, const char * gupdate);
15.676 -
15.677 -/* contact SOAP operations */
15.678 -void msn_update_contact(MsnSession *session, const char *passport, MsnContactUpdateType type, const char* value);
15.679 -
15.680 -void msn_add_contact(MsnSession *session, MsnCallbackState *state,
15.681 - const char *passport);
15.682 -void msn_delete_contact(MsnSession *session, MsnUser *user);
15.683 -
15.684 -void msn_add_contact_to_group(MsnSession *session, MsnCallbackState *state,
15.685 - const char *passport, const char *groupId);
15.686 -void msn_del_contact_from_group(MsnSession *session, const char *passport,
15.687 - const char *group_name);
15.688 -/* group operations */
15.689 -void msn_add_group(MsnSession *session, MsnCallbackState *state,
15.690 - const char* group_name);
15.691 -void msn_del_group(MsnSession *session, const gchar *group_name);
15.692 -void msn_contact_rename_group(MsnSession *session, const char *old_group_name,
15.693 - const char *new_group_name);
15.694 -
15.695 -/* lists operations */
15.696 -void msn_add_contact_to_list(MsnSession *session, MsnCallbackState *state,
15.697 - const gchar *passport, const MsnListId list);
15.698 -void msn_del_contact_from_list(MsnSession *session, MsnCallbackState *state,
15.699 - const gchar *passport, const MsnListId list);
15.700 -
15.701 -#endif /* _MSN_CONTACT_H_ */
15.702 -
16.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/conversation.h Sun Jun 21 22:04:11 2009 -0400
16.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
16.3 @@ -1,1407 +0,0 @@
16.4 -/**
16.5 - * @file conversation.h Conversation API
16.6 - * @ingroup core
16.7 - * @see @ref conversation-signals
16.8 - */
16.9 -
16.10 -/* purple
16.11 - *
16.12 - * Purple is the legal property of its developers, whose names are too numerous
16.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
16.14 - * source distribution.
16.15 - *
16.16 - * This program is free software; you can redistribute it and/or modify
16.17 - * it under the terms of the GNU General Public License as published by
16.18 - * the Free Software Foundation; either version 2 of the License, or
16.19 - * (at your option) any later version.
16.20 - *
16.21 - * This program is distributed in the hope that it will be useful,
16.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
16.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16.24 - * GNU General Public License for more details.
16.25 - *
16.26 - * You should have received a copy of the GNU General Public License
16.27 - * along with this program; if not, write to the Free Software
16.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
16.29 - */
16.30 -#ifndef _PURPLE_CONVERSATION_H_
16.31 -#define _PURPLE_CONVERSATION_H_
16.32 -
16.33 -/**************************************************************************/
16.34 -/** Data Structures */
16.35 -/**************************************************************************/
16.36 -
16.37 -
16.38 -/** @copydoc _PurpleConversationUiOps */
16.39 -typedef struct _PurpleConversationUiOps PurpleConversationUiOps;
16.40 -/** @copydoc _PurpleConversation */
16.41 -typedef struct _PurpleConversation PurpleConversation;
16.42 -/** @copydoc _PurpleConvIm */
16.43 -typedef struct _PurpleConvIm PurpleConvIm;
16.44 -/** @copydoc _PurpleConvChat */
16.45 -typedef struct _PurpleConvChat PurpleConvChat;
16.46 -/** @copydoc _PurpleConvChatBuddy */
16.47 -typedef struct _PurpleConvChatBuddy PurpleConvChatBuddy;
16.48 -/** @copydoc _PurpleConvMessage */
16.49 -typedef struct _PurpleConvMessage PurpleConvMessage;
16.50 -
16.51 -/**
16.52 - * A type of conversation.
16.53 - */
16.54 -typedef enum
16.55 -{
16.56 - PURPLE_CONV_TYPE_UNKNOWN = 0, /**< Unknown conversation type. */
16.57 - PURPLE_CONV_TYPE_IM, /**< Instant Message. */
16.58 - PURPLE_CONV_TYPE_CHAT, /**< Chat room. */
16.59 - PURPLE_CONV_TYPE_MISC, /**< A misc. conversation. */
16.60 - PURPLE_CONV_TYPE_ANY /**< Any type of conversation. */
16.61 -
16.62 -} PurpleConversationType;
16.63 -
16.64 -/**
16.65 - * Conversation update type.
16.66 - */
16.67 -typedef enum
16.68 -{
16.69 - PURPLE_CONV_UPDATE_ADD = 0, /**< The buddy associated with the conversation
16.70 - was added. */
16.71 - PURPLE_CONV_UPDATE_REMOVE, /**< The buddy associated with the conversation
16.72 - was removed. */
16.73 - PURPLE_CONV_UPDATE_ACCOUNT, /**< The purple_account was changed. */
16.74 - PURPLE_CONV_UPDATE_TYPING, /**< The typing state was updated. */
16.75 - PURPLE_CONV_UPDATE_UNSEEN, /**< The unseen state was updated. */
16.76 - PURPLE_CONV_UPDATE_LOGGING, /**< Logging for this conversation was
16.77 - enabled or disabled. */
16.78 - PURPLE_CONV_UPDATE_TOPIC, /**< The topic for a chat was updated. */
16.79 - /*
16.80 - * XXX These need to go when we implement a more generic core/UI event
16.81 - * system.
16.82 - */
16.83 - PURPLE_CONV_ACCOUNT_ONLINE, /**< One of the user's accounts went online. */
16.84 - PURPLE_CONV_ACCOUNT_OFFLINE, /**< One of the user's accounts went offline. */
16.85 - PURPLE_CONV_UPDATE_AWAY, /**< The other user went away. */
16.86 - PURPLE_CONV_UPDATE_ICON, /**< The other user's buddy icon changed. */
16.87 - PURPLE_CONV_UPDATE_TITLE,
16.88 - PURPLE_CONV_UPDATE_CHATLEFT,
16.89 -
16.90 - PURPLE_CONV_UPDATE_FEATURES /**< The features for a chat have changed */
16.91 -
16.92 -} PurpleConvUpdateType;
16.93 -
16.94 -/**
16.95 - * The typing state of a user.
16.96 - */
16.97 -typedef enum
16.98 -{
16.99 - PURPLE_NOT_TYPING = 0, /**< Not typing. */
16.100 - PURPLE_TYPING, /**< Currently typing. */
16.101 - PURPLE_TYPED /**< Stopped typing momentarily. */
16.102 -
16.103 -} PurpleTypingState;
16.104 -
16.105 -/**
16.106 - * Flags applicable to a message. Most will have send, recv or system.
16.107 - */
16.108 -typedef enum
16.109 -{
16.110 - PURPLE_MESSAGE_SEND = 0x0001, /**< Outgoing message. */
16.111 - PURPLE_MESSAGE_RECV = 0x0002, /**< Incoming message. */
16.112 - PURPLE_MESSAGE_SYSTEM = 0x0004, /**< System message. */
16.113 - PURPLE_MESSAGE_AUTO_RESP = 0x0008, /**< Auto response. */
16.114 - PURPLE_MESSAGE_ACTIVE_ONLY = 0x0010, /**< Hint to the UI that this
16.115 - message should not be
16.116 - shown in conversations
16.117 - which are only open for
16.118 - internal UI purposes
16.119 - (e.g. for contact-aware
16.120 - conversations). */
16.121 - PURPLE_MESSAGE_NICK = 0x0020, /**< Contains your nick. */
16.122 - PURPLE_MESSAGE_NO_LOG = 0x0040, /**< Do not log. */
16.123 - PURPLE_MESSAGE_WHISPER = 0x0080, /**< Whispered message. */
16.124 - PURPLE_MESSAGE_ERROR = 0x0200, /**< Error message. */
16.125 - PURPLE_MESSAGE_DELAYED = 0x0400, /**< Delayed message. */
16.126 - PURPLE_MESSAGE_RAW = 0x0800, /**< "Raw" message - don't
16.127 - apply formatting */
16.128 - PURPLE_MESSAGE_IMAGES = 0x1000, /**< Message contains images */
16.129 - PURPLE_MESSAGE_NOTIFY = 0x2000, /**< Message is a notification */
16.130 - PURPLE_MESSAGE_NO_LINKIFY = 0x4000, /**< Message should not be auto-
16.131 - linkified @since 2.1.0 */
16.132 - PURPLE_MESSAGE_INVISIBLE = 0x8000 /**< Message should not be displayed */
16.133 -} PurpleMessageFlags;
16.134 -
16.135 -/**
16.136 - * Flags applicable to users in Chats.
16.137 - */
16.138 -typedef enum
16.139 -{
16.140 - PURPLE_CBFLAGS_NONE = 0x0000, /**< No flags */
16.141 - PURPLE_CBFLAGS_VOICE = 0x0001, /**< Voiced user or "Participant" */
16.142 - PURPLE_CBFLAGS_HALFOP = 0x0002, /**< Half-op */
16.143 - PURPLE_CBFLAGS_OP = 0x0004, /**< Channel Op or Moderator */
16.144 - PURPLE_CBFLAGS_FOUNDER = 0x0008, /**< Channel Founder */
16.145 - PURPLE_CBFLAGS_TYPING = 0x0010 /**< Currently typing */
16.146 -
16.147 -} PurpleConvChatBuddyFlags;
16.148 -
16.149 -#include "account.h"
16.150 -#include "buddyicon.h"
16.151 -#include "log.h"
16.152 -#include "server.h"
16.153 -
16.154 -/**
16.155 - * Conversation operations and events.
16.156 - *
16.157 - * Any UI representing a conversation must assign a filled-out
16.158 - * PurpleConversationUiOps structure to the PurpleConversation.
16.159 - */
16.160 -struct _PurpleConversationUiOps
16.161 -{
16.162 - /** Called when @a conv is created (but before the @ref
16.163 - * conversation-created signal is emitted).
16.164 - */
16.165 - void (*create_conversation)(PurpleConversation *conv);
16.166 -
16.167 - /** Called just before @a conv is freed. */
16.168 - void (*destroy_conversation)(PurpleConversation *conv);
16.169 - /** Write a message to a chat. If this field is @c NULL, libpurple will
16.170 - * fall back to using #write_conv.
16.171 - * @see purple_conv_chat_write()
16.172 - */
16.173 - void (*write_chat)(PurpleConversation *conv, const char *who,
16.174 - const char *message, PurpleMessageFlags flags,
16.175 - time_t mtime);
16.176 - /** Write a message to an IM conversation. If this field is @c NULL,
16.177 - * libpurple will fall back to using #write_conv.
16.178 - * @see purple_conv_im_write()
16.179 - */
16.180 - void (*write_im)(PurpleConversation *conv, const char *who,
16.181 - const char *message, PurpleMessageFlags flags,
16.182 - time_t mtime);
16.183 - /** Write a message to a conversation. This is used rather than the
16.184 - * chat- or im-specific ops for errors, system messages (such as "x is
16.185 - * now know as y"), and as the fallback if #write_im and #write_chat
16.186 - * are not implemented. It should be implemented, or the UI will miss
16.187 - * conversation error messages and your users will hate you.
16.188 - *
16.189 - * @see purple_conversation_write()
16.190 - */
16.191 - void (*write_conv)(PurpleConversation *conv,
16.192 - const char *name,
16.193 - const char *alias,
16.194 - const char *message,
16.195 - PurpleMessageFlags flags,
16.196 - time_t mtime);
16.197 -
16.198 - /** Add @a cbuddies to a chat.
16.199 - * @param cbuddies A @c GList of #PurpleConvChatBuddy structs.
16.200 - * @param new_arrivals Whether join notices should be shown.
16.201 - * (Join notices are actually written to the
16.202 - * conversation by #purple_conv_chat_add_users().)
16.203 - */
16.204 - void (*chat_add_users)(PurpleConversation *conv,
16.205 - GList *cbuddies,
16.206 - gboolean new_arrivals);
16.207 - /** Rename the user in this chat named @a old_name to @a new_name. (The
16.208 - * rename message is written to the conversation by libpurple.)
16.209 - * @param new_alias @a new_name's new alias, if they have one.
16.210 - * @see purple_conv_chat_add_users()
16.211 - */
16.212 - void (*chat_rename_user)(PurpleConversation *conv, const char *old_name,
16.213 - const char *new_name, const char *new_alias);
16.214 - /** Remove @a users from a chat.
16.215 - * @param users A @c GList of <tt>const char *</tt>s.
16.216 - * @see purple_conv_chat_rename_user()
16.217 - */
16.218 - void (*chat_remove_users)(PurpleConversation *conv, GList *users);
16.219 - /** Called when a user's flags are changed.
16.220 - * @see purple_conv_chat_user_set_flags()
16.221 - */
16.222 - void (*chat_update_user)(PurpleConversation *conv, const char *user);
16.223 -
16.224 - /** Present this conversation to the user; for example, by displaying
16.225 - * the IM dialog.
16.226 - */
16.227 - void (*present)(PurpleConversation *conv);
16.228 -
16.229 - /** If this UI has a concept of focus (as in a windowing system) and
16.230 - * this conversation has the focus, return @c TRUE; otherwise, return
16.231 - * @c FALSE.
16.232 - */
16.233 - gboolean (*has_focus)(PurpleConversation *conv);
16.234 -
16.235 - /* Custom Smileys */
16.236 - gboolean (*custom_smiley_add)(PurpleConversation *conv, const char *smile, gboolean remote);
16.237 - void (*custom_smiley_write)(PurpleConversation *conv, const char *smile,
16.238 - const guchar *data, gsize size);
16.239 - void (*custom_smiley_close)(PurpleConversation *conv, const char *smile);
16.240 -
16.241 - /** Prompt the user for confirmation to send @a message. This function
16.242 - * should arrange for the message to be sent if the user accepts. If
16.243 - * this field is @c NULL, libpurple will fall back to using
16.244 - * #purple_request_action().
16.245 - */
16.246 - void (*send_confirm)(PurpleConversation *conv, const char *message);
16.247 -
16.248 - void (*_purple_reserved1)(void);
16.249 - void (*_purple_reserved2)(void);
16.250 - void (*_purple_reserved3)(void);
16.251 - void (*_purple_reserved4)(void);
16.252 -};
16.253 -
16.254 -/**
16.255 - * Data specific to Instant Messages.
16.256 - */
16.257 -struct _PurpleConvIm
16.258 -{
16.259 - PurpleConversation *conv; /**< The parent conversation. */
16.260 -
16.261 - PurpleTypingState typing_state; /**< The current typing state. */
16.262 - guint typing_timeout; /**< The typing timer handle. */
16.263 - time_t type_again; /**< The type again time. */
16.264 - guint send_typed_timeout; /**< The type again timer handle. */
16.265 -
16.266 - PurpleBuddyIcon *icon; /**< The buddy icon. */
16.267 -};
16.268 -
16.269 -/**
16.270 - * Data specific to Chats.
16.271 - */
16.272 -struct _PurpleConvChat
16.273 -{
16.274 - PurpleConversation *conv; /**< The parent conversation. */
16.275 -
16.276 - GList *in_room; /**< The users in the room. */
16.277 - GList *ignored; /**< Ignored users. */
16.278 - char *who; /**< The person who set the topic. */
16.279 - char *topic; /**< The topic. */
16.280 - int id; /**< The chat ID. */
16.281 - char *nick; /**< Your nick in this chat. */
16.282 -
16.283 - gboolean left; /**< We left the chat and kept the window open */
16.284 -};
16.285 -
16.286 -/**
16.287 - * Data for "Chat Buddies"
16.288 - */
16.289 -struct _PurpleConvChatBuddy
16.290 -{
16.291 - char *name; /**< The chat participant's name in the chat. */
16.292 - char *alias; /**< The chat participant's alias, if known;
16.293 - * @a NULL otherwise.
16.294 - */
16.295 - char *alias_key; /**< A string by which this buddy will be sorted,
16.296 - * or @c NULL if the buddy should be sorted by
16.297 - * its @c name. (This is currently always @c
16.298 - * NULL.)
16.299 - */
16.300 - gboolean buddy; /**< @a TRUE if this chat participant is on the
16.301 - * buddy list; @a FALSE otherwise.
16.302 - */
16.303 - PurpleConvChatBuddyFlags flags; /**< A bitwise OR of flags for this participant,
16.304 - * such as whether they are a channel operator.
16.305 - */
16.306 -};
16.307 -
16.308 -/**
16.309 - * Description of a conversation message
16.310 - *
16.311 - * @since 2.2.0
16.312 - */
16.313 -struct _PurpleConvMessage
16.314 -{
16.315 - char *who;
16.316 - char *what;
16.317 - PurpleMessageFlags flags;
16.318 - time_t when;
16.319 - PurpleConversation *conv; /**< @since 2.3.0 */
16.320 - char *alias; /**< @since 2.3.0 */
16.321 -};
16.322 -
16.323 -/**
16.324 - * A core representation of a conversation between two or more people.
16.325 - *
16.326 - * The conversation can be an IM or a chat.
16.327 - */
16.328 -struct _PurpleConversation
16.329 -{
16.330 - PurpleConversationType type; /**< The type of conversation. */
16.331 -
16.332 - PurpleAccount *account; /**< The user using this conversation. */
16.333 -
16.334 -
16.335 - char *name; /**< The name of the conversation. */
16.336 - char *title; /**< The window title. */
16.337 -
16.338 - gboolean logging; /**< The status of logging. */
16.339 -
16.340 - GList *logs; /**< This conversation's logs */
16.341 -
16.342 - union
16.343 - {
16.344 - PurpleConvIm *im; /**< IM-specific data. */
16.345 - PurpleConvChat *chat; /**< Chat-specific data. */
16.346 - void *misc; /**< Misc. data. */
16.347 -
16.348 - } u;
16.349 -
16.350 - PurpleConversationUiOps *ui_ops; /**< UI-specific operations. */
16.351 - void *ui_data; /**< UI-specific data. */
16.352 -
16.353 - GHashTable *data; /**< Plugin-specific data. */
16.354 -
16.355 - PurpleConnectionFlags features; /**< The supported features */
16.356 - GList *message_history; /**< Message history, as a GList of PurpleConvMessage's */
16.357 -};
16.358 -
16.359 -#ifdef __cplusplus
16.360 -extern "C" {
16.361 -#endif
16.362 -
16.363 -/**************************************************************************/
16.364 -/** @name Conversation API */
16.365 -/**************************************************************************/
16.366 -/*@{*/
16.367 -
16.368 -/**
16.369 - * Creates a new conversation of the specified type.
16.370 - *
16.371 - * @param type The type of conversation.
16.372 - * @param account The account opening the conversation window on the purple
16.373 - * user's end.
16.374 - * @param name The name of the conversation.
16.375 - *
16.376 - * @return The new conversation.
16.377 - */
16.378 -PurpleConversation *purple_conversation_new(PurpleConversationType type,
16.379 - PurpleAccount *account,
16.380 - const char *name);
16.381 -
16.382 -/**
16.383 - * Destroys the specified conversation and removes it from the parent
16.384 - * window.
16.385 - *
16.386 - * If this conversation is the only one contained in the parent window,
16.387 - * that window is also destroyed.
16.388 - *
16.389 - * @param conv The conversation to destroy.
16.390 - */
16.391 -void purple_conversation_destroy(PurpleConversation *conv);
16.392 -
16.393 -
16.394 -/**
16.395 - * Present a conversation to the user. This allows core code to initiate a
16.396 - * conversation by displaying the IM dialog.
16.397 - * @param conv The conversation to present
16.398 - */
16.399 -void purple_conversation_present(PurpleConversation *conv);
16.400 -
16.401 -
16.402 -/**
16.403 - * Returns the specified conversation's type.
16.404 - *
16.405 - * @param conv The conversation.
16.406 - *
16.407 - * @return The conversation's type.
16.408 - */
16.409 -PurpleConversationType purple_conversation_get_type(const PurpleConversation *conv);
16.410 -
16.411 -/**
16.412 - * Sets the specified conversation's UI operations structure.
16.413 - *
16.414 - * @param conv The conversation.
16.415 - * @param ops The UI conversation operations structure.
16.416 - */
16.417 -void purple_conversation_set_ui_ops(PurpleConversation *conv,
16.418 - PurpleConversationUiOps *ops);
16.419 -
16.420 -/**
16.421 - * Sets the default conversation UI operations structure.
16.422 - *
16.423 - * @param ops The UI conversation operations structure.
16.424 - */
16.425 -void purple_conversations_set_ui_ops(PurpleConversationUiOps *ops);
16.426 -
16.427 -/**
16.428 - * Returns the specified conversation's UI operations structure.
16.429 - *
16.430 - * @param conv The conversation.
16.431 - *
16.432 - * @return The operations structure.
16.433 - */
16.434 -PurpleConversationUiOps *purple_conversation_get_ui_ops(
16.435 - const PurpleConversation *conv);
16.436 -
16.437 -/**
16.438 - * Sets the specified conversation's purple_account.
16.439 - *
16.440 - * This purple_account represents the user using purple, not the person the user
16.441 - * is having a conversation/chat/flame with.
16.442 - *
16.443 - * @param conv The conversation.
16.444 - * @param account The purple_account.
16.445 - */
16.446 -void purple_conversation_set_account(PurpleConversation *conv,
16.447 - PurpleAccount *account);
16.448 -
16.449 -/**
16.450 - * Returns the specified conversation's purple_account.
16.451 - *
16.452 - * This purple_account represents the user using purple, not the person the user
16.453 - * is having a conversation/chat/flame with.
16.454 - *
16.455 - * @param conv The conversation.
16.456 - *
16.457 - * @return The conversation's purple_account.
16.458 - */
16.459 -PurpleAccount *purple_conversation_get_account(const PurpleConversation *conv);
16.460 -
16.461 -/**
16.462 - * Returns the specified conversation's purple_connection.
16.463 - *
16.464 - * This is the same as purple_conversation_get_user(conv)->gc.
16.465 - *
16.466 - * @param conv The conversation.
16.467 - *
16.468 - * @return The conversation's purple_connection.
16.469 - */
16.470 -PurpleConnection *purple_conversation_get_gc(const PurpleConversation *conv);
16.471 -
16.472 -/**
16.473 - * Sets the specified conversation's title.
16.474 - *
16.475 - * @param conv The conversation.
16.476 - * @param title The title.
16.477 - */
16.478 -void purple_conversation_set_title(PurpleConversation *conv, const char *title);
16.479 -
16.480 -/**
16.481 - * Returns the specified conversation's title.
16.482 - *
16.483 - * @param conv The conversation.
16.484 - *
16.485 - * @return The title.
16.486 - */
16.487 -const char *purple_conversation_get_title(const PurpleConversation *conv);
16.488 -
16.489 -/**
16.490 - * Automatically sets the specified conversation's title.
16.491 - *
16.492 - * This function takes OPT_IM_ALIAS_TAB into account, as well as the
16.493 - * user's alias.
16.494 - *
16.495 - * @param conv The conversation.
16.496 - */
16.497 -void purple_conversation_autoset_title(PurpleConversation *conv);
16.498 -
16.499 -/**
16.500 - * Sets the specified conversation's name.
16.501 - *
16.502 - * @param conv The conversation.
16.503 - * @param name The conversation's name.
16.504 - */
16.505 -void purple_conversation_set_name(PurpleConversation *conv, const char *name);
16.506 -
16.507 -/**
16.508 - * Returns the specified conversation's name.
16.509 - *
16.510 - * @param conv The conversation.
16.511 - *
16.512 - * @return The conversation's name. If the conversation is an IM with a PurpleBuddy,
16.513 - * then it's the name of the PurpleBuddy.
16.514 - */
16.515 -const char *purple_conversation_get_name(const PurpleConversation *conv);
16.516 -
16.517 -/**
16.518 - * Enables or disables logging for this conversation.
16.519 - *
16.520 - * @param conv The conversation.
16.521 - * @param log @c TRUE if logging should be enabled, or @c FALSE otherwise.
16.522 - */
16.523 -void purple_conversation_set_logging(PurpleConversation *conv, gboolean log);
16.524 -
16.525 -/**
16.526 - * Returns whether or not logging is enabled for this conversation.
16.527 - *
16.528 - * @param conv The conversation.
16.529 - *
16.530 - * @return @c TRUE if logging is enabled, or @c FALSE otherwise.
16.531 - */
16.532 -gboolean purple_conversation_is_logging(const PurpleConversation *conv);
16.533 -
16.534 -/**
16.535 - * Closes any open logs for this conversation.
16.536 - *
16.537 - * Note that new logs will be opened as necessary (e.g. upon receipt of a
16.538 - * message, if the conversation has logging enabled. To disable logging for
16.539 - * the remainder of the conversation, use purple_conversation_set_logging().
16.540 - *
16.541 - * @param conv The conversation.
16.542 - */
16.543 -void purple_conversation_close_logs(PurpleConversation *conv);
16.544 -
16.545 -/**
16.546 - * Returns the specified conversation's IM-specific data.
16.547 - *
16.548 - * If the conversation type is not PURPLE_CONV_TYPE_IM, this will return @c NULL.
16.549 - *
16.550 - * @param conv The conversation.
16.551 - *
16.552 - * @return The IM-specific data.
16.553 - */
16.554 -PurpleConvIm *purple_conversation_get_im_data(const PurpleConversation *conv);
16.555 -
16.556 -#define PURPLE_CONV_IM(c) (purple_conversation_get_im_data(c))
16.557 -
16.558 -/**
16.559 - * Returns the specified conversation's chat-specific data.
16.560 - *
16.561 - * If the conversation type is not PURPLE_CONV_TYPE_CHAT, this will return @c NULL.
16.562 - *
16.563 - * @param conv The conversation.
16.564 - *
16.565 - * @return The chat-specific data.
16.566 - */
16.567 -PurpleConvChat *purple_conversation_get_chat_data(const PurpleConversation *conv);
16.568 -
16.569 -#define PURPLE_CONV_CHAT(c) (purple_conversation_get_chat_data(c))
16.570 -
16.571 -/**
16.572 - * Sets extra data for a conversation.
16.573 - *
16.574 - * @param conv The conversation.
16.575 - * @param key The unique key.
16.576 - * @param data The data to assign.
16.577 - */
16.578 -void purple_conversation_set_data(PurpleConversation *conv, const char *key,
16.579 - gpointer data);
16.580 -
16.581 -/**
16.582 - * Returns extra data in a conversation.
16.583 - *
16.584 - * @param conv The conversation.
16.585 - * @param key The unqiue key.
16.586 - *
16.587 - * @return The data associated with the key.
16.588 - */
16.589 -gpointer purple_conversation_get_data(PurpleConversation *conv, const char *key);
16.590 -
16.591 -/**
16.592 - * Returns a list of all conversations.
16.593 - *
16.594 - * This list includes both IMs and chats.
16.595 - *
16.596 - * @constreturn A GList of all conversations.
16.597 - */
16.598 -GList *purple_get_conversations(void);
16.599 -
16.600 -/**
16.601 - * Returns a list of all IMs.
16.602 - *
16.603 - * @constreturn A GList of all IMs.
16.604 - */
16.605 -GList *purple_get_ims(void);
16.606 -
16.607 -/**
16.608 - * Returns a list of all chats.
16.609 - *
16.610 - * @constreturn A GList of all chats.
16.611 - */
16.612 -GList *purple_get_chats(void);
16.613 -
16.614 -/**
16.615 - * Finds a conversation with the specified type, name, and Purple account.
16.616 - *
16.617 - * @param type The type of the conversation.
16.618 - * @param name The name of the conversation.
16.619 - * @param account The purple_account associated with the conversation.
16.620 - *
16.621 - * @return The conversation if found, or @c NULL otherwise.
16.622 - */
16.623 -PurpleConversation *purple_find_conversation_with_account(
16.624 - PurpleConversationType type, const char *name,
16.625 - const PurpleAccount *account);
16.626 -
16.627 -/**
16.628 - * Writes to a conversation window.
16.629 - *
16.630 - * This function should not be used to write IM or chat messages. Use
16.631 - * purple_conv_im_write() and purple_conv_chat_write() instead. Those functions will
16.632 - * most likely call this anyway, but they may do their own formatting,
16.633 - * sound playback, etc.
16.634 - *
16.635 - * This can be used to write generic messages, such as "so and so closed
16.636 - * the conversation window."
16.637 - *
16.638 - * @param conv The conversation.
16.639 - * @param who The user who sent the message.
16.640 - * @param message The message.
16.641 - * @param flags The message flags.
16.642 - * @param mtime The time the message was sent.
16.643 - *
16.644 - * @see purple_conv_im_write()
16.645 - * @see purple_conv_chat_write()
16.646 - */
16.647 -void purple_conversation_write(PurpleConversation *conv, const char *who,
16.648 - const char *message, PurpleMessageFlags flags,
16.649 - time_t mtime);
16.650 -
16.651 -
16.652 -/**
16.653 - Set the features as supported for the given conversation.
16.654 - @param conv The conversation
16.655 - @param features Bitset defining supported features
16.656 -*/
16.657 -void purple_conversation_set_features(PurpleConversation *conv,
16.658 - PurpleConnectionFlags features);
16.659 -
16.660 -
16.661 -/**
16.662 - Get the features supported by the given conversation.
16.663 - @param conv The conversation
16.664 -*/
16.665 -PurpleConnectionFlags purple_conversation_get_features(PurpleConversation *conv);
16.666 -
16.667 -/**
16.668 - * Determines if a conversation has focus
16.669 - *
16.670 - * @param conv The conversation.
16.671 - *
16.672 - * @return @c TRUE if the conversation has focus, @c FALSE if
16.673 - * it does not or the UI does not have a concept of conversation focus
16.674 - */
16.675 -gboolean purple_conversation_has_focus(PurpleConversation *conv);
16.676 -
16.677 -/**
16.678 - * Updates the visual status and UI of a conversation.
16.679 - *
16.680 - * @param conv The conversation.
16.681 - * @param type The update type.
16.682 - */
16.683 -void purple_conversation_update(PurpleConversation *conv, PurpleConvUpdateType type);
16.684 -
16.685 -/**
16.686 - * Calls a function on each conversation.
16.687 - *
16.688 - * @param func The function.
16.689 - */
16.690 -void purple_conversation_foreach(void (*func)(PurpleConversation *conv));
16.691 -
16.692 -/**
16.693 - * Retrieve the message history of a conversation.
16.694 - *
16.695 - * @param conv The conversation
16.696 - *
16.697 - * @return A GList of PurpleConvMessage's. The must not modify the list or the data within.
16.698 - * The list contains the newest message at the beginning, and the oldest message at
16.699 - * the end.
16.700 - *
16.701 - * @since 2.2.0
16.702 - */
16.703 -GList *purple_conversation_get_message_history(PurpleConversation *conv);
16.704 -
16.705 -/**
16.706 - * Clear the message history of a conversation.
16.707 - *
16.708 - * @param conv The conversation
16.709 - *
16.710 - * @since 2.2.0
16.711 - */
16.712 -void purple_conversation_clear_message_history(PurpleConversation *conv);
16.713 -
16.714 -/**
16.715 - * Get the sender from a PurpleConvMessage
16.716 - *
16.717 - * @param msg A PurpleConvMessage
16.718 - *
16.719 - * @return The name of the sender of the message
16.720 - *
16.721 - * @since 2.2.0
16.722 - */
16.723 -const char *purple_conversation_message_get_sender(PurpleConvMessage *msg);
16.724 -
16.725 -/**
16.726 - * Get the message from a PurpleConvMessage
16.727 - *
16.728 - * @param msg A PurpleConvMessage
16.729 - *
16.730 - * @return The name of the sender of the message
16.731 - *
16.732 - * @since 2.2.0
16.733 - */
16.734 -const char *purple_conversation_message_get_message(PurpleConvMessage *msg);
16.735 -
16.736 -/**
16.737 - * Get the message-flags of a PurpleConvMessage
16.738 - *
16.739 - * @param msg A PurpleConvMessage
16.740 - *
16.741 - * @return The message flags
16.742 - *
16.743 - * @since 2.2.0
16.744 - */
16.745 -PurpleMessageFlags purple_conversation_message_get_flags(PurpleConvMessage *msg);
16.746 -
16.747 -/**
16.748 - * Get the timestamp of a PurpleConvMessage
16.749 - *
16.750 - * @param msg A PurpleConvMessage
16.751 - *
16.752 - * @return The timestamp of the message
16.753 - *
16.754 - * @since 2.2.0
16.755 - */
16.756 -time_t purple_conversation_message_get_timestamp(PurpleConvMessage *msg);
16.757 -
16.758 -/*@}*/
16.759 -
16.760 -
16.761 -/**************************************************************************/
16.762 -/** @name IM Conversation API */
16.763 -/**************************************************************************/
16.764 -/*@{*/
16.765 -
16.766 -/**
16.767 - * Gets an IM's parent conversation.
16.768 - *
16.769 - * @param im The IM.
16.770 - *
16.771 - * @return The parent conversation.
16.772 - */
16.773 -PurpleConversation *purple_conv_im_get_conversation(const PurpleConvIm *im);
16.774 -
16.775 -/**
16.776 - * Sets the IM's buddy icon.
16.777 - *
16.778 - * This should only be called from within Purple. You probably want to
16.779 - * call purple_buddy_icon_set_data().
16.780 - *
16.781 - * @param im The IM.
16.782 - * @param icon The buddy icon.
16.783 - *
16.784 - * @see purple_buddy_icon_set_data()
16.785 - */
16.786 -void purple_conv_im_set_icon(PurpleConvIm *im, PurpleBuddyIcon *icon);
16.787 -
16.788 -/**
16.789 - * Returns the IM's buddy icon.
16.790 - *
16.791 - * @param im The IM.
16.792 - *
16.793 - * @return The buddy icon.
16.794 - */
16.795 -PurpleBuddyIcon *purple_conv_im_get_icon(const PurpleConvIm *im);
16.796 -
16.797 -/**
16.798 - * Sets the IM's typing state.
16.799 - *
16.800 - * @param im The IM.
16.801 - * @param state The typing state.
16.802 - */
16.803 -void purple_conv_im_set_typing_state(PurpleConvIm *im, PurpleTypingState state);
16.804 -
16.805 -/**
16.806 - * Returns the IM's typing state.
16.807 - *
16.808 - * @param im The IM.
16.809 - *
16.810 - * @return The IM's typing state.
16.811 - */
16.812 -PurpleTypingState purple_conv_im_get_typing_state(const PurpleConvIm *im);
16.813 -
16.814 -/**
16.815 - * Starts the IM's typing timeout.
16.816 - *
16.817 - * @param im The IM.
16.818 - * @param timeout The timeout.
16.819 - */
16.820 -void purple_conv_im_start_typing_timeout(PurpleConvIm *im, int timeout);
16.821 -
16.822 -/**
16.823 - * Stops the IM's typing timeout.
16.824 - *
16.825 - * @param im The IM.
16.826 - */
16.827 -void purple_conv_im_stop_typing_timeout(PurpleConvIm *im);
16.828 -
16.829 -/**
16.830 - * Returns the IM's typing timeout.
16.831 - *
16.832 - * @param im The IM.
16.833 - *
16.834 - * @return The timeout.
16.835 - */
16.836 -guint purple_conv_im_get_typing_timeout(const PurpleConvIm *im);
16.837 -
16.838 -/**
16.839 - * Sets the quiet-time when no PURPLE_TYPING messages will be sent.
16.840 - * Few protocols need this (maybe only MSN). If the user is still
16.841 - * typing after this quiet-period, then another PURPLE_TYPING message
16.842 - * will be sent.
16.843 - *
16.844 - * @param im The IM.
16.845 - * @param val The number of seconds to wait before allowing another
16.846 - * PURPLE_TYPING message to be sent to the user. Or 0 to
16.847 - * not send another PURPLE_TYPING message.
16.848 - */
16.849 -void purple_conv_im_set_type_again(PurpleConvIm *im, unsigned int val);
16.850 -
16.851 -/**
16.852 - * Returns the time after which another PURPLE_TYPING message should be sent.
16.853 - *
16.854 - * @param im The IM.
16.855 - *
16.856 - * @return The time in seconds since the epoch. Or 0 if no additional
16.857 - * PURPLE_TYPING message should be sent.
16.858 - */
16.859 -time_t purple_conv_im_get_type_again(const PurpleConvIm *im);
16.860 -
16.861 -/**
16.862 - * Starts the IM's type again timeout.
16.863 - *
16.864 - * @param im The IM.
16.865 - */
16.866 -void purple_conv_im_start_send_typed_timeout(PurpleConvIm *im);
16.867 -
16.868 -/**
16.869 - * Stops the IM's type again timeout.
16.870 - *
16.871 - * @param im The IM.
16.872 - */
16.873 -void purple_conv_im_stop_send_typed_timeout(PurpleConvIm *im);
16.874 -
16.875 -/**
16.876 - * Returns the IM's type again timeout interval.
16.877 - *
16.878 - * @param im The IM.
16.879 - *
16.880 - * @return The type again timeout interval.
16.881 - */
16.882 -guint purple_conv_im_get_send_typed_timeout(const PurpleConvIm *im);
16.883 -
16.884 -/**
16.885 - * Updates the visual typing notification for an IM conversation.
16.886 - *
16.887 - * @param im The IM.
16.888 - */
16.889 -void purple_conv_im_update_typing(PurpleConvIm *im);
16.890 -
16.891 -/**
16.892 - * Writes to an IM.
16.893 - *
16.894 - * @param im The IM.
16.895 - * @param who The user who sent the message.
16.896 - * @param message The message to write.
16.897 - * @param flags The message flags.
16.898 - * @param mtime The time the message was sent.
16.899 - */
16.900 -void purple_conv_im_write(PurpleConvIm *im, const char *who,
16.901 - const char *message, PurpleMessageFlags flags,
16.902 - time_t mtime);
16.903 -
16.904 -/**
16.905 - * Presents an IM-error to the user
16.906 - *
16.907 - * This is a helper function to find a conversation, write an error to it, and
16.908 - * raise the window. If a conversation with this user doesn't already exist,
16.909 - * the function will return FALSE and the calling function can attempt to present
16.910 - * the error another way (purple_notify_error, most likely)
16.911 - *
16.912 - * @param who The user this error is about
16.913 - * @param account The account this error is on
16.914 - * @param what The error
16.915 - * @return TRUE if the error was presented, else FALSE
16.916 - */
16.917 -gboolean purple_conv_present_error(const char *who, PurpleAccount *account, const char *what);
16.918 -
16.919 -/**
16.920 - * Sends a message to this IM conversation.
16.921 - *
16.922 - * @param im The IM.
16.923 - * @param message The message to send.
16.924 - */
16.925 -void purple_conv_im_send(PurpleConvIm *im, const char *message);
16.926 -
16.927 -/**
16.928 - * Sends a message to a conversation after confirming with
16.929 - * the user.
16.930 - *
16.931 - * This function is intended for use in cases where the user
16.932 - * hasn't explicitly and knowingly caused a message to be sent.
16.933 - * The confirmation ensures that the user isn't sending a
16.934 - * message by mistake.
16.935 - *
16.936 - * @param conv The conversation.
16.937 - * @param message The message to send.
16.938 - */
16.939 -void purple_conv_send_confirm(PurpleConversation *conv, const char *message);
16.940 -
16.941 -/**
16.942 - * Sends a message to this IM conversation with specified flags.
16.943 - *
16.944 - * @param im The IM.
16.945 - * @param message The message to send.
16.946 - * @param flags The PurpleMessageFlags flags to use in addition to PURPLE_MESSAGE_SEND.
16.947 - */
16.948 -void purple_conv_im_send_with_flags(PurpleConvIm *im, const char *message, PurpleMessageFlags flags);
16.949 -
16.950 -/**
16.951 - * Adds a smiley to the conversation's smiley tree. If this returns
16.952 - * @c TRUE you should call purple_conv_custom_smiley_write() one or more
16.953 - * times, and then purple_conv_custom_smiley_close(). If this returns
16.954 - * @c FALSE, either the conv or smile were invalid, or the icon was
16.955 - * found in the cache. In either case, calling write or close would
16.956 - * be an error.
16.957 - *
16.958 - * @param conv The conversation to associate the smiley with.
16.959 - * @param smile The text associated with the smiley
16.960 - * @param cksum_type The type of checksum.
16.961 - * @param chksum The checksum, as a NUL terminated base64 string.
16.962 - * @param remote @c TRUE if the custom smiley is set by the remote user (buddy).
16.963 - * @return @c TRUE if an icon is expected, else FALSE. Note that
16.964 - * it is an error to never call purple_conv_custom_smiley_close if
16.965 - * this function returns @c TRUE, but an error to call it if
16.966 - * @c FALSE is returned.
16.967 - */
16.968 -
16.969 -gboolean purple_conv_custom_smiley_add(PurpleConversation *conv, const char *smile,
16.970 - const char *cksum_type, const char *chksum,
16.971 - gboolean remote);
16.972 -
16.973 -
16.974 -/**
16.975 - * Updates the image associated with the current smiley.
16.976 - *
16.977 - * @param conv The conversation associated with the smiley.
16.978 - * @param smile The text associated with the smiley.
16.979 - * @param data The actual image data.
16.980 - * @param size The length of the data.
16.981 - */
16.982 -
16.983 -void purple_conv_custom_smiley_write(PurpleConversation *conv,
16.984 - const char *smile,
16.985 - const guchar *data,
16.986 - gsize size);
16.987 -
16.988 -/**
16.989 - * Close the custom smiley, all data has been written with
16.990 - * purple_conv_custom_smiley_write, and it is no longer valid
16.991 - * to call that function on that smiley.
16.992 - *
16.993 - * @param conv The purple conversation associated with the smiley.
16.994 - * @param smile The text associated with the smiley
16.995 - */
16.996 -
16.997 -void purple_conv_custom_smiley_close(PurpleConversation *conv, const char *smile);
16.998 -
16.999 -/*@}*/
16.1000 -
16.1001 -
16.1002 -/**************************************************************************/
16.1003 -/** @name Chat Conversation API */
16.1004 -/**************************************************************************/
16.1005 -/*@{*/
16.1006 -
16.1007 -/**
16.1008 - * Gets a chat's parent conversation.
16.1009 - *
16.1010 - * @param chat The chat.
16.1011 - *
16.1012 - * @return The parent conversation.
16.1013 - */
16.1014 -PurpleConversation *purple_conv_chat_get_conversation(const PurpleConvChat *chat);
16.1015 -
16.1016 -/**
16.1017 - * Sets the list of users in the chat room.
16.1018 - *
16.1019 - * @note Calling this function will not update the display of the users.
16.1020 - * Please use purple_conv_chat_add_user(), purple_conv_chat_add_users(),
16.1021 - * purple_conv_chat_remove_user(), and purple_conv_chat_remove_users() instead.
16.1022 - *
16.1023 - * @param chat The chat.
16.1024 - * @param users The list of users.
16.1025 - *
16.1026 - * @return The list passed.
16.1027 - */
16.1028 -GList *purple_conv_chat_set_users(PurpleConvChat *chat, GList *users);
16.1029 -
16.1030 -/**
16.1031 - * Returns a list of users in the chat room.
16.1032 - *
16.1033 - * @param chat The chat.
16.1034 - *
16.1035 - * @constreturn The list of users.
16.1036 - */
16.1037 -GList *purple_conv_chat_get_users(const PurpleConvChat *chat);
16.1038 -
16.1039 -/**
16.1040 - * Ignores a user in a chat room.
16.1041 - *
16.1042 - * @param chat The chat.
16.1043 - * @param name The name of the user.
16.1044 - */
16.1045 -void purple_conv_chat_ignore(PurpleConvChat *chat, const char *name);
16.1046 -
16.1047 -/**
16.1048 - * Unignores a user in a chat room.
16.1049 - *
16.1050 - * @param chat The chat.
16.1051 - * @param name The name of the user.
16.1052 - */
16.1053 -void purple_conv_chat_unignore(PurpleConvChat *chat, const char *name);
16.1054 -
16.1055 -/**
16.1056 - * Sets the list of ignored users in the chat room.
16.1057 - *
16.1058 - * @param chat The chat.
16.1059 - * @param ignored The list of ignored users.
16.1060 - *
16.1061 - * @return The list passed.
16.1062 - */
16.1063 -GList *purple_conv_chat_set_ignored(PurpleConvChat *chat, GList *ignored);
16.1064 -
16.1065 -/**
16.1066 - * Returns the list of ignored users in the chat room.
16.1067 - *
16.1068 - * @param chat The chat.
16.1069 - *
16.1070 - * @constreturn The list of ignored users.
16.1071 - */
16.1072 -GList *purple_conv_chat_get_ignored(const PurpleConvChat *chat);
16.1073 -
16.1074 -/**
16.1075 - * Returns the actual name of the specified ignored user, if it exists in
16.1076 - * the ignore list.
16.1077 - *
16.1078 - * If the user found contains a prefix, such as '+' or '\@', this is also
16.1079 - * returned. The username passed to the function does not have to have this
16.1080 - * formatting.
16.1081 - *
16.1082 - * @param chat The chat.
16.1083 - * @param user The user to check in the ignore list.
16.1084 - *
16.1085 - * @return The ignored user if found, complete with prefixes, or @c NULL
16.1086 - * if not found.
16.1087 - */
16.1088 -const char *purple_conv_chat_get_ignored_user(const PurpleConvChat *chat,
16.1089 - const char *user);
16.1090 -
16.1091 -/**
16.1092 - * Returns @c TRUE if the specified user is ignored.
16.1093 - *
16.1094 - * @param chat The chat.
16.1095 - * @param user The user.
16.1096 - *
16.1097 - * @return @c TRUE if the user is in the ignore list; @c FALSE otherwise.
16.1098 - */
16.1099 -gboolean purple_conv_chat_is_user_ignored(const PurpleConvChat *chat,
16.1100 - const char *user);
16.1101 -
16.1102 -/**
16.1103 - * Sets the chat room's topic.
16.1104 - *
16.1105 - * @param chat The chat.
16.1106 - * @param who The user that set the topic.
16.1107 - * @param topic The topic.
16.1108 - */
16.1109 -void purple_conv_chat_set_topic(PurpleConvChat *chat, const char *who,
16.1110 - const char *topic);
16.1111 -
16.1112 -/**
16.1113 - * Returns the chat room's topic.
16.1114 - *
16.1115 - * @param chat The chat.
16.1116 - *
16.1117 - * @return The chat's topic.
16.1118 - */
16.1119 -const char *purple_conv_chat_get_topic(const PurpleConvChat *chat);
16.1120 -
16.1121 -/**
16.1122 - * Sets the chat room's ID.
16.1123 - *
16.1124 - * @param chat The chat.
16.1125 - * @param id The ID.
16.1126 - */
16.1127 -void purple_conv_chat_set_id(PurpleConvChat *chat, int id);
16.1128 -
16.1129 -/**
16.1130 - * Returns the chat room's ID.
16.1131 - *
16.1132 - * @param chat The chat.
16.1133 - *
16.1134 - * @return The ID.
16.1135 - */
16.1136 -int purple_conv_chat_get_id(const PurpleConvChat *chat);
16.1137 -
16.1138 -/**
16.1139 - * Writes to a chat.
16.1140 - *
16.1141 - * @param chat The chat.
16.1142 - * @param who The user who sent the message.
16.1143 - * @param message The message to write.
16.1144 - * @param flags The flags.
16.1145 - * @param mtime The time the message was sent.
16.1146 - */
16.1147 -void purple_conv_chat_write(PurpleConvChat *chat, const char *who,
16.1148 - const char *message, PurpleMessageFlags flags,
16.1149 - time_t mtime);
16.1150 -
16.1151 -/**
16.1152 - * Sends a message to this chat conversation.
16.1153 - *
16.1154 - * @param chat The chat.
16.1155 - * @param message The message to send.
16.1156 - */
16.1157 -void purple_conv_chat_send(PurpleConvChat *chat, const char *message);
16.1158 -
16.1159 -/**
16.1160 - * Sends a message to this chat conversation with specified flags.
16.1161 - *
16.1162 - * @param chat The chat.
16.1163 - * @param message The message to send.
16.1164 - * @param flags The PurpleMessageFlags flags to use.
16.1165 - */
16.1166 -void purple_conv_chat_send_with_flags(PurpleConvChat *chat, const char *message, PurpleMessageFlags flags);
16.1167 -
16.1168 -/**
16.1169 - * Adds a user to a chat.
16.1170 - *
16.1171 - * @param chat The chat.
16.1172 - * @param user The user to add.
16.1173 - * @param extra_msg An extra message to display with the join message.
16.1174 - * @param flags The users flags
16.1175 - * @param new_arrival Decides whether or not to show a join notice.
16.1176 - */
16.1177 -void purple_conv_chat_add_user(PurpleConvChat *chat, const char *user,
16.1178 - const char *extra_msg, PurpleConvChatBuddyFlags flags,
16.1179 - gboolean new_arrival);
16.1180 -
16.1181 -/**
16.1182 - * Adds a list of users to a chat.
16.1183 - *
16.1184 - * The data is copied from @a users, @a extra_msgs, and @a flags, so it is up to
16.1185 - * the caller to free this list after calling this function.
16.1186 - *
16.1187 - * @param chat The chat.
16.1188 - * @param users The list of users to add.
16.1189 - * @param extra_msgs An extra message to display with the join message for each
16.1190 - * user. This list may be shorter than @a users, in which
16.1191 - * case, the users after the end of extra_msgs will not have
16.1192 - * an extra message. By extension, this means that extra_msgs
16.1193 - * can simply be @c NULL and none of the users will have an
16.1194 - * extra message.
16.1195 - * @param flags The list of flags for each user.
16.1196 - * @param new_arrivals Decides whether or not to show join notices.
16.1197 - */
16.1198 -void purple_conv_chat_add_users(PurpleConvChat *chat, GList *users, GList *extra_msgs,
16.1199 - GList *flags, gboolean new_arrivals);
16.1200 -
16.1201 -/**
16.1202 - * Renames a user in a chat.
16.1203 - *
16.1204 - * @param chat The chat.
16.1205 - * @param old_user The old username.
16.1206 - * @param new_user The new username.
16.1207 - */
16.1208 -void purple_conv_chat_rename_user(PurpleConvChat *chat, const char *old_user,
16.1209 - const char *new_user);
16.1210 -
16.1211 -/**
16.1212 - * Removes a user from a chat, optionally with a reason.
16.1213 - *
16.1214 - * It is up to the developer to free this list after calling this function.
16.1215 - *
16.1216 - * @param chat The chat.
16.1217 - * @param user The user that is being removed.
16.1218 - * @param reason The optional reason given for the removal. Can be @c NULL.
16.1219 - */
16.1220 -void purple_conv_chat_remove_user(PurpleConvChat *chat, const char *user,
16.1221 - const char *reason);
16.1222 -
16.1223 -/**
16.1224 - * Removes a list of users from a chat, optionally with a single reason.
16.1225 - *
16.1226 - * @param chat The chat.
16.1227 - * @param users The users that are being removed.
16.1228 - * @param reason The optional reason given for the removal. Can be @c NULL.
16.1229 - */
16.1230 -void purple_conv_chat_remove_users(PurpleConvChat *chat, GList *users,
16.1231 - const char *reason);
16.1232 -
16.1233 -/**
16.1234 - * Finds a user in a chat
16.1235 - *
16.1236 - * @param chat The chat.
16.1237 - * @param user The user to look for.
16.1238 - *
16.1239 - * @return TRUE if the user is in the chat, FALSE if not
16.1240 - */
16.1241 -gboolean purple_conv_chat_find_user(PurpleConvChat *chat, const char *user);
16.1242 -
16.1243 -/**
16.1244 - * Set a users flags in a chat
16.1245 - *
16.1246 - * @param chat The chat.
16.1247 - * @param user The user to update.
16.1248 - * @param flags The new flags.
16.1249 - */
16.1250 -void purple_conv_chat_user_set_flags(PurpleConvChat *chat, const char *user,
16.1251 - PurpleConvChatBuddyFlags flags);
16.1252 -
16.1253 -/**
16.1254 - * Get the flags for a user in a chat
16.1255 - *
16.1256 - * @param chat The chat.
16.1257 - * @param user The user to find the flags for
16.1258 - *
16.1259 - * @return The flags for the user
16.1260 - */
16.1261 -PurpleConvChatBuddyFlags purple_conv_chat_user_get_flags(PurpleConvChat *chat,
16.1262 - const char *user);
16.1263 -
16.1264 -/**
16.1265 - * Clears all users from a chat.
16.1266 - *
16.1267 - * @param chat The chat.
16.1268 - */
16.1269 -void purple_conv_chat_clear_users(PurpleConvChat *chat);
16.1270 -
16.1271 -/**
16.1272 - * Sets your nickname (used for hilighting) for a chat.
16.1273 - *
16.1274 - * @param chat The chat.
16.1275 - * @param nick The nick.
16.1276 - */
16.1277 -void purple_conv_chat_set_nick(PurpleConvChat *chat, const char *nick);
16.1278 -
16.1279 -/**
16.1280 - * Gets your nickname (used for hilighting) for a chat.
16.1281 - *
16.1282 - * @param chat The chat.
16.1283 - * @return The nick.
16.1284 - */
16.1285 -const char *purple_conv_chat_get_nick(PurpleConvChat *chat);
16.1286 -
16.1287 -/**
16.1288 - * Finds a chat with the specified chat ID.
16.1289 - *
16.1290 - * @param gc The purple_connection.
16.1291 - * @param id The chat ID.
16.1292 - *
16.1293 - * @return The chat conversation.
16.1294 - */
16.1295 -PurpleConversation *purple_find_chat(const PurpleConnection *gc, int id);
16.1296 -
16.1297 -/**
16.1298 - * Lets the core know we left a chat, without destroying it.
16.1299 - * Called from serv_got_chat_left().
16.1300 - *
16.1301 - * @param chat The chat.
16.1302 - */
16.1303 -void purple_conv_chat_left(PurpleConvChat *chat);
16.1304 -
16.1305 -/**
16.1306 - * Returns true if we're no longer in this chat,
16.1307 - * and just left the window open.
16.1308 - *
16.1309 - * @param chat The chat.
16.1310 - *
16.1311 - * @return @c TRUE if we left the chat already, @c FALSE if
16.1312 - * we're still there.
16.1313 - */
16.1314 -gboolean purple_conv_chat_has_left(PurpleConvChat *chat);
16.1315 -
16.1316 -/**
16.1317 - * Creates a new chat buddy
16.1318 - *
16.1319 - * @param name The name.
16.1320 - * @param alias The alias.
16.1321 - * @param flags The flags.
16.1322 - *
16.1323 - * @return The new chat buddy
16.1324 - */
16.1325 -PurpleConvChatBuddy *purple_conv_chat_cb_new(const char *name, const char *alias,
16.1326 - PurpleConvChatBuddyFlags flags);
16.1327 -
16.1328 -/**
16.1329 - * Find a chat buddy in a chat
16.1330 - *
16.1331 - * @param chat The chat.
16.1332 - * @param name The name of the chat buddy to find.
16.1333 - */
16.1334 -PurpleConvChatBuddy *purple_conv_chat_cb_find(PurpleConvChat *chat, const char *name);
16.1335 -
16.1336 -/**
16.1337 - * Get the name of a chat buddy
16.1338 - *
16.1339 - * @param cb The chat buddy.
16.1340 - *
16.1341 - * @return The name of the chat buddy.
16.1342 - */
16.1343 -const char *purple_conv_chat_cb_get_name(PurpleConvChatBuddy *cb);
16.1344 -
16.1345 -/**
16.1346 - * Destroys a chat buddy
16.1347 - *
16.1348 - * @param cb The chat buddy to destroy
16.1349 - */
16.1350 -void purple_conv_chat_cb_destroy(PurpleConvChatBuddy *cb);
16.1351 -
16.1352 -/**
16.1353 - * Retrieves the extended menu items for the conversation.
16.1354 - *
16.1355 - * @param conv The conversation.
16.1356 - *
16.1357 - * @return A list of PurpleMenuAction items, harvested by the
16.1358 - * chat-extended-menu signal. The list and the menuaction
16.1359 - * items should be freed by the caller.
16.1360 - *
16.1361 - * @since 2.1.0
16.1362 - */
16.1363 -GList * purple_conversation_get_extended_menu(PurpleConversation *conv);
16.1364 -
16.1365 -/**
16.1366 - * Perform a command in a conversation. Similar to @see purple_cmd_do_command
16.1367 - *
16.1368 - * @param conv The conversation.
16.1369 - * @param cmdline The entire command including the arguments.
16.1370 - * @param markup @c NULL, or the formatted command line.
16.1371 - * @param error If the command failed errormsg is filled in with the appropriate error
16.1372 - * message, if not @c NULL. It must be freed by the caller with g_free().
16.1373 - *
16.1374 - * @return @c TRUE if the command was executed successfully, @c FALSE otherwise.
16.1375 - *
16.1376 - * @since 2.1.0
16.1377 - */
16.1378 -gboolean purple_conversation_do_command(PurpleConversation *conv, const gchar *cmdline, const gchar *markup, gchar **error);
16.1379 -
16.1380 -/*@}*/
16.1381 -
16.1382 -/**************************************************************************/
16.1383 -/** @name Conversations Subsystem */
16.1384 -/**************************************************************************/
16.1385 -/*@{*/
16.1386 -
16.1387 -/**
16.1388 - * Returns the conversation subsystem handle.
16.1389 - *
16.1390 - * @return The conversation subsystem handle.
16.1391 - */
16.1392 -void *purple_conversations_get_handle(void);
16.1393 -
16.1394 -/**
16.1395 - * Initializes the conversation subsystem.
16.1396 - */
16.1397 -void purple_conversations_init(void);
16.1398 -
16.1399 -/**
16.1400 - * Uninitializes the conversation subsystem.
16.1401 - */
16.1402 -void purple_conversations_uninit(void);
16.1403 -
16.1404 -/*@}*/
16.1405 -
16.1406 -#ifdef __cplusplus
16.1407 -}
16.1408 -#endif
16.1409 -
16.1410 -#endif /* _PURPLE_CONVERSATION_H_ */
17.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/core.h Sun Jun 21 22:04:11 2009 -0400
17.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
17.3 @@ -1,235 +0,0 @@
17.4 -/**
17.5 - * @file core.h Startup and shutdown of libpurple
17.6 - * @defgroup core libpurple
17.7 - * @see @ref core-signals
17.8 - */
17.9 -
17.10 -/* purple
17.11 - *
17.12 - * Purple is the legal property of its developers, whose names are too numerous
17.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
17.14 - * source distribution.
17.15 - *
17.16 - * This program is free software; you can redistribute it and/or modify
17.17 - * it under the terms of the GNU General Public License as published by
17.18 - * the Free Software Foundation; either version 2 of the License, or
17.19 - * (at your option) any later version.
17.20 - *
17.21 - * This program is distributed in the hope that it will be useful,
17.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
17.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17.24 - * GNU General Public License for more details.
17.25 - *
17.26 - * You should have received a copy of the GNU General Public License
17.27 - * along with this program; if not, write to the Free Software
17.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
17.29 - */
17.30 -#ifndef _PURPLE_CORE_H_
17.31 -#define _PURPLE_CORE_H_
17.32 -
17.33 -typedef struct PurpleCore PurpleCore;
17.34 -
17.35 -/** Callbacks that fire at different points of the initialization and teardown
17.36 - * of libpurple, along with a hook to return descriptive information about the
17.37 - * UI.
17.38 - */
17.39 -typedef struct
17.40 -{
17.41 - /** Called just after the preferences subsystem is initialized; the UI
17.42 - * could use this callback to add some preferences it needs to be in
17.43 - * place when other subsystems are initialized.
17.44 - */
17.45 - void (*ui_prefs_init)(void);
17.46 - /** Called just after the debug subsystem is initialized, but before
17.47 - * just about every other component's initialization. The UI should
17.48 - * use this hook to call purple_debug_set_ui_ops() so that debugging
17.49 - * information for other components can be logged during their
17.50 - * initialization.
17.51 - */
17.52 - void (*debug_ui_init)(void);
17.53 - /** Called after all of libpurple has been initialized. The UI should
17.54 - * use this hook to set all other necessary UiOps structures.
17.55 - *
17.56 - * @see @ref ui-ops
17.57 - */
17.58 - void (*ui_init)(void);
17.59 - /** Called after most of libpurple has been uninitialized. */
17.60 - void (*quit)(void);
17.61 -
17.62 - /** Called by purple_core_get_ui_info(); should return the information
17.63 - * documented there.
17.64 - */
17.65 - GHashTable* (*get_ui_info)(void);
17.66 -
17.67 - void (*_purple_reserved1)(void);
17.68 - void (*_purple_reserved2)(void);
17.69 - void (*_purple_reserved3)(void);
17.70 -} PurpleCoreUiOps;
17.71 -
17.72 -#ifdef __cplusplus
17.73 -extern "C" {
17.74 -#endif
17.75 -
17.76 -/**
17.77 - * Initializes the core of purple.
17.78 - *
17.79 - * This will setup preferences for all the core subsystems.
17.80 - *
17.81 - * @param ui The ID of the UI using the core. This should be a
17.82 - * unique ID, registered with the purple team.
17.83 - *
17.84 - * @return @c TRUE if successful, or @c FALSE otherwise.
17.85 - */
17.86 -gboolean purple_core_init(const char *ui);
17.87 -
17.88 -/**
17.89 - * Quits the core of purple, which, depending on the UI, may quit the
17.90 - * application using the purple core.
17.91 - */
17.92 -void purple_core_quit(void);
17.93 -
17.94 -/**
17.95 - * <p>
17.96 - * Calls purple_core_quit(). This can be used as the function
17.97 - * passed to purple_timeout_add() when you want to shutdown Purple
17.98 - * in a specified amount of time. When shutting down Purple
17.99 - * from a plugin, you must use this instead of purple_core_quit();
17.100 - * for an immediate exit, use a timeout value of 0:
17.101 - * </p>
17.102 - *
17.103 - * <code>purple_timeout_add(0, purple_core_quitcb, NULL);</code>
17.104 - *
17.105 - * <p>
17.106 - * This is ensures that code from your plugin is not being
17.107 - * executed when purple_core_quit() is called. If the plugin
17.108 - * called purple_core_quit() directly, you would get a core dump
17.109 - * after purple_core_quit() executes and control returns to your
17.110 - * plugin because purple_core_quit() frees all plugins.
17.111 - * </p>
17.112 - */
17.113 -gboolean purple_core_quit_cb(gpointer unused);
17.114 -
17.115 -/**
17.116 - * Returns the version of the core library.
17.117 - *
17.118 - * @return The version of the core library.
17.119 - */
17.120 -const char *purple_core_get_version(void);
17.121 -
17.122 -/**
17.123 - * Returns the ID of the UI that is using the core, as passed to
17.124 - * purple_core_init().
17.125 - *
17.126 - * @return The ID of the UI that is currently using the core.
17.127 - */
17.128 -const char *purple_core_get_ui(void);
17.129 -
17.130 -/**
17.131 - * Returns a handle to the purple core.
17.132 - *
17.133 - * This is used to connect to @ref core-signals "core signals".
17.134 - */
17.135 -PurpleCore *purple_get_core(void);
17.136 -
17.137 -/**
17.138 - * Sets the UI ops for the core.
17.139 - *
17.140 - * @param ops A UI ops structure for the core.
17.141 - */
17.142 -void purple_core_set_ui_ops(PurpleCoreUiOps *ops);
17.143 -
17.144 -/**
17.145 - * Returns the UI ops for the core.
17.146 - *
17.147 - * @return The core's UI ops structure.
17.148 - */
17.149 -PurpleCoreUiOps *purple_core_get_ui_ops(void);
17.150 -
17.151 -/**
17.152 - * Migrates from <tt>.gaim</tt> to <tt>.purple</tt>.
17.153 - *
17.154 - * UIs <strong>must not</strong> call this if they have been told to use a
17.155 - * custom user directory.
17.156 - *
17.157 - * @return A boolean indicating success or migration failure. On failure,
17.158 - * the application must display an error to the user and then exit.
17.159 - */
17.160 -gboolean purple_core_migrate(void);
17.161 -
17.162 -/**
17.163 - * Ensures that only one instance is running. If libpurple is built with D-Bus
17.164 - * support, this checks if another process owns the libpurple bus name and if
17.165 - * so whether that process is using the same configuration directory as this
17.166 - * process.
17.167 - *
17.168 - * @return @c TRUE if this is the first instance of libpurple running;
17.169 - * @c FALSE if there is another instance running.
17.170 - *
17.171 - * @since 2.1.0
17.172 - */
17.173 -gboolean purple_core_ensure_single_instance(void);
17.174 -
17.175 -/**
17.176 - * Returns a hash table containing various information about the UI. The
17.177 - * following well-known entries may be in the table (along with any others the
17.178 - * UI might choose to include):
17.179 - *
17.180 - * <dl>
17.181 - * <dt><tt>name</tt></dt>
17.182 - * <dd>the user-readable name for the UI.</dd>
17.183 - *
17.184 - * <dt><tt>version</tt></dt>
17.185 - * <dd>a user-readable description of the current version of the UI.</dd>
17.186 - *
17.187 - * <dt><tt>website</tt></dt>
17.188 - * <dd>the UI's website, such as http://pidgin.im.</dd>
17.189 - *
17.190 - * <dt><tt>dev_website</tt></dt>
17.191 - * <dd>the UI's development/support website, such as http://developer.pidgin.im.</dd>
17.192 - * </dl>
17.193 - *
17.194 - * @return A GHashTable with strings for keys and values. This
17.195 - * hash table must not be freed and should not be modified.
17.196 - *
17.197 - * @since 2.1.0
17.198 - *
17.199 - */
17.200 -GHashTable* purple_core_get_ui_info(void);
17.201 -
17.202 -#ifdef __cplusplus
17.203 -}
17.204 -#endif
17.205 -
17.206 -#endif /* _PURPLE_CORE_H_ */
17.207 -
17.208 -/*
17.209 -
17.210 - /===-
17.211 - `//"\\ """"`---.___.-""
17.212 - ______-==| | | \\ _-"`
17.213 - __--""" ,-/-==\\ | | `\ ,'
17.214 - _-" /' | \\ ___ / / \ /
17.215 - .' / | \\ /" "\ /' / \ /'
17.216 - / ____ / | \`\.__/-"" D O \_/' / \/'
17.217 -/-'" """""---__ | "-/" O G R /' _--"`
17.218 - \_| / R __--_ t ), __--""
17.219 - '""--_/ T _-"_>--<_\ h '-" \
17.220 - {\__--_/} / \\__>--<__\ e B \
17.221 - /' (_/ _-" | |__>--<__| U |
17.222 - | _/) )-" | |__>--<__| R |
17.223 - / /" ,_/ / /__>---<__/ N |
17.224 - o-o _// /-"_>---<__-" I /
17.225 - (^(" /"_>---<__- N _-"
17.226 - ,/| /__>--<__/ A _-"
17.227 - ,//('( |__>--<__| T / .----_
17.228 - ( ( ')) |__>--<__| | /' _---_"\
17.229 - `-)) )) ( |__>--<__| O | /' / "\`\
17.230 - ,/,'//( ( \__>--<__\ R \ /' // ||
17.231 - ,( ( ((, )) "-__>--<_"-_ "--____---"' _/'/ /'
17.232 - `"/ )` ) ,/| "-_">--<_/-__ __-" _/
17.233 - ._-"//( )/ )) ` ""-'_/_/ /"""""""__--"
17.234 - ;'( ')/ ,)( """"""""""
17.235 - ' ') '( (/
17.236 - ' ' `
17.237 -
17.238 -*/
18.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/dbus-maybe.h Sun Jun 21 22:04:11 2009 -0400
18.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
18.3 @@ -1,35 +0,0 @@
18.4 -/* This file contains macros that wrap calls to the purple dbus module.
18.5 - These macros call the appropriate functions if the build includes
18.6 - dbus support and do nothing otherwise. See "dbus-server.h" for
18.7 - documentation. */
18.8 -
18.9 -#ifndef _PURPLE_DBUS_MAYBE_H_
18.10 -#define _PURPLE_DBUS_MAYBE_H_
18.11 -
18.12 -#ifdef HAVE_DBUS
18.13 -
18.14 -#ifndef DBUS_API_SUBJECT_TO_CHANGE
18.15 -#define DBUS_API_SUBJECT_TO_CHANGE
18.16 -#endif
18.17 -
18.18 -#include "dbus-server.h"
18.19 -
18.20 -/* this provides a type check */
18.21 -#define PURPLE_DBUS_REGISTER_POINTER(ptr, type) { \
18.22 - type *typed_ptr = ptr; \
18.23 - purple_dbus_register_pointer(typed_ptr, PURPLE_DBUS_TYPE(type)); \
18.24 -}
18.25 -#define PURPLE_DBUS_UNREGISTER_POINTER(ptr) purple_dbus_unregister_pointer(ptr)
18.26 -
18.27 -#else /* !HAVE_DBUS */
18.28 -
18.29 -#define PURPLE_DBUS_REGISTER_POINTER(ptr, type) { \
18.30 - if (ptr) {} \
18.31 -}
18.32 -
18.33 -#define PURPLE_DBUS_UNREGISTER_POINTER(ptr)
18.34 -#define DBUS_EXPORT
18.35 -
18.36 -#endif /* HAVE_DBUS */
18.37 -
18.38 -#endif
19.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/debug.h Sun Jun 21 22:04:11 2009 -0400
19.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
19.3 @@ -1,199 +0,0 @@
19.4 -/**
19.5 - * @file debug.h Debug API
19.6 - * @ingroup core
19.7 - */
19.8 -
19.9 -/* purple
19.10 - *
19.11 - * Purple is the legal property of its developers, whose names are too numerous
19.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
19.13 - * source distribution.
19.14 - *
19.15 - * This program is free software; you can redistribute it and/or modify
19.16 - * it under the terms of the GNU General Public License as published by
19.17 - * the Free Software Foundation; either version 2 of the License, or
19.18 - * (at your option) any later version.
19.19 - *
19.20 - * This program is distributed in the hope that it will be useful,
19.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
19.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19.23 - * GNU General Public License for more details.
19.24 - *
19.25 - * You should have received a copy of the GNU General Public License
19.26 - * along with this program; if not, write to the Free Software
19.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
19.28 - */
19.29 -#ifndef _PURPLE_DEBUG_H_
19.30 -#define _PURPLE_DEBUG_H_
19.31 -
19.32 -#include <glib.h>
19.33 -#include <stdarg.h>
19.34 -
19.35 -/**
19.36 - * Debug levels.
19.37 - */
19.38 -typedef enum
19.39 -{
19.40 - PURPLE_DEBUG_ALL = 0, /**< All debug levels. */
19.41 - PURPLE_DEBUG_MISC, /**< General chatter. */
19.42 - PURPLE_DEBUG_INFO, /**< General operation Information. */
19.43 - PURPLE_DEBUG_WARNING, /**< Warnings. */
19.44 - PURPLE_DEBUG_ERROR, /**< Errors. */
19.45 - PURPLE_DEBUG_FATAL /**< Fatal errors. */
19.46 -
19.47 -} PurpleDebugLevel;
19.48 -
19.49 -/**
19.50 - * Debug UI operations.
19.51 - */
19.52 -typedef struct
19.53 -{
19.54 - void (*print)(PurpleDebugLevel level, const char *category,
19.55 - const char *arg_s);
19.56 - gboolean (*is_enabled)(PurpleDebugLevel level,
19.57 - const char *category);
19.58 -
19.59 - void (*_purple_reserved1)(void);
19.60 - void (*_purple_reserved2)(void);
19.61 - void (*_purple_reserved3)(void);
19.62 - void (*_purple_reserved4)(void);
19.63 -} PurpleDebugUiOps;
19.64 -
19.65 -#ifdef __cplusplus
19.66 -extern "C" {
19.67 -#endif
19.68 -
19.69 -/**************************************************************************/
19.70 -/** @name Debug API */
19.71 -/**************************************************************************/
19.72 -/**
19.73 - * Outputs debug information.
19.74 - *
19.75 - * @param level The debug level.
19.76 - * @param category The category (or @c NULL).
19.77 - * @param format The format string.
19.78 - */
19.79 -void purple_debug(PurpleDebugLevel level, const char *category,
19.80 - const char *format, ...) G_GNUC_PRINTF(3, 4);
19.81 -
19.82 -/**
19.83 - * Outputs misc. level debug information.
19.84 - *
19.85 - * This is a wrapper for purple_debug(), and uses PURPLE_DEBUG_MISC as
19.86 - * the level.
19.87 - *
19.88 - * @param category The category (or @c NULL).
19.89 - * @param format The format string.
19.90 - *
19.91 - * @see purple_debug()
19.92 - */
19.93 -void purple_debug_misc(const char *category, const char *format, ...) G_GNUC_PRINTF(2, 3);
19.94 -
19.95 -/**
19.96 - * Outputs info level debug information.
19.97 - *
19.98 - * This is a wrapper for purple_debug(), and uses PURPLE_DEBUG_INFO as
19.99 - * the level.
19.100 - *
19.101 - * @param category The category (or @c NULL).
19.102 - * @param format The format string.
19.103 - *
19.104 - * @see purple_debug()
19.105 - */
19.106 -void purple_debug_info(const char *category, const char *format, ...) G_GNUC_PRINTF(2, 3);
19.107 -
19.108 -/**
19.109 - * Outputs warning level debug information.
19.110 - *
19.111 - * This is a wrapper for purple_debug(), and uses PURPLE_DEBUG_WARNING as
19.112 - * the level.
19.113 - *
19.114 - * @param category The category (or @c NULL).
19.115 - * @param format The format string.
19.116 - *
19.117 - * @see purple_debug()
19.118 - */
19.119 -void purple_debug_warning(const char *category, const char *format, ...) G_GNUC_PRINTF(2, 3);
19.120 -
19.121 -/**
19.122 - * Outputs error level debug information.
19.123 - *
19.124 - * This is a wrapper for purple_debug(), and uses PURPLE_DEBUG_ERROR as
19.125 - * the level.
19.126 - *
19.127 - * @param category The category (or @c NULL).
19.128 - * @param format The format string.
19.129 - *
19.130 - * @see purple_debug()
19.131 - */
19.132 -void purple_debug_error(const char *category, const char *format, ...) G_GNUC_PRINTF(2, 3);
19.133 -
19.134 -/**
19.135 - * Outputs fatal error level debug information.
19.136 - *
19.137 - * This is a wrapper for purple_debug(), and uses PURPLE_DEBUG_ERROR as
19.138 - * the level.
19.139 - *
19.140 - * @param category The category (or @c NULL).
19.141 - * @param format The format string.
19.142 - *
19.143 - * @see purple_debug()
19.144 - */
19.145 -void purple_debug_fatal(const char *category, const char *format, ...) G_GNUC_PRINTF(2, 3);
19.146 -
19.147 -/**
19.148 - * Enable or disable printing debug output to the console.
19.149 - *
19.150 - * @param enabled TRUE to enable debug output or FALSE to disable it.
19.151 - */
19.152 -void purple_debug_set_enabled(gboolean enabled);
19.153 -
19.154 -/**
19.155 - * Check if console debug output is enabled.
19.156 - *
19.157 - * @return TRUE if debuggin is enabled, FALSE if it is not.
19.158 - */
19.159 -gboolean purple_debug_is_enabled(void);
19.160 -
19.161 -/*@}*/
19.162 -
19.163 -/**************************************************************************/
19.164 -/** @name UI Registration Functions */
19.165 -/**************************************************************************/
19.166 -/*@{*/
19.167 -
19.168 -/**
19.169 - * Sets the UI operations structure to be used when outputting debug
19.170 - * information.
19.171 - *
19.172 - * @param ops The UI operations structure.
19.173 - */
19.174 -void purple_debug_set_ui_ops(PurpleDebugUiOps *ops);
19.175 -
19.176 -/**
19.177 - * Returns the UI operations structure used when outputting debug
19.178 - * information.
19.179 - *
19.180 - * @return The UI operations structure in use.
19.181 - */
19.182 -PurpleDebugUiOps *purple_debug_get_ui_ops(void);
19.183 -
19.184 -/*@}*/
19.185 -
19.186 -/**************************************************************************/
19.187 -/** @name Debug Subsystem */
19.188 -/**************************************************************************/
19.189 -/*@{*/
19.190 -
19.191 -/**
19.192 - * Initializes the debug subsystem.
19.193 - */
19.194 -void purple_debug_init(void);
19.195 -
19.196 -/*@}*/
19.197 -
19.198 -#ifdef __cplusplus
19.199 -}
19.200 -#endif
19.201 -
19.202 -#endif /* _PURPLE_DEBUG_H_ */
20.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/desktopitem.h Sun Jun 21 22:04:11 2009 -0400
20.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
20.3 @@ -1,172 +0,0 @@
20.4 -/**
20.5 - * @file desktopitem.h Functions for managing .desktop files
20.6 - * @ingroup core
20.7 - */
20.8 -
20.9 -/* Purple is the legal property of its developers, whose names are too numerous
20.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
20.11 - * source distribution.
20.12 - *
20.13 - * This program is free software; you can redistribute it and/or modify
20.14 - * it under the terms of the GNU General Public License as published by
20.15 - * the Free Software Foundation; either version 2 of the License, or
20.16 - * (at your option) any later version.
20.17 - *
20.18 - * This program is distributed in the hope that it will be useful,
20.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
20.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20.21 - * GNU General Public License for more details.
20.22 - *
20.23 - * You should have received a copy of the GNU General Public License
20.24 - * along with this program; if not, write to the Free Software
20.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
20.26 - *
20.27 - */
20.28 -
20.29 -/*
20.30 - * The following code has been adapted from gnome-desktop-item.[ch],
20.31 - * as found on gnome-desktop-2.8.1.
20.32 - *
20.33 - * Copyright (C) 2004 by Alceste Scalas <alceste.scalas@gmx.net>.
20.34 - *
20.35 - * Original copyright notice:
20.36 - *
20.37 - * Copyright (C) 1999, 2000 Red Hat Inc.
20.38 - * Copyright (C) 2001 Sid Vicious
20.39 - * All rights reserved.
20.40 - *
20.41 - * This file is part of the Gnome Library.
20.42 - *
20.43 - * The Gnome Library is free software; you can redistribute it and/or
20.44 - * modify it under the terms of the GNU Library General Public License as
20.45 - * published by the Free Software Foundation; either version 2 of the
20.46 - * License, or (at your option) any later version.
20.47 - *
20.48 - * The Gnome Library is distributed in the hope that it will be useful,
20.49 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
20.50 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20.51 - * Library General Public License for more details.
20.52 - *
20.53 - * You should have received a copy of the GNU Library General Public
20.54 - * License along with the Gnome Library; see the file COPYING.LIB. If not,
20.55 - * write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20.56 - * Boston, MA 02111-1301, USA.
20.57 - */
20.58 -
20.59 -#ifndef _PURPLE_DESKTOP_ITEM_H_
20.60 -#define _PURPLE_DESKTOP_ITEM_H_
20.61 -
20.62 -#include <glib.h>
20.63 -#include <glib-object.h>
20.64 -
20.65 -G_BEGIN_DECLS
20.66 -
20.67 -typedef enum {
20.68 - PURPLE_DESKTOP_ITEM_TYPE_NULL = 0 /* This means its NULL, that is, not
20.69 - * set */,
20.70 - PURPLE_DESKTOP_ITEM_TYPE_OTHER /* This means it's not one of the below
20.71 - strings types, and you must get the
20.72 - Type attribute. */,
20.73 -
20.74 - /* These are the standard compliant types: */
20.75 - PURPLE_DESKTOP_ITEM_TYPE_APPLICATION,
20.76 - PURPLE_DESKTOP_ITEM_TYPE_LINK,
20.77 - PURPLE_DESKTOP_ITEM_TYPE_FSDEVICE,
20.78 - PURPLE_DESKTOP_ITEM_TYPE_MIME_TYPE,
20.79 - PURPLE_DESKTOP_ITEM_TYPE_DIRECTORY,
20.80 - PURPLE_DESKTOP_ITEM_TYPE_SERVICE,
20.81 - PURPLE_DESKTOP_ITEM_TYPE_SERVICE_TYPE
20.82 -} PurpleDesktopItemType;
20.83 -
20.84 -typedef struct _PurpleDesktopItem PurpleDesktopItem;
20.85 -
20.86 -#define PURPLE_TYPE_DESKTOP_ITEM (purple_desktop_item_get_type ())
20.87 -GType purple_desktop_item_get_type (void);
20.88 -
20.89 -/* standard */
20.90 -#define PURPLE_DESKTOP_ITEM_ENCODING "Encoding" /* string */
20.91 -#define PURPLE_DESKTOP_ITEM_VERSION "Version" /* numeric */
20.92 -#define PURPLE_DESKTOP_ITEM_NAME "Name" /* localestring */
20.93 -#define PURPLE_DESKTOP_ITEM_GENERIC_NAME "GenericName" /* localestring */
20.94 -#define PURPLE_DESKTOP_ITEM_TYPE "Type" /* string */
20.95 -#define PURPLE_DESKTOP_ITEM_FILE_PATTERN "FilePattern" /* regexp(s) */
20.96 -#define PURPLE_DESKTOP_ITEM_TRY_EXEC "TryExec" /* string */
20.97 -#define PURPLE_DESKTOP_ITEM_NO_DISPLAY "NoDisplay" /* boolean */
20.98 -#define PURPLE_DESKTOP_ITEM_COMMENT "Comment" /* localestring */
20.99 -#define PURPLE_DESKTOP_ITEM_EXEC "Exec" /* string */
20.100 -#define PURPLE_DESKTOP_ITEM_ACTIONS "Actions" /* strings */
20.101 -#define PURPLE_DESKTOP_ITEM_ICON "Icon" /* string */
20.102 -#define PURPLE_DESKTOP_ITEM_MINI_ICON "MiniIcon" /* string */
20.103 -#define PURPLE_DESKTOP_ITEM_HIDDEN "Hidden" /* boolean */
20.104 -#define PURPLE_DESKTOP_ITEM_PATH "Path" /* string */
20.105 -#define PURPLE_DESKTOP_ITEM_TERMINAL "Terminal" /* boolean */
20.106 -#define PURPLE_DESKTOP_ITEM_TERMINAL_OPTIONS "TerminalOptions" /* string */
20.107 -#define PURPLE_DESKTOP_ITEM_SWALLOW_TITLE "SwallowTitle" /* string */
20.108 -#define PURPLE_DESKTOP_ITEM_SWALLOW_EXEC "SwallowExec" /* string */
20.109 -#define PURPLE_DESKTOP_ITEM_MIME_TYPE "MimeType" /* regexp(s) */
20.110 -#define PURPLE_DESKTOP_ITEM_PATTERNS "Patterns" /* regexp(s) */
20.111 -#define PURPLE_DESKTOP_ITEM_DEFAULT_APP "DefaultApp" /* string */
20.112 -#define PURPLE_DESKTOP_ITEM_DEV "Dev" /* string */
20.113 -#define PURPLE_DESKTOP_ITEM_FS_TYPE "FSType" /* string */
20.114 -#define PURPLE_DESKTOP_ITEM_MOUNT_POINT "MountPoint" /* string */
20.115 -#define PURPLE_DESKTOP_ITEM_READ_ONLY "ReadOnly" /* boolean */
20.116 -#define PURPLE_DESKTOP_ITEM_UNMOUNT_ICON "UnmountIcon" /* string */
20.117 -#define PURPLE_DESKTOP_ITEM_SORT_ORDER "SortOrder" /* strings */
20.118 -#define PURPLE_DESKTOP_ITEM_URL "URL" /* string */
20.119 -#define PURPLE_DESKTOP_ITEM_DOC_PATH "X-GNOME-DocPath" /* string */
20.120 -
20.121 -/**
20.122 - * This function loads 'filename' and turns it into a PurpleDesktopItem.
20.123 - *
20.124 - * @param filename The filename or directory path to load the PurpleDesktopItem from
20.125 - *
20.126 - * @return The newly loaded item, or NULL on error.
20.127 - */
20.128 -PurpleDesktopItem *purple_desktop_item_new_from_file (const char *filename);
20.129 -
20.130 -/**
20.131 - * Gets the type attribute (the 'Type' field) of the item. This should
20.132 - * usually be 'Application' for an application, but it can be 'Directory'
20.133 - * for a directory description. There are other types available as well.
20.134 - * The type usually indicates how the desktop item should be handeled and
20.135 - * how the 'Exec' field should be handeled.
20.136 - *
20.137 - * @param item A desktop item
20.138 - *
20.139 - * @return The type of the specified 'item'. The returned memory
20.140 - * remains owned by the PurpleDesktopItem and should not be freed.
20.141 - */
20.142 -PurpleDesktopItemType purple_desktop_item_get_entry_type (const PurpleDesktopItem *item);
20.143 -
20.144 -/**
20.145 - * Gets the value of an attribute of the item, as a string.
20.146 - *
20.147 - * @param item A desktop item
20.148 - * @param attr The attribute to look for
20.149 - *
20.150 - * @return The value of the specified item attribute.
20.151 - */
20.152 -const char *purple_desktop_item_get_string (const PurpleDesktopItem *item,
20.153 - const char *attr);
20.154 -
20.155 -/**
20.156 - * Creates a copy of a PurpleDesktopItem. The new copy has a refcount of 1.
20.157 - * Note: Section stack is NOT copied.
20.158 - *
20.159 - * @param item The item to be copied
20.160 - *
20.161 - * @return The new copy
20.162 - */
20.163 -PurpleDesktopItem *purple_desktop_item_copy (const PurpleDesktopItem *item);
20.164 -
20.165 -/**
20.166 - * Decreases the reference count of the specified item, and destroys
20.167 - * the item if there are no more references left.
20.168 - *
20.169 - * @param item A desktop item
20.170 - */
20.171 -void purple_desktop_item_unref (PurpleDesktopItem *item);
20.172 -
20.173 -G_END_DECLS
20.174 -
20.175 -#endif /* _PURPLE_DESKTOP_ITEM_H_ */
21.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/dialog.h Sun Jun 21 22:04:11 2009 -0400
21.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
21.3 @@ -1,30 +0,0 @@
21.4 -/**
21.5 - * @file dialog.h Dialog functions
21.6 - *
21.7 - * purple
21.8 - *
21.9 - * Purple is the legal property of its developers, whose names are too numerous
21.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
21.11 - * source distribution.
21.12 - *
21.13 - * This program is free software; you can redistribute it and/or modify
21.14 - * it under the terms of the GNU General Public License as published by
21.15 - * the Free Software Foundation; either version 2 of the License, or
21.16 - * (at your option) any later version.
21.17 - *
21.18 - * This program is distributed in the hope that it will be useful,
21.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
21.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21.21 - * GNU General Public License for more details.
21.22 - *
21.23 - * You should have received a copy of the GNU General Public License
21.24 - * along with this program; if not, write to the Free Software
21.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
21.26 - */
21.27 -#ifndef _MSN_DIALOG_H_
21.28 -#define _MSN_DIALOG_H_
21.29 -
21.30 -void msn_show_sync_issue(MsnSession *session, const char *passport,
21.31 - const char *group_name);
21.32 -
21.33 -#endif /* _MSN_DIALOG_H_ */
22.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/directconn.h Sun Jun 21 22:04:11 2009 -0400
22.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
22.3 @@ -1,61 +0,0 @@
22.4 -/**
22.5 - * @file directconn.h MSN direct connection functions
22.6 - *
22.7 - * purple
22.8 - *
22.9 - * Purple is the legal property of its developers, whose names are too numerous
22.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
22.11 - * source distribution.
22.12 - *
22.13 - * This program is free software; you can redistribute it and/or modify
22.14 - * it under the terms of the GNU General Public License as published by
22.15 - * the Free Software Foundation; either version 2 of the License, or
22.16 - * (at your option) any later version.
22.17 - *
22.18 - * This program is distributed in the hope that it will be useful,
22.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
22.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22.21 - * GNU General Public License for more details.
22.22 - *
22.23 - * You should have received a copy of the GNU General Public License
22.24 - * along with this program; if not, write to the Free Software
22.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
22.26 - */
22.27 -#ifndef _MSN_DIRECTCONN_H_
22.28 -#define _MSN_DIRECTCONN_H_
22.29 -
22.30 -typedef struct _MsnDirectConn MsnDirectConn;
22.31 -
22.32 -#include "slplink.h"
22.33 -#include "slp.h"
22.34 -#include "msg.h"
22.35 -
22.36 -struct _MsnDirectConn
22.37 -{
22.38 - MsnSlpLink *slplink;
22.39 - MsnSlpCall *initial_call;
22.40 -
22.41 - PurpleProxyConnectData *connect_data;
22.42 -
22.43 - gboolean acked;
22.44 -
22.45 - char *nonce;
22.46 -
22.47 - int fd;
22.48 -
22.49 - int port;
22.50 - int inpa;
22.51 -
22.52 - int c;
22.53 -};
22.54 -
22.55 -MsnDirectConn *msn_directconn_new(MsnSlpLink *slplink);
22.56 -gboolean msn_directconn_connect(MsnDirectConn *directconn,
22.57 - const char *host, int port);
22.58 -void msn_directconn_listen(MsnDirectConn *directconn);
22.59 -void msn_directconn_send_msg(MsnDirectConn *directconn, MsnMessage *msg);
22.60 -void msn_directconn_parse_nonce(MsnDirectConn *directconn, const char *nonce);
22.61 -void msn_directconn_destroy(MsnDirectConn *directconn);
22.62 -void msn_directconn_send_handshake(MsnDirectConn *directconn);
22.63 -
22.64 -#endif /* _MSN_DIRECTCONN_H_ */
23.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/dnsquery.h Sun Jun 21 22:04:11 2009 -0400
23.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
23.3 @@ -1,153 +0,0 @@
23.4 -/**
23.5 - * @file dnsquery.h DNS query API
23.6 - * @ingroup core
23.7 - */
23.8 -
23.9 -/* purple
23.10 - *
23.11 - * Purple is the legal property of its developers, whose names are too numerous
23.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
23.13 - * source distribution.
23.14 - *
23.15 - * This program is free software; you can redistribute it and/or modify
23.16 - * it under the terms of the GNU General Public License as published by
23.17 - * the Free Software Foundation; either version 2 of the License, or
23.18 - * (at your option) any later version.
23.19 - *
23.20 - * This program is distributed in the hope that it will be useful,
23.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
23.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23.23 - * GNU General Public License for more details.
23.24 - *
23.25 - * You should have received a copy of the GNU General Public License
23.26 - * along with this program; if not, write to the Free Software
23.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
23.28 - */
23.29 -#ifndef _PURPLE_DNSQUERY_H_
23.30 -#define _PURPLE_DNSQUERY_H_
23.31 -
23.32 -#include <glib.h>
23.33 -#include "eventloop.h"
23.34 -#include "account.h"
23.35 -
23.36 -typedef struct _PurpleDnsQueryData PurpleDnsQueryData;
23.37 -
23.38 -/**
23.39 - * The "hosts" parameter is a linked list containing pairs of
23.40 - * one size_t addrlen and one struct sockaddr *addr. It should
23.41 - * be free'd by the callback function.
23.42 - */
23.43 -typedef void (*PurpleDnsQueryConnectFunction)(GSList *hosts, gpointer data, const char *error_message);
23.44 -
23.45 -/**
23.46 - * Callbacks used by the UI if it handles resolving DNS
23.47 - */
23.48 -typedef void (*PurpleDnsQueryResolvedCallback) (PurpleDnsQueryData *query_data, GSList *hosts);
23.49 -typedef void (*PurpleDnsQueryFailedCallback) (PurpleDnsQueryData *query_data, const gchar *error_message);
23.50 -
23.51 -/**
23.52 - * DNS Request UI operations; UIs should implement this if they want to do DNS
23.53 - * lookups themselves, rather than relying on the core.
23.54 - *
23.55 - * @see @ref ui-ops
23.56 - */
23.57 -typedef struct
23.58 -{
23.59 - /** If implemented, the UI is responsible for DNS queries */
23.60 - gboolean (*resolve_host)(PurpleDnsQueryData *query_data,
23.61 - PurpleDnsQueryResolvedCallback resolved_cb,
23.62 - PurpleDnsQueryFailedCallback failed_cb);
23.63 -
23.64 - /** Called just before @a query_data is freed; this should cancel any
23.65 - * further use of @a query_data the UI would make. Unneeded if
23.66 - * #resolve_host is not implemented.
23.67 - */
23.68 - void (*destroy)(PurpleDnsQueryData *query_data);
23.69 -
23.70 - void (*_purple_reserved1)(void);
23.71 - void (*_purple_reserved2)(void);
23.72 - void (*_purple_reserved3)(void);
23.73 - void (*_purple_reserved4)(void);
23.74 -} PurpleDnsQueryUiOps;
23.75 -
23.76 -#ifdef __cplusplus
23.77 -extern "C" {
23.78 -#endif
23.79 -
23.80 -/**************************************************************************/
23.81 -/** @name DNS query API */
23.82 -/**************************************************************************/
23.83 -/*@{*/
23.84 -
23.85 -/**
23.86 - * Perform an asynchronous DNS query.
23.87 - *
23.88 - * @param hostname The hostname to resolve.
23.89 - * @param port A port number which is stored in the struct sockaddr.
23.90 - * @param callback The callback function to call after resolving.
23.91 - * @param data Extra data to pass to the callback function.
23.92 - *
23.93 - * @return NULL if there was an error, otherwise return a reference to
23.94 - * a data structure that can be used to cancel the pending
23.95 - * DNS query, if needed.
23.96 - */
23.97 -PurpleDnsQueryData *purple_dnsquery_a(const char *hostname, int port, PurpleDnsQueryConnectFunction callback, gpointer data);
23.98 -
23.99 -/**
23.100 - * Cancel a DNS query and destroy the associated data structure.
23.101 - *
23.102 - * @param query_data The DNS query to cancel. This data structure
23.103 - * is freed by this function.
23.104 - */
23.105 -void purple_dnsquery_destroy(PurpleDnsQueryData *query_data);
23.106 -
23.107 -/**
23.108 - * Sets the UI operations structure to be used when doing a DNS
23.109 - * resolve. The UI operations need only be set if the UI wants to
23.110 - * handle the resolve itself; otherwise, leave it as NULL.
23.111 - *
23.112 - * @param ops The UI operations structure.
23.113 - */
23.114 -void purple_dnsquery_set_ui_ops(PurpleDnsQueryUiOps *ops);
23.115 -
23.116 -/**
23.117 - * Returns the UI operations structure to be used when doing a DNS
23.118 - * resolve.
23.119 - *
23.120 - * @return The UI operations structure.
23.121 - */
23.122 -PurpleDnsQueryUiOps *purple_dnsquery_get_ui_ops(void);
23.123 -
23.124 -/**
23.125 - * Get the host associated with a PurpleDnsQueryData
23.126 - *
23.127 - * @param query_data The DNS query
23.128 - * @return The host.
23.129 - */
23.130 -char *purple_dnsquery_get_host(PurpleDnsQueryData *query_data);
23.131 -
23.132 -/**
23.133 - * Get the port associated with a PurpleDnsQueryData
23.134 - *
23.135 - * @param query_data The DNS query
23.136 - * @return The port.
23.137 - */
23.138 -unsigned short purple_dnsquery_get_port(PurpleDnsQueryData *query_data);
23.139 -
23.140 -/**
23.141 - * Initializes the DNS query subsystem.
23.142 - */
23.143 -void purple_dnsquery_init(void);
23.144 -
23.145 -/**
23.146 - * Uninitializes the DNS query subsystem.
23.147 - */
23.148 -void purple_dnsquery_uninit(void);
23.149 -
23.150 -/*@}*/
23.151 -
23.152 -#ifdef __cplusplus
23.153 -}
23.154 -#endif
23.155 -
23.156 -#endif /* _PURPLE_DNSQUERY_H_ */
24.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/dnssrv.h Sun Jun 21 22:04:11 2009 -0400
24.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
24.3 @@ -1,65 +0,0 @@
24.4 -/**
24.5 - * @file dnssrv.h
24.6 - */
24.7 -
24.8 -/* purple
24.9 - *
24.10 - * Copyright (C) 2005, Thomas Butter <butter@uni-mannheim.de>
24.11 - *
24.12 - * This program is free software; you can redistribute it and/or modify
24.13 - * it under the terms of the GNU General Public License as published by
24.14 - * the Free Software Foundation; either version 2 of the License, or
24.15 - * (at your option) any later version.
24.16 - *
24.17 - * This program is distributed in the hope that it will be useful,
24.18 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
24.19 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24.20 - * GNU General Public License for more details.
24.21 - *
24.22 - * You should have received a copy of the GNU General Public License
24.23 - * along with this program; if not, write to the Free Software
24.24 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
24.25 - */
24.26 -
24.27 -#ifndef _PURPLE_DNSSRV_H
24.28 -#define _PURPLE_DNSSRV_H
24.29 -
24.30 -#ifdef __cplusplus
24.31 -extern "C" {
24.32 -#endif
24.33 -
24.34 -typedef struct _PurpleSrvResponse PurpleSrvResponse;
24.35 -typedef struct _PurpleSrvQueryData PurpleSrvQueryData;
24.36 -
24.37 -struct _PurpleSrvResponse {
24.38 - char hostname[256];
24.39 - int port;
24.40 - int weight;
24.41 - int pref;
24.42 -};
24.43 -
24.44 -typedef void (*PurpleSrvCallback)(PurpleSrvResponse *resp, int results, gpointer data);
24.45 -
24.46 -/**
24.47 - * Queries an SRV record.
24.48 - *
24.49 - * @param protocol Name of the protocol (e.g. "sip")
24.50 - * @param transport Name of the transport ("tcp" or "udp")
24.51 - * @param domain Domain name to query (e.g. "blubb.com")
24.52 - * @param cb A callback which will be called with the results
24.53 - * @param extradata Extra data to be passed to the callback
24.54 - */
24.55 -PurpleSrvQueryData *purple_srv_resolve(const char *protocol, const char *transport, const char *domain, PurpleSrvCallback cb, gpointer extradata);
24.56 -
24.57 -/**
24.58 - * Cancel an SRV DNS query.
24.59 - *
24.60 - * @param query_data The request to cancel.
24.61 - */
24.62 -void purple_srv_cancel(PurpleSrvQueryData *query_data);
24.63 -
24.64 -#ifdef __cplusplus
24.65 -}
24.66 -#endif
24.67 -
24.68 -#endif /* _PURPLE_DNSSRV_H */
25.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/error.h Sun Jun 21 22:04:11 2009 -0400
25.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
25.3 @@ -1,47 +0,0 @@
25.4 -/**
25.5 - * @file error.h Error functions
25.6 - *
25.7 - * purple
25.8 - *
25.9 - * Purple is the legal property of its developers, whose names are too numerous
25.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
25.11 - * source distribution.
25.12 - *
25.13 - * This program is free software; you can redistribute it and/or modify
25.14 - * it under the terms of the GNU General Public License as published by
25.15 - * the Free Software Foundation; either version 2 of the License, or
25.16 - * (at your option) any later version.
25.17 - *
25.18 - * This program is distributed in the hope that it will be useful,
25.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
25.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25.21 - * GNU General Public License for more details.
25.22 - *
25.23 - * You should have received a copy of the GNU General Public License
25.24 - * along with this program; if not, write to the Free Software
25.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
25.26 - */
25.27 -#ifndef _MSN_ERROR_H_
25.28 -#define _MSN_ERROR_H_
25.29 -
25.30 -#include "session.h"
25.31 -
25.32 -/**
25.33 - * Returns the string representation of an error type.
25.34 - *
25.35 - * @param type The error type.
25.36 - * @param debug Whether this should be treated as a debug log message or a user-visible error
25.37 - *
25.38 - * @return The string representation of the error type.
25.39 - */
25.40 -const char *msn_error_get_text(unsigned int type, gboolean *debug);
25.41 -
25.42 -/**
25.43 - * Handles an error.
25.44 - *
25.45 - * @param session The current session.
25.46 - * @param type The error type.
25.47 - */
25.48 -void msn_error_handle(MsnSession *session, unsigned int type);
25.49 -
25.50 -#endif /* _MSN_ERROR_H_ */
26.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/eventloop.h Sun Jun 21 22:04:11 2009 -0400
26.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
26.3 @@ -1,276 +0,0 @@
26.4 -/**
26.5 - * @file eventloop.h Purple Event Loop API
26.6 - * @ingroup core
26.7 - */
26.8 -
26.9 -/* purple
26.10 - *
26.11 - * Purple is the legal property of its developers, whose names are too numerous
26.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
26.13 - * source distribution.
26.14 - *
26.15 - * This program is free software; you can redistribute it and/or modify
26.16 - * it under the terms of the GNU General Public License as published by
26.17 - * the Free Software Foundation; either version 2 of the License, or
26.18 - * (at your option) any later version.
26.19 - *
26.20 - * This program is distributed in the hope that it will be useful,
26.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
26.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
26.23 - * GNU General Public License for more details.
26.24 - *
26.25 - * You should have received a copy of the GNU General Public License
26.26 - * along with this program; if not, write to the Free Software
26.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
26.28 - */
26.29 -#ifndef _PURPLE_EVENTLOOP_H_
26.30 -#define _PURPLE_EVENTLOOP_H_
26.31 -
26.32 -#include <glib.h>
26.33 -
26.34 -#ifdef __cplusplus
26.35 -extern "C" {
26.36 -#endif
26.37 -
26.38 -/**
26.39 - * An input condition.
26.40 - */
26.41 -typedef enum
26.42 -{
26.43 - PURPLE_INPUT_READ = 1 << 0, /**< A read condition. */
26.44 - PURPLE_INPUT_WRITE = 1 << 1 /**< A write condition. */
26.45 -
26.46 -} PurpleInputCondition;
26.47 -
26.48 -/** The type of callbacks to handle events on file descriptors, as passed to
26.49 - * purple_input_add(). The callback will receive the @c user_data passed to
26.50 - * purple_input_add(), the file descriptor on which the event occurred, and the
26.51 - * condition that was satisfied to cause the callback to be invoked.
26.52 - */
26.53 -typedef void (*PurpleInputFunction)(gpointer, gint, PurpleInputCondition);
26.54 -
26.55 -/** @copydoc _PurpleEventLoopUiOps */
26.56 -typedef struct _PurpleEventLoopUiOps PurpleEventLoopUiOps;
26.57 -
26.58 -/** An abstraction of an application's mainloop; libpurple will use this to
26.59 - * watch file descriptors and schedule timed callbacks. If your application
26.60 - * uses the glib mainloop, there is an implementation of this struct in
26.61 - * <tt>libpurple/example/nullclient.c</tt> which you can use verbatim.
26.62 - */
26.63 -struct _PurpleEventLoopUiOps
26.64 -{
26.65 - /**
26.66 - * Should create a callback timer with an interval measured in
26.67 - * milliseconds. The supplied @a function should be called every @a
26.68 - * interval seconds until it returns @c FALSE, after which it should not
26.69 - * be called again.
26.70 - *
26.71 - * Analogous to g_timeout_add in glib.
26.72 - *
26.73 - * Note: On Win32, this function may be called from a thread other than
26.74 - * the libpurple thread. You should make sure to detect this situation
26.75 - * and to only call "function" from the libpurple thread.
26.76 - *
26.77 - * @param interval the interval in <em>milliseconds</em> between calls
26.78 - * to @a function.
26.79 - * @param data arbitrary data to be passed to @a function at each
26.80 - * call.
26.81 - * @todo Who is responsible for freeing @a data?
26.82 - *
26.83 - * @return a handle for the timeout, which can be passed to
26.84 - * #timeout_remove.
26.85 - *
26.86 - * @see purple_timeout_add
26.87 - **/
26.88 - guint (*timeout_add)(guint interval, GSourceFunc function, gpointer data);
26.89 -
26.90 - /**
26.91 - * Should remove a callback timer. Analogous to g_source_remove in glib.
26.92 - * @param handle an identifier for a timeout, as returned by
26.93 - * #timeout_add.
26.94 - * @return @c TRUE if the timeout identified by @a handle was
26.95 - * found and removed.
26.96 - * @see purple_timeout_remove
26.97 - */
26.98 - gboolean (*timeout_remove)(guint handle);
26.99 -
26.100 - /**
26.101 - * Should add an input handler. Analogous to g_io_add_watch_full in
26.102 - * glib.
26.103 - *
26.104 - * @param fd a file descriptor to watch for events
26.105 - * @param cond a bitwise OR of events on @a fd for which @a func
26.106 - * should be called.
26.107 - * @param func a callback to fire whenever a relevant event on @a
26.108 - * fd occurs.
26.109 - * @param user_data arbitrary data to pass to @a fd.
26.110 - * @return an identifier for this input handler, which can be
26.111 - * passed to #input_remove.
26.112 - *
26.113 - * @see purple_input_add
26.114 - */
26.115 - guint (*input_add)(int fd, PurpleInputCondition cond,
26.116 - PurpleInputFunction func, gpointer user_data);
26.117 -
26.118 - /**
26.119 - * Should remove an input handler. Analogous to g_source_remove in glib.
26.120 - * @param handle an identifier, as returned by #input_add.
26.121 - * @return @c TRUE if the input handler was found and removed.
26.122 - * @see purple_input_remove
26.123 - */
26.124 - gboolean (*input_remove)(guint handle);
26.125 -
26.126 -
26.127 - /**
26.128 - * If implemented, should get the current error status for an input.
26.129 - *
26.130 - * Implementation of this UI op is optional. Implement it if the UI's
26.131 - * sockets or event loop needs to customize determination of socket
26.132 - * error status. If unimplemented, <tt>getsockopt(2)</tt> will be used
26.133 - * instead.
26.134 - *
26.135 - * @see purple_input_get_error
26.136 - */
26.137 - int (*input_get_error)(int fd, int *error);
26.138 -
26.139 - /**
26.140 - * If implemented, should create a callback timer with an interval
26.141 - * measured in seconds. Analogous to g_timeout_add_seconds in glib.
26.142 - *
26.143 - * This allows UIs to group timers for better power efficiency. For
26.144 - * this reason, @a interval may be rounded by up to a second.
26.145 - *
26.146 - * Implementation of this UI op is optional. If it's not implemented,
26.147 - * calls to purple_timeout_add_seconds() will be serviced by
26.148 - * #timeout_add.
26.149 - *
26.150 - * @see purple_timeout_add_seconds()
26.151 - * @since 2.1.0
26.152 - **/
26.153 - guint (*timeout_add_seconds)(guint interval, GSourceFunc function,
26.154 - gpointer data);
26.155 -
26.156 - void (*_purple_reserved2)(void);
26.157 - void (*_purple_reserved3)(void);
26.158 - void (*_purple_reserved4)(void);
26.159 -};
26.160 -
26.161 -/**************************************************************************/
26.162 -/** @name Event Loop API */
26.163 -/**************************************************************************/
26.164 -/*@{*/
26.165 -/**
26.166 - * Creates a callback timer.
26.167 - *
26.168 - * The timer will repeat until the function returns @c FALSE. The
26.169 - * first call will be at the end of the first interval.
26.170 - *
26.171 - * If the timer is in a multiple of seconds, use purple_timeout_add_seconds()
26.172 - * instead as it allows UIs to group timers for power efficiency.
26.173 - *
26.174 - * @param interval The time between calls of the function, in
26.175 - * milliseconds.
26.176 - * @param function The function to call.
26.177 - * @param data data to pass to @a function.
26.178 - * @return A handle to the timer which can be passed to
26.179 - * purple_timeout_remove() to remove the timer.
26.180 - */
26.181 -guint purple_timeout_add(guint interval, GSourceFunc function, gpointer data);
26.182 -
26.183 -/**
26.184 - * Creates a callback timer.
26.185 - *
26.186 - * The timer will repeat until the function returns @c FALSE. The
26.187 - * first call will be at the end of the first interval.
26.188 - *
26.189 - * This function allows UIs to group timers for better power efficiency. For
26.190 - * this reason, @a interval may be rounded by up to a second.
26.191 - *
26.192 - * @param interval The time between calls of the function, in
26.193 - * seconds.
26.194 - * @param function The function to call.
26.195 - * @param data data to pass to @a function.
26.196 - * @return A handle to the timer which can be passed to
26.197 - * purple_timeout_remove() to remove the timer.
26.198 - *
26.199 - * @since 2.1.0
26.200 - */
26.201 -guint purple_timeout_add_seconds(guint interval, GSourceFunc function, gpointer data);
26.202 -
26.203 -/**
26.204 - * Removes a timeout handler.
26.205 - *
26.206 - * @param handle The handle, as returned by purple_timeout_add().
26.207 - *
26.208 - * @return @c TRUE if the handler was successfully removed.
26.209 - */
26.210 -gboolean purple_timeout_remove(guint handle);
26.211 -
26.212 -/**
26.213 - * Adds an input handler.
26.214 - *
26.215 - * @param fd The input file descriptor.
26.216 - * @param cond The condition type.
26.217 - * @param func The callback function for data.
26.218 - * @param user_data User-specified data.
26.219 - *
26.220 - * @return The resulting handle (will be greater than 0).
26.221 - * @see g_io_add_watch_full
26.222 - */
26.223 -guint purple_input_add(int fd, PurpleInputCondition cond,
26.224 - PurpleInputFunction func, gpointer user_data);
26.225 -
26.226 -/**
26.227 - * Removes an input handler.
26.228 - *
26.229 - * @param handle The handle of the input handler. Note that this is the return
26.230 - * value from purple_input_add(), <i>not</i> the file descriptor.
26.231 - */
26.232 -gboolean purple_input_remove(guint handle);
26.233 -
26.234 -/**
26.235 - * Get the current error status for an input.
26.236 - *
26.237 - * The return value and error follow getsockopt() with a level of SOL_SOCKET and an
26.238 - * option name of SO_ERROR, and this is how the error is determined if the UI does not
26.239 - * implement the input_get_error UI op.
26.240 - *
26.241 - * @param fd The input file descriptor.
26.242 - * @param error A pointer to an @c int which on return will have the error, or
26.243 - * @c 0 if no error.
26.244 - *
26.245 - * @return @c 0 if there is no error; @c -1 if there is an error, in which case
26.246 - * @a errno will be set.
26.247 - */
26.248 -int
26.249 -purple_input_get_error(int fd, int *error);
26.250 -
26.251 -
26.252 -/*@}*/
26.253 -
26.254 -
26.255 -/**************************************************************************/
26.256 -/** @name UI Registration Functions */
26.257 -/**************************************************************************/
26.258 -/*@{*/
26.259 -/**
26.260 - * Sets the UI operations structure to be used for accounts.
26.261 - *
26.262 - * @param ops The UI operations structure.
26.263 - */
26.264 -void purple_eventloop_set_ui_ops(PurpleEventLoopUiOps *ops);
26.265 -
26.266 -/**
26.267 - * Returns the UI operations structure used for accounts.
26.268 - *
26.269 - * @return The UI operations structure in use.
26.270 - */
26.271 -PurpleEventLoopUiOps *purple_eventloop_get_ui_ops(void);
26.272 -
26.273 -/*@}*/
26.274 -
26.275 -#ifdef __cplusplus
26.276 -}
26.277 -#endif
26.278 -
26.279 -#endif /* _PURPLE_EVENTLOOP_H_ */
27.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/fix_purple.h Sun Jun 21 22:04:11 2009 -0400
27.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
27.3 @@ -1,51 +0,0 @@
27.4 -/**
27.5 - * Copyright (C) 2007-2008 Felipe Contreras
27.6 - *
27.7 - * This program is free software; you can redistribute it and/or modify
27.8 - * it under the terms of the GNU General Public License as published by
27.9 - * the Free Software Foundation; either version 2 of the License, or
27.10 - * (at your option) any later version.
27.11 - *
27.12 - * This program is distributed in the hope that it will be useful,
27.13 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
27.14 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
27.15 - * GNU General Public License for more details.
27.16 - *
27.17 - * You should have received a copy of the GNU General Public License along
27.18 - * with this program; if not, write to the Free Software Foundation, Inc.,
27.19 - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
27.20 - */
27.21 -
27.22 -#ifndef FIX_PURPLE_H
27.23 -#define FIX_PURPLE_H
27.24 -
27.25 -struct _PurpleConnection;
27.26 -
27.27 -#include <glib.h>
27.28 -
27.29 -#if !GLIB_CHECK_VERSION(2,3,1)
27.30 -
27.31 -#if GLIB_SIZEOF_LONG == 8
27.32 -#define G_GSIZE_FORMAT "lu"
27.33 -#else
27.34 -#define G_GSIZE_FORMAT "u"
27.35 -#endif
27.36 -
27.37 -#endif /* !GLIB_CHECK_VERSION(2,3,1) */
27.38 -
27.39 -#if !GLIB_CHECK_VERSION(2,14,0)
27.40 -static inline guint
27.41 -g_timeout_add_seconds (guint interval,
27.42 - GSourceFunc function,
27.43 - gpointer data)
27.44 -{
27.45 - g_return_val_if_fail (function != NULL, 0);
27.46 -
27.47 - return g_timeout_add_full (G_PRIORITY_DEFAULT, interval * 1000, function, data, NULL);
27.48 -}
27.49 -#endif /* !GLIB_CHECK_VERSION(2,14,0) */
27.50 -
27.51 -void purple_buddy_set_displayname (struct _PurpleConnection *gc, const gchar *who, const gchar *value);
27.52 -void purple_buddy_set_nickname (struct _PurpleConnection *gc, const gchar *who, const gchar *value);
27.53 -
27.54 -#endif /* FIX_PURPLE_H */
28.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/fix_purple_win32.h Sun Jun 21 22:04:11 2009 -0400
28.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
28.3 @@ -1,30 +0,0 @@
28.4 -/**
28.5 - * Copyright (C) 2007-2008 Felipe Contreras
28.6 - *
28.7 - * This program is free software; you can redistribute it and/or modify
28.8 - * it under the terms of the GNU General Public License as published by
28.9 - * the Free Software Foundation; either version 2 of the License, or
28.10 - * (at your option) any later version.
28.11 - *
28.12 - * This program is distributed in the hope that it will be useful,
28.13 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
28.14 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
28.15 - * GNU General Public License for more details.
28.16 - *
28.17 - * You should have received a copy of the GNU General Public License along
28.18 - * with this program; if not, write to the Free Software Foundation, Inc.,
28.19 - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
28.20 - */
28.21 -
28.22 -#ifndef FIX_PURPLE_WIN32_H
28.23 -#define FIX_PURPLE_WIN32_H
28.24 -
28.25 -#ifndef G_GNUC_NULL_TERMINATED
28.26 -#if __GNUC__ >= 4
28.27 -#define G_GNUC_NULL_TERMINATED __attribute__((__sentinel__))
28.28 -#else
28.29 -#define G_GNUC_NULL_TERMINATED
28.30 -#endif
28.31 -#endif
28.32 -
28.33 -#endif /* FIX_PURPLE_WIN32_H */
29.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/ft.h Sun Jun 21 22:04:11 2009 -0400
29.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
29.3 @@ -1,664 +0,0 @@
29.4 -/**
29.5 - * @file ft.h File Transfer API
29.6 - * @ingroup core
29.7 - * @see @ref xfer-signals
29.8 - */
29.9 -
29.10 -/* purple
29.11 - *
29.12 - * Purple is the legal property of its developers, whose names are too numerous
29.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
29.14 - * source distribution.
29.15 - *
29.16 - * This program is free software; you can redistribute it and/or modify
29.17 - * it under the terms of the GNU General Public License as published by
29.18 - * the Free Software Foundation; either version 2 of the License, or
29.19 - * (at your option) any later version.
29.20 - *
29.21 - * This program is distributed in the hope that it will be useful,
29.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
29.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29.24 - * GNU General Public License for more details.
29.25 - *
29.26 - * You should have received a copy of the GNU General Public License
29.27 - * along with this program; if not, write to the Free Software
29.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
29.29 - */
29.30 -#ifndef _PURPLE_FT_H_
29.31 -#define _PURPLE_FT_H_
29.32 -
29.33 -/**************************************************************************/
29.34 -/** Data Structures */
29.35 -/**************************************************************************/
29.36 -typedef struct _PurpleXfer PurpleXfer;
29.37 -
29.38 -#include <glib.h>
29.39 -#include <stdio.h>
29.40 -
29.41 -#include "account.h"
29.42 -
29.43 -/**
29.44 - * Types of file transfers.
29.45 - */
29.46 -typedef enum
29.47 -{
29.48 - PURPLE_XFER_UNKNOWN = 0, /**< Unknown file transfer type. */
29.49 - PURPLE_XFER_SEND, /**< File sending. */
29.50 - PURPLE_XFER_RECEIVE /**< File receiving. */
29.51 -
29.52 -} PurpleXferType;
29.53 -
29.54 -/**
29.55 - * The different states of the xfer.
29.56 - */
29.57 -typedef enum
29.58 -{
29.59 - PURPLE_XFER_STATUS_UNKNOWN = 0, /**< Unknown, the xfer may be null. */
29.60 - PURPLE_XFER_STATUS_NOT_STARTED, /**< It hasn't started yet. */
29.61 - PURPLE_XFER_STATUS_ACCEPTED, /**< Receive accepted, but destination file not selected yet */
29.62 - PURPLE_XFER_STATUS_STARTED, /**< purple_xfer_start has been called. */
29.63 - PURPLE_XFER_STATUS_DONE, /**< The xfer completed successfully. */
29.64 - PURPLE_XFER_STATUS_CANCEL_LOCAL, /**< The xfer was canceled by us. */
29.65 - PURPLE_XFER_STATUS_CANCEL_REMOTE /**< The xfer was canceled by the other end, or we couldn't connect. */
29.66 -} PurpleXferStatusType;
29.67 -
29.68 -/**
29.69 - * File transfer UI operations.
29.70 - *
29.71 - * Any UI representing a file transfer must assign a filled-out
29.72 - * PurpleXferUiOps structure to the purple_xfer.
29.73 - */
29.74 -typedef struct
29.75 -{
29.76 - void (*new_xfer)(PurpleXfer *xfer);
29.77 - void (*destroy)(PurpleXfer *xfer);
29.78 - void (*add_xfer)(PurpleXfer *xfer);
29.79 - void (*update_progress)(PurpleXfer *xfer, double percent);
29.80 - void (*cancel_local)(PurpleXfer *xfer);
29.81 - void (*cancel_remote)(PurpleXfer *xfer);
29.82 -
29.83 - void (*_purple_reserved1)(void);
29.84 - void (*_purple_reserved2)(void);
29.85 - void (*_purple_reserved3)(void);
29.86 - void (*_purple_reserved4)(void);
29.87 -} PurpleXferUiOps;
29.88 -
29.89 -/**
29.90 - * A core representation of a file transfer.
29.91 - */
29.92 -struct _PurpleXfer
29.93 -{
29.94 - guint ref; /**< The reference count. */
29.95 - PurpleXferType type; /**< The type of transfer. */
29.96 -
29.97 - PurpleAccount *account; /**< The account. */
29.98 -
29.99 - char *who; /**< The person on the other end of the
29.100 - transfer. */
29.101 -
29.102 - char *message; /**< A message sent with the request */
29.103 - char *filename; /**< The name sent over the network. */
29.104 - char *local_filename; /**< The name on the local hard drive. */
29.105 - size_t size; /**< The size of the file. */
29.106 -
29.107 - FILE *dest_fp; /**< The destination file pointer. */
29.108 -
29.109 - char *remote_ip; /**< The remote IP address. */
29.110 - int local_port; /**< The local port. */
29.111 - int remote_port; /**< The remote port. */
29.112 -
29.113 - int fd; /**< The socket file descriptor. */
29.114 - int watcher; /**< Watcher. */
29.115 -
29.116 - size_t bytes_sent; /**< The number of bytes sent. */
29.117 - size_t bytes_remaining; /**< The number of bytes remaining. */
29.118 - time_t start_time; /**< When the transfer of data began. */
29.119 - time_t end_time; /**< When the transfer of data ended. */
29.120 -
29.121 - size_t current_buffer_size; /**< This gradually increases for fast
29.122 - network connections. */
29.123 -
29.124 - PurpleXferStatusType status; /**< File Transfer's status. */
29.125 -
29.126 - /* I/O operations. */
29.127 - struct
29.128 - {
29.129 - void (*init)(PurpleXfer *xfer);
29.130 - void (*request_denied)(PurpleXfer *xfer);
29.131 - void (*start)(PurpleXfer *xfer);
29.132 - void (*end)(PurpleXfer *xfer);
29.133 - void (*cancel_send)(PurpleXfer *xfer);
29.134 - void (*cancel_recv)(PurpleXfer *xfer);
29.135 - gssize (*read)(guchar **buffer, PurpleXfer *xfer);
29.136 - gssize (*write)(const guchar *buffer, size_t size, PurpleXfer *xfer);
29.137 - void (*ack)(PurpleXfer *xfer, const guchar *buffer, size_t size);
29.138 -
29.139 - } ops;
29.140 -
29.141 - PurpleXferUiOps *ui_ops; /**< UI-specific operations. */
29.142 - void *ui_data; /**< UI-specific data. */
29.143 -
29.144 - void *data; /**< prpl-specific data. */
29.145 -};
29.146 -
29.147 -#ifdef __cplusplus
29.148 -extern "C" {
29.149 -#endif
29.150 -
29.151 -/**************************************************************************/
29.152 -/** @name File Transfer API */
29.153 -/**************************************************************************/
29.154 -/*@{*/
29.155 -
29.156 -/**
29.157 - * Creates a new file transfer handle.
29.158 - * This is called by prpls.
29.159 - * The handle starts with a ref count of 1, and this reference
29.160 - * is owned by the core. The prpl normally does not need to
29.161 - * purple_xfer_ref or unref.
29.162 - *
29.163 - * @param account The account sending or receiving the file.
29.164 - * @param type The type of file transfer.
29.165 - * @param who The name of the remote user.
29.166 - *
29.167 - * @return A file transfer handle.
29.168 - */
29.169 -PurpleXfer *purple_xfer_new(PurpleAccount *account,
29.170 - PurpleXferType type, const char *who);
29.171 -
29.172 -/**
29.173 - * Returns all xfers
29.174 - *
29.175 - * @return all current xfers with refs
29.176 - */
29.177 -GList *purple_xfers_get_all(void);
29.178 -
29.179 -/**
29.180 - * Increases the reference count on a PurpleXfer.
29.181 - * Please call purple_xfer_unref later.
29.182 - *
29.183 - * @param xfer A file transfer handle.
29.184 - */
29.185 -void purple_xfer_ref(PurpleXfer *xfer);
29.186 -
29.187 -/**
29.188 - * Decreases the reference count on a PurpleXfer.
29.189 - * If the reference reaches 0, purple_xfer_destroy (an internal function)
29.190 - * will destroy the xfer. It calls the ui destroy cb first.
29.191 - * Since the core keeps a ref on the xfer, only an erroneous call to
29.192 - * this function will destroy the xfer while still in use.
29.193 - *
29.194 - * @param xfer A file transfer handle.
29.195 - */
29.196 -void purple_xfer_unref(PurpleXfer *xfer);
29.197 -
29.198 -/**
29.199 - * Requests confirmation for a file transfer from the user. If receiving
29.200 - * a file which is known at this point, this requests user to accept and
29.201 - * save the file. If the filename is unknown (not set) this only requests user
29.202 - * to accept the file transfer. In this case protocol must call this function
29.203 - * again once the filename is available.
29.204 - *
29.205 - * @param xfer The file transfer to request confirmation on.
29.206 - */
29.207 -void purple_xfer_request(PurpleXfer *xfer);
29.208 -
29.209 -/**
29.210 - * Called if the user accepts the file transfer request.
29.211 - *
29.212 - * @param xfer The file transfer.
29.213 - * @param filename The filename.
29.214 - */
29.215 -void purple_xfer_request_accepted(PurpleXfer *xfer, const char *filename);
29.216 -
29.217 -/**
29.218 - * Called if the user rejects the file transfer request.
29.219 - *
29.220 - * @param xfer The file transfer.
29.221 - */
29.222 -void purple_xfer_request_denied(PurpleXfer *xfer);
29.223 -
29.224 -/**
29.225 - * Returns the type of file transfer.
29.226 - *
29.227 - * @param xfer The file transfer.
29.228 - *
29.229 - * @return The type of the file transfer.
29.230 - */
29.231 -PurpleXferType purple_xfer_get_type(const PurpleXfer *xfer);
29.232 -
29.233 -/**
29.234 - * Returns the account the file transfer is using.
29.235 - *
29.236 - * @param xfer The file transfer.
29.237 - *
29.238 - * @return The account.
29.239 - */
29.240 -PurpleAccount *purple_xfer_get_account(const PurpleXfer *xfer);
29.241 -
29.242 -/**
29.243 - * Returns the name of the remote user.
29.244 - *
29.245 - * @param xfer The file transfer.
29.246 - *
29.247 - * @return The name of the remote user.
29.248 - *
29.249 - * @since 2.1.0
29.250 - */
29.251 -const char *purple_xfer_get_remote_user(const PurpleXfer *xfer);
29.252 -
29.253 -/**
29.254 - * Returns the status of the xfer.
29.255 - *
29.256 - * @param xfer The file transfer.
29.257 - *
29.258 - * @return The status.
29.259 - */
29.260 -PurpleXferStatusType purple_xfer_get_status(const PurpleXfer *xfer);
29.261 -
29.262 -/**
29.263 - * Returns true if the file transfer was canceled.
29.264 - *
29.265 - * @param xfer The file transfer.
29.266 - *
29.267 - * @return Whether or not the transfer was canceled.
29.268 - */
29.269 -gboolean purple_xfer_is_canceled(const PurpleXfer *xfer);
29.270 -
29.271 -/**
29.272 - * Returns the completed state for a file transfer.
29.273 - *
29.274 - * @param xfer The file transfer.
29.275 - *
29.276 - * @return The completed state.
29.277 - */
29.278 -gboolean purple_xfer_is_completed(const PurpleXfer *xfer);
29.279 -
29.280 -/**
29.281 - * Returns the name of the file being sent or received.
29.282 - *
29.283 - * @param xfer The file transfer.
29.284 - *
29.285 - * @return The filename.
29.286 - */
29.287 -const char *purple_xfer_get_filename(const PurpleXfer *xfer);
29.288 -
29.289 -/**
29.290 - * Returns the file's destination filename,
29.291 - *
29.292 - * @param xfer The file transfer.
29.293 - *
29.294 - * @return The destination filename.
29.295 - */
29.296 -const char *purple_xfer_get_local_filename(const PurpleXfer *xfer);
29.297 -
29.298 -/**
29.299 - * Returns the number of bytes sent (or received) so far.
29.300 - *
29.301 - * @param xfer The file transfer.
29.302 - *
29.303 - * @return The number of bytes sent.
29.304 - */
29.305 -size_t purple_xfer_get_bytes_sent(const PurpleXfer *xfer);
29.306 -
29.307 -/**
29.308 - * Returns the number of bytes remaining to send or receive.
29.309 - *
29.310 - * @param xfer The file transfer.
29.311 - *
29.312 - * @return The number of bytes remaining.
29.313 - */
29.314 -size_t purple_xfer_get_bytes_remaining(const PurpleXfer *xfer);
29.315 -
29.316 -/**
29.317 - * Returns the size of the file being sent or received.
29.318 - *
29.319 - * @param xfer The file transfer.
29.320 - *
29.321 - * @return The total size of the file.
29.322 - */
29.323 -size_t purple_xfer_get_size(const PurpleXfer *xfer);
29.324 -
29.325 -/**
29.326 - * Returns the current percentage of progress of the transfer.
29.327 - *
29.328 - * This is a number between 0 (0%) and 1 (100%).
29.329 - *
29.330 - * @param xfer The file transfer.
29.331 - *
29.332 - * @return The percentage complete.
29.333 - */
29.334 -double purple_xfer_get_progress(const PurpleXfer *xfer);
29.335 -
29.336 -/**
29.337 - * Returns the local port number in the file transfer.
29.338 - *
29.339 - * @param xfer The file transfer.
29.340 - *
29.341 - * @return The port number on this end.
29.342 - */
29.343 -unsigned int purple_xfer_get_local_port(const PurpleXfer *xfer);
29.344 -
29.345 -/**
29.346 - * Returns the remote IP address in the file transfer.
29.347 - *
29.348 - * @param xfer The file transfer.
29.349 - *
29.350 - * @return The IP address on the other end.
29.351 - */
29.352 -const char *purple_xfer_get_remote_ip(const PurpleXfer *xfer);
29.353 -
29.354 -/**
29.355 - * Returns the remote port number in the file transfer.
29.356 - *
29.357 - * @param xfer The file transfer.
29.358 - *
29.359 - * @return The port number on the other end.
29.360 - */
29.361 -unsigned int purple_xfer_get_remote_port(const PurpleXfer *xfer);
29.362 -
29.363 -/**
29.364 - * Returns the time the transfer of a file started.
29.365 - *
29.366 - * @param xfer The file transfer.
29.367 - *
29.368 - * @return The time when the transfer started.
29.369 - * @since 2.4.0
29.370 - */
29.371 -time_t purple_xfer_get_start_time(const PurpleXfer *xfer);
29.372 -
29.373 -/**
29.374 - * Returns the time the transfer of a file ended.
29.375 - *
29.376 - * @param xfer The file transfer.
29.377 - *
29.378 - * @return The time when the transfer ended.
29.379 - * @since 2.4.0
29.380 - */
29.381 -time_t purple_xfer_get_end_time(const PurpleXfer *xfer);
29.382 -
29.383 -/**
29.384 - * Sets the completed state for the file transfer.
29.385 - *
29.386 - * @param xfer The file transfer.
29.387 - * @param completed The completed state.
29.388 - */
29.389 -void purple_xfer_set_completed(PurpleXfer *xfer, gboolean completed);
29.390 -
29.391 -/**
29.392 - * Sets the filename for the file transfer.
29.393 - *
29.394 - * @param xfer The file transfer.
29.395 - * @param message The message.
29.396 - */
29.397 -void purple_xfer_set_message(PurpleXfer *xfer, const char *message);
29.398 -
29.399 -/**
29.400 - * Sets the filename for the file transfer.
29.401 - *
29.402 - * @param xfer The file transfer.
29.403 - * @param filename The filename.
29.404 - */
29.405 -void purple_xfer_set_filename(PurpleXfer *xfer, const char *filename);
29.406 -
29.407 -/**
29.408 - * Sets the local filename for the file transfer.
29.409 - *
29.410 - * @param xfer The file transfer.
29.411 - * @param filename The filename
29.412 - */
29.413 -void purple_xfer_set_local_filename(PurpleXfer *xfer, const char *filename);
29.414 -
29.415 -/**
29.416 - * Sets the size of the file in a file transfer.
29.417 - *
29.418 - * @param xfer The file transfer.
29.419 - * @param size The size of the file.
29.420 - */
29.421 -void purple_xfer_set_size(PurpleXfer *xfer, size_t size);
29.422 -
29.423 -/**
29.424 - * Sets the current working position in the active file transfer. This
29.425 - * can be used to jump backward in the file if the protocol detects
29.426 - * that some bit of data needs to be resent or has been sent twice.
29.427 - *
29.428 - * It's used for pausing and resuming an oscar file transfer.
29.429 - *
29.430 - * @param xfer The file transfer.
29.431 - * @param bytes_sent The new current position in the file. If we're
29.432 - * sending a file then this is the byte that we will
29.433 - * send. If we're receiving a file, this is the
29.434 - * next byte that we expect to receive.
29.435 - */
29.436 -void purple_xfer_set_bytes_sent(PurpleXfer *xfer, size_t bytes_sent);
29.437 -
29.438 -/**
29.439 - * Returns the UI operations structure for a file transfer.
29.440 - *
29.441 - * @param xfer The file transfer.
29.442 - *
29.443 - * @return The UI operations structure.
29.444 - */
29.445 -PurpleXferUiOps *purple_xfer_get_ui_ops(const PurpleXfer *xfer);
29.446 -
29.447 -/**
29.448 - * Sets the read function for the file transfer.
29.449 - *
29.450 - * @param xfer The file transfer.
29.451 - * @param fnc The read function.
29.452 - */
29.453 -void purple_xfer_set_read_fnc(PurpleXfer *xfer,
29.454 - gssize (*fnc)(guchar **, PurpleXfer *));
29.455 -
29.456 -/**
29.457 - * Sets the write function for the file transfer.
29.458 - *
29.459 - * @param xfer The file transfer.
29.460 - * @param fnc The write function.
29.461 - */
29.462 -void purple_xfer_set_write_fnc(PurpleXfer *xfer,
29.463 - gssize (*fnc)(const guchar *, size_t, PurpleXfer *));
29.464 -
29.465 -/**
29.466 - * Sets the acknowledge function for the file transfer.
29.467 - *
29.468 - * @param xfer The file transfer.
29.469 - * @param fnc The acknowledge function.
29.470 - */
29.471 -void purple_xfer_set_ack_fnc(PurpleXfer *xfer,
29.472 - void (*fnc)(PurpleXfer *, const guchar *, size_t));
29.473 -
29.474 -/**
29.475 - * Sets the function to be called if the request is denied.
29.476 - *
29.477 - * @param xfer The file transfer.
29.478 - * @param fnc The request denied prpl callback.
29.479 - */
29.480 -void purple_xfer_set_request_denied_fnc(PurpleXfer *xfer, void (*fnc)(PurpleXfer *));
29.481 -
29.482 -/**
29.483 - * Sets the transfer initialization function for the file transfer.
29.484 - *
29.485 - * This function is required, and must call purple_xfer_start() with
29.486 - * the necessary parameters. This will be called if the file transfer
29.487 - * is accepted by the user.
29.488 - *
29.489 - * @param xfer The file transfer.
29.490 - * @param fnc The transfer initialization function.
29.491 - */
29.492 -void purple_xfer_set_init_fnc(PurpleXfer *xfer, void (*fnc)(PurpleXfer *));
29.493 -
29.494 -/**
29.495 - * Sets the start transfer function for the file transfer.
29.496 - *
29.497 - * @param xfer The file transfer.
29.498 - * @param fnc The start transfer function.
29.499 - */
29.500 -void purple_xfer_set_start_fnc(PurpleXfer *xfer, void (*fnc)(PurpleXfer *));
29.501 -
29.502 -/**
29.503 - * Sets the end transfer function for the file transfer.
29.504 - *
29.505 - * @param xfer The file transfer.
29.506 - * @param fnc The end transfer function.
29.507 - */
29.508 -void purple_xfer_set_end_fnc(PurpleXfer *xfer, void (*fnc)(PurpleXfer *));
29.509 -
29.510 -/**
29.511 - * Sets the cancel send function for the file transfer.
29.512 - *
29.513 - * @param xfer The file transfer.
29.514 - * @param fnc The cancel send function.
29.515 - */
29.516 -void purple_xfer_set_cancel_send_fnc(PurpleXfer *xfer, void (*fnc)(PurpleXfer *));
29.517 -
29.518 -/**
29.519 - * Sets the cancel receive function for the file transfer.
29.520 - *
29.521 - * @param xfer The file transfer.
29.522 - * @param fnc The cancel receive function.
29.523 - */
29.524 -void purple_xfer_set_cancel_recv_fnc(PurpleXfer *xfer, void (*fnc)(PurpleXfer *));
29.525 -
29.526 -/**
29.527 - * Reads in data from a file transfer stream.
29.528 - *
29.529 - * @param xfer The file transfer.
29.530 - * @param buffer The buffer that will be created to contain the data.
29.531 - *
29.532 - * @return The number of bytes read, or -1.
29.533 - */
29.534 -gssize purple_xfer_read(PurpleXfer *xfer, guchar **buffer);
29.535 -
29.536 -/**
29.537 - * Writes data to a file transfer stream.
29.538 - *
29.539 - * @param xfer The file transfer.
29.540 - * @param buffer The buffer to read the data from.
29.541 - * @param size The number of bytes to write.
29.542 - *
29.543 - * @return The number of bytes written, or -1.
29.544 - */
29.545 -gssize purple_xfer_write(PurpleXfer *xfer, const guchar *buffer, gsize size);
29.546 -
29.547 -/**
29.548 - * Starts a file transfer.
29.549 - *
29.550 - * Either @a fd must be specified <i>or</i> @a ip and @a port on a
29.551 - * file receive transfer. On send, @a fd must be specified, and
29.552 - * @a ip and @a port are ignored.
29.553 - *
29.554 - * @param xfer The file transfer.
29.555 - * @param fd The file descriptor for the socket.
29.556 - * @param ip The IP address to connect to.
29.557 - * @param port The port to connect to.
29.558 - */
29.559 -void purple_xfer_start(PurpleXfer *xfer, int fd, const char *ip,
29.560 - unsigned int port);
29.561 -
29.562 -/**
29.563 - * Ends a file transfer.
29.564 - *
29.565 - * @param xfer The file transfer.
29.566 - */
29.567 -void purple_xfer_end(PurpleXfer *xfer);
29.568 -
29.569 -/**
29.570 - * Adds a new file transfer to the list of file transfers. Call this only
29.571 - * if you are not using purple_xfer_start.
29.572 - *
29.573 - * @param xfer The file transfer.
29.574 - */
29.575 -void purple_xfer_add(PurpleXfer *xfer);
29.576 -
29.577 -/**
29.578 - * Cancels a file transfer on the local end.
29.579 - *
29.580 - * @param xfer The file transfer.
29.581 - */
29.582 -void purple_xfer_cancel_local(PurpleXfer *xfer);
29.583 -
29.584 -/**
29.585 - * Cancels a file transfer from the remote end.
29.586 - *
29.587 - * @param xfer The file transfer.
29.588 - */
29.589 -void purple_xfer_cancel_remote(PurpleXfer *xfer);
29.590 -
29.591 -/**
29.592 - * Displays a file transfer-related error message.
29.593 - *
29.594 - * This is a wrapper around purple_notify_error(), which automatically
29.595 - * specifies a title ("File transfer to <i>user</i> failed" or
29.596 - * "File Transfer from <i>user</i> failed").
29.597 - *
29.598 - * @param type The type of file transfer.
29.599 - * @param account The account sending or receiving the file.
29.600 - * @param who The user on the other end of the transfer.
29.601 - * @param msg The message to display.
29.602 - */
29.603 -void purple_xfer_error(PurpleXferType type, PurpleAccount *account, const char *who, const char *msg);
29.604 -
29.605 -/**
29.606 - * Updates file transfer progress.
29.607 - *
29.608 - * @param xfer The file transfer.
29.609 - */
29.610 -void purple_xfer_update_progress(PurpleXfer *xfer);
29.611 -
29.612 -/**
29.613 - * Displays a file transfer-related message in the conversation window
29.614 - *
29.615 - * This is a wrapper around purple_conversation_write
29.616 - *
29.617 - * @param xfer The file transfer to which this message relates.
29.618 - * @param message The message to display.
29.619 - * @param is_error Is this an error message?.
29.620 - */
29.621 -void purple_xfer_conversation_write(PurpleXfer *xfer, char *message, gboolean is_error);
29.622 -
29.623 -/*@}*/
29.624 -
29.625 -/**************************************************************************/
29.626 -/** @name UI Registration Functions */
29.627 -/**************************************************************************/
29.628 -/*@{*/
29.629 -
29.630 -/**
29.631 - * Returns the handle to the file transfer subsystem
29.632 - *
29.633 - * @return The handle
29.634 - */
29.635 -void *purple_xfers_get_handle(void);
29.636 -
29.637 -/**
29.638 - * Initializes the file transfer subsystem
29.639 - */
29.640 -void purple_xfers_init(void);
29.641 -
29.642 -/**
29.643 - * Uninitializes the file transfer subsystem
29.644 - */
29.645 -void purple_xfers_uninit(void);
29.646 -
29.647 -/**
29.648 - * Sets the UI operations structure to be used in all purple file transfers.
29.649 - *
29.650 - * @param ops The UI operations structure.
29.651 - */
29.652 -void purple_xfers_set_ui_ops(PurpleXferUiOps *ops);
29.653 -
29.654 -/**
29.655 - * Returns the UI operations structure to be used in all purple file transfers.
29.656 - *
29.657 - * @return The UI operations structure.
29.658 - */
29.659 -PurpleXferUiOps *purple_xfers_get_ui_ops(void);
29.660 -
29.661 -/*@}*/
29.662 -
29.663 -#ifdef __cplusplus
29.664 -}
29.665 -#endif
29.666 -
29.667 -#endif /* _PURPLE_FT_H_ */
30.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/gaim-compat.h Sun Jun 21 22:04:11 2009 -0400
30.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
30.3 @@ -1,2317 +0,0 @@
30.4 -/**
30.5 - * @file gaim-compat.h Gaim Compat macros
30.6 - * @ingroup core
30.7 - */
30.8 -
30.9 -/* pidgin
30.10 - *
30.11 - * Pidgin is the legal property of its developers, whose names are too numerous
30.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
30.13 - * source distribution.
30.14 - *
30.15 - * This program is free software; you can redistribute it and/or modify
30.16 - * it under the terms of the GNU General Public License as published by
30.17 - * the Free Software Foundation; either version 2 of the License, or
30.18 - * (at your option) any later version.
30.19 - *
30.20 - * This program is distributed in the hope that it will be useful,
30.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
30.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30.23 - * GNU General Public License for more details.
30.24 - *
30.25 - * You should have received a copy of the GNU General Public License
30.26 - * along with this program; if not, write to the Free Software
30.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
30.28 - */
30.29 -#ifndef _GAIM_COMPAT_H_
30.30 -#define _GAIM_COMPAT_H_
30.31 -
30.32 -#include <glib.h>
30.33 -
30.34 -/* from account.h */
30.35 -#define GaimAccountUiOps PurpleAccountUiOps
30.36 -#define GaimAccount PurpleAccount
30.37 -
30.38 -#define GaimFilterAccountFunc PurpleFilterAccountFunc
30.39 -#define GaimAccountRequestAuthorizationCb PurpleAccountRequestAuthorizationCb
30.40 -
30.41 -#define gaim_account_new purple_account_new
30.42 -#define gaim_account_destroy purple_account_destroy
30.43 -#define gaim_account_connect purple_account_connect
30.44 -#define gaim_account_register purple_account_register
30.45 -#define gaim_account_disconnect purple_account_disconnect
30.46 -#define gaim_account_notify_added purple_account_notify_added
30.47 -#define gaim_account_request_add purple_account_request_add
30.48 -#define gaim_account_request_close purple_account_request_close
30.49 -
30.50 -#define gaim_account_request_authorization purple_account_request_authorization
30.51 -#define gaim_account_request_change_password purple_account_request_change_password
30.52 -#define gaim_account_request_change_user_info purple_account_request_change_user_info
30.53 -
30.54 -#define gaim_account_set_username purple_account_set_username
30.55 -#define gaim_account_set_password purple_account_set_password
30.56 -#define gaim_account_set_alias purple_account_set_alias
30.57 -#define gaim_account_set_user_info purple_account_set_user_info
30.58 -#define gaim_account_set_buddy_icon_path purple_account_set_buddy_icon_path
30.59 -#define gaim_account_set_protocol_id purple_account_set_protocol_id
30.60 -#define gaim_account_set_connection purple_account_set_connection
30.61 -#define gaim_account_set_remember_password purple_account_set_remember_password
30.62 -#define gaim_account_set_check_mail purple_account_set_check_mail
30.63 -#define gaim_account_set_enabled purple_account_set_enabled
30.64 -#define gaim_account_set_proxy_info purple_account_set_proxy_info
30.65 -#define gaim_account_set_status_types purple_account_set_status_types
30.66 -#define gaim_account_set_status purple_account_set_status
30.67 -#define gaim_account_set_status_list purple_account_set_status_list
30.68 -
30.69 -#define gaim_account_clear_settings purple_account_clear_settings
30.70 -
30.71 -#define gaim_account_set_int purple_account_set_int
30.72 -#define gaim_account_set_string purple_account_set_string
30.73 -#define gaim_account_set_bool purple_account_set_bool
30.74 -
30.75 -#define gaim_account_set_ui_int purple_account_set_ui_int
30.76 -#define gaim_account_set_ui_string purple_account_set_ui_string
30.77 -#define gaim_account_set_ui_bool purple_account_set_ui_bool
30.78 -
30.79 -#define gaim_account_is_connected purple_account_is_connected
30.80 -#define gaim_account_is_connecting purple_account_is_connecting
30.81 -#define gaim_account_is_disconnected purple_account_is_disconnected
30.82 -
30.83 -#define gaim_account_get_username purple_account_get_username
30.84 -#define gaim_account_get_password purple_account_get_password
30.85 -#define gaim_account_get_alias purple_account_get_alias
30.86 -#define gaim_account_get_user_info purple_account_get_user_info
30.87 -#define gaim_account_get_buddy_icon_path purple_account_get_buddy_icon_path
30.88 -#define gaim_account_get_protocol_id purple_account_get_protocol_id
30.89 -#define gaim_account_get_protocol_name purple_account_get_protocol_name
30.90 -#define gaim_account_get_connection purple_account_get_connection
30.91 -#define gaim_account_get_remember_password purple_account_get_remember_password
30.92 -#define gaim_account_get_check_mail purple_account_get_check_mail
30.93 -#define gaim_account_get_enabled purple_account_get_enabled
30.94 -#define gaim_account_get_proxy_info purple_account_get_proxy_info
30.95 -#define gaim_account_get_active_status purple_account_get_active_status
30.96 -#define gaim_account_get_status purple_account_get_status
30.97 -#define gaim_account_get_status_type purple_account_get_status_type
30.98 -#define gaim_account_get_status_type_with_primitive \
30.99 - purple_account_get_status_type_with_primitive
30.100 -
30.101 -#define gaim_account_get_presence purple_account_get_presence
30.102 -#define gaim_account_is_status_active purple_account_is_status_active
30.103 -#define gaim_account_get_status_types purple_account_get_status_types
30.104 -
30.105 -#define gaim_account_get_int purple_account_get_int
30.106 -#define gaim_account_get_string purple_account_get_string
30.107 -#define gaim_account_get_bool purple_account_get_bool
30.108 -
30.109 -#define gaim_account_get_ui_int purple_account_get_ui_int
30.110 -#define gaim_account_get_ui_string purple_account_get_ui_string
30.111 -#define gaim_account_get_ui_bool purple_account_get_ui_bool
30.112 -
30.113 -
30.114 -#define gaim_account_get_log purple_account_get_log
30.115 -#define gaim_account_destroy_log purple_account_destroy_log
30.116 -
30.117 -#define gaim_account_add_buddy purple_account_add_buddy
30.118 -#define gaim_account_add_buddies purple_account_add_buddies
30.119 -#define gaim_account_remove_buddy purple_account_remove_buddy
30.120 -#define gaim_account_remove_buddies purple_account_remove_buddies
30.121 -
30.122 -#define gaim_account_remove_group purple_account_remove_group
30.123 -
30.124 -#define gaim_account_change_password purple_account_change_password
30.125 -
30.126 -#define gaim_account_supports_offline_message purple_account_supports_offline_message
30.127 -
30.128 -#define gaim_accounts_add purple_accounts_add
30.129 -#define gaim_accounts_remove purple_accounts_remove
30.130 -#define gaim_accounts_delete purple_accounts_delete
30.131 -#define gaim_accounts_reorder purple_accounts_reorder
30.132 -
30.133 -#define gaim_accounts_get_all purple_accounts_get_all
30.134 -#define gaim_accounts_get_all_active purple_accounts_get_all_active
30.135 -
30.136 -#define gaim_accounts_find purple_accounts_find
30.137 -
30.138 -#define gaim_accounts_restore_current_statuses purple_accounts_restore_current_statuses
30.139 -
30.140 -#define gaim_accounts_set_ui_ops purple_accounts_set_ui_ops
30.141 -#define gaim_accounts_get_ui_ops purple_accounts_get_ui_ops
30.142 -
30.143 -#define gaim_accounts_get_handle purple_accounts_get_handle
30.144 -
30.145 -#define gaim_accounts_init purple_accounts_init
30.146 -#define gaim_accounts_uninit purple_accounts_uninit
30.147 -
30.148 -/* from accountopt.h */
30.149 -
30.150 -#define GaimAccountOption PurpleAccountOption
30.151 -#define GaimAccountUserSplit PurpleAccountUserSplit
30.152 -
30.153 -#define gaim_account_option_new purple_account_option_new
30.154 -#define gaim_account_option_bool_new purple_account_option_bool_new
30.155 -#define gaim_account_option_int_new purple_account_option_int_new
30.156 -#define gaim_account_option_string_new purple_account_option_string_new
30.157 -#define gaim_account_option_list_new purple_account_option_list_new
30.158 -
30.159 -#define gaim_account_option_destroy purple_account_option_destroy
30.160 -
30.161 -#define gaim_account_option_set_default_bool purple_account_option_set_default_bool
30.162 -#define gaim_account_option_set_default_int purple_account_option_set_default_int
30.163 -#define gaim_account_option_set_default_string purple_account_option_set_default_string
30.164 -
30.165 -#define gaim_account_option_set_masked purple_account_option_set_masked
30.166 -
30.167 -#define gaim_account_option_set_list purple_account_option_set_list
30.168 -
30.169 -#define gaim_account_option_add_list_item purple_account_option_add_list_item
30.170 -
30.171 -#define gaim_account_option_get_type purple_account_option_get_type
30.172 -#define gaim_account_option_get_text purple_account_option_get_text
30.173 -#define gaim_account_option_get_setting purple_account_option_get_setting
30.174 -
30.175 -#define gaim_account_option_get_default_bool purple_account_option_get_default_bool
30.176 -#define gaim_account_option_get_default_int purple_account_option_get_default_int
30.177 -#define gaim_account_option_get_default_string purple_account_option_get_default_string
30.178 -#define gaim_account_option_get_default_list_value purple_account_option_get_default_list_value
30.179 -
30.180 -#define gaim_account_option_get_masked purple_account_option_get_masked
30.181 -#define gaim_account_option_get_list purple_account_option_get_list
30.182 -
30.183 -#define gaim_account_user_split_new purple_account_user_split_new
30.184 -#define gaim_account_user_split_destroy purple_account_user_split_destroy
30.185 -
30.186 -#define gaim_account_user_split_get_text purple_account_user_split_get_text
30.187 -#define gaim_account_user_split_get_default_value purple_account_user_split_get_default_value
30.188 -#define gaim_account_user_split_get_separator purple_account_user_split_get_separator
30.189 -
30.190 -/* from blist.h */
30.191 -
30.192 -#define GaimBuddyList PurpleBuddyList
30.193 -#define GaimBlistUiOps PurpleBlistUiOps
30.194 -#define GaimBlistNode PurpleBlistNode
30.195 -
30.196 -#define GaimChat PurpleChat
30.197 -#define GaimGroup PurpleGroup
30.198 -#define GaimContact PurpleContact
30.199 -#define GaimBuddy PurpleBuddy
30.200 -
30.201 -#define GAIM_BLIST_GROUP_NODE PURPLE_BLIST_GROUP_NODE
30.202 -#define GAIM_BLIST_CONTACT_NODE PURPLE_BLIST_CONTACT_NODE
30.203 -#define GAIM_BLIST_BUDDY_NODE PURPLE_BLIST_BUDDY_NODE
30.204 -#define GAIM_BLIST_CHAT_NODE PURPLE_BLIST_CHAT_NODE
30.205 -#define GAIM_BLIST_OTHER_NODE PURPLE_BLIST_OTHER_NODE
30.206 -#define GaimBlistNodeType PurpleBlistNodeType
30.207 -
30.208 -#define GAIM_BLIST_NODE_IS_CHAT PURPLE_BLIST_NODE_IS_CHAT
30.209 -#define GAIM_BLIST_NODE_IS_BUDDY PURPLE_BLIST_NODE_IS_BUDDY
30.210 -#define GAIM_BLIST_NODE_IS_CONTACT PURPLE_BLIST_NODE_IS_CONTACT
30.211 -#define GAIM_BLIST_NODE_IS_GROUP PURPLE_BLIST_NODE_IS_GROUP
30.212 -
30.213 -#define GAIM_BUDDY_IS_ONLINE PURPLE_BUDDY_IS_ONLINE
30.214 -
30.215 -#define GAIM_BLIST_NODE_FLAG_NO_SAVE PURPLE_BLIST_NODE_FLAG_NO_SAVE
30.216 -#define GaimBlistNodeFlags PurpleBlistNodeFlags
30.217 -
30.218 -#define GAIM_BLIST_NODE_HAS_FLAG PURPLE_BLIST_NODE_HAS_FLAG
30.219 -#define GAIM_BLIST_NODE_SHOULD_SAVE PURPLE_BLIST_NODE_SHOULD_SAVE
30.220 -
30.221 -#define GAIM_BLIST_NODE_NAME PURPLE_BLIST_NODE_NAME
30.222 -
30.223 -
30.224 -#define gaim_blist_new purple_blist_new
30.225 -#define gaim_set_blist purple_set_blist
30.226 -#define gaim_get_blist purple_get_blist
30.227 -
30.228 -#define gaim_blist_get_root purple_blist_get_root
30.229 -#define gaim_blist_node_next purple_blist_node_next
30.230 -
30.231 -#define gaim_blist_show purple_blist_show
30.232 -
30.233 -#define gaim_blist_destroy purple_blist_destroy
30.234 -
30.235 -#define gaim_blist_set_visible purple_blist_set_visible
30.236 -
30.237 -#define gaim_blist_update_buddy_status purple_blist_update_buddy_status
30.238 -#define gaim_blist_update_buddy_icon purple_blist_update_buddy_icon
30.239 -
30.240 -
30.241 -#define gaim_blist_alias_contact purple_blist_alias_contact
30.242 -#define gaim_blist_alias_buddy purple_blist_alias_buddy
30.243 -#define gaim_blist_server_alias_buddy purple_blist_server_alias_buddy
30.244 -#define gaim_blist_alias_chat purple_blist_alias_chat
30.245 -
30.246 -#define gaim_blist_rename_buddy purple_blist_rename_buddy
30.247 -#define gaim_blist_rename_group purple_blist_rename_group
30.248 -
30.249 -#define gaim_chat_new purple_chat_new
30.250 -#define gaim_blist_add_chat purple_blist_add_chat
30.251 -
30.252 -#define gaim_buddy_new purple_buddy_new
30.253 -#define gaim_buddy_set_icon purple_buddy_set_icon
30.254 -#define gaim_buddy_get_account purple_buddy_get_account
30.255 -#define gaim_buddy_get_name purple_buddy_get_name
30.256 -#define gaim_buddy_get_icon purple_buddy_get_icon
30.257 -#define gaim_buddy_get_contact purple_buddy_get_contact
30.258 -#define gaim_buddy_get_presence purple_buddy_get_presence
30.259 -
30.260 -#define gaim_blist_add_buddy purple_blist_add_buddy
30.261 -
30.262 -#define gaim_group_new purple_group_new
30.263 -
30.264 -#define gaim_blist_add_group purple_blist_add_group
30.265 -
30.266 -#define gaim_contact_new purple_contact_new
30.267 -
30.268 -#define gaim_blist_add_contact purple_blist_add_contact
30.269 -#define gaim_blist_merge_contact purple_blist_merge_contact
30.270 -
30.271 -#define gaim_contact_get_priority_buddy purple_contact_get_priority_buddy
30.272 -#define gaim_contact_set_alias purple_contact_set_alias
30.273 -#define gaim_contact_get_alias purple_contact_get_alias
30.274 -#define gaim_contact_on_account purple_contact_on_account
30.275 -
30.276 -#define gaim_contact_invalidate_priority_buddy purple_contact_invalidate_priority_buddy
30.277 -
30.278 -#define gaim_blist_remove_buddy purple_blist_remove_buddy
30.279 -#define gaim_blist_remove_contact purple_blist_remove_contact
30.280 -#define gaim_blist_remove_chat purple_blist_remove_chat
30.281 -#define gaim_blist_remove_group purple_blist_remove_group
30.282 -
30.283 -#define gaim_buddy_get_alias_only purple_buddy_get_alias_only
30.284 -#define gaim_buddy_get_server_alias purple_buddy_get_server_alias
30.285 -#define gaim_buddy_get_contact_alias purple_buddy_get_contact_alias
30.286 -#define gaim_buddy_get_local_alias purple_buddy_get_local_alias
30.287 -#define gaim_buddy_get_alias purple_buddy_get_alias
30.288 -
30.289 -#define gaim_chat_get_name purple_chat_get_name
30.290 -
30.291 -#define gaim_find_buddy purple_find_buddy
30.292 -#define gaim_find_buddy_in_group purple_find_buddy_in_group
30.293 -#define gaim_find_buddies purple_find_buddies
30.294 -
30.295 -#define gaim_find_group purple_find_group
30.296 -
30.297 -#define gaim_blist_find_chat purple_blist_find_chat
30.298 -
30.299 -#define gaim_chat_get_group purple_chat_get_group
30.300 -#define gaim_buddy_get_group purple_buddy_get_group
30.301 -
30.302 -#define gaim_group_get_accounts purple_group_get_accounts
30.303 -#define gaim_group_on_account purple_group_on_account
30.304 -
30.305 -#define gaim_blist_add_account purple_blist_add_account
30.306 -#define gaim_blist_remove_account purple_blist_remove_account
30.307 -
30.308 -#define gaim_blist_get_group_size purple_blist_get_group_size
30.309 -#define gaim_blist_get_group_online_count purple_blist_get_group_online_count
30.310 -
30.311 -#define gaim_blist_load purple_blist_load
30.312 -#define gaim_blist_schedule_save purple_blist_schedule_save
30.313 -
30.314 -#define gaim_blist_request_add_buddy purple_blist_request_add_buddy
30.315 -#define gaim_blist_request_add_chat purple_blist_request_add_chat
30.316 -#define gaim_blist_request_add_group purple_blist_request_add_group
30.317 -
30.318 -#define gaim_blist_node_set_bool purple_blist_node_set_bool
30.319 -#define gaim_blist_node_get_bool purple_blist_node_get_bool
30.320 -#define gaim_blist_node_set_int purple_blist_node_set_int
30.321 -#define gaim_blist_node_get_int purple_blist_node_get_int
30.322 -#define gaim_blist_node_set_string purple_blist_node_set_string
30.323 -#define gaim_blist_node_get_string purple_blist_node_get_string
30.324 -
30.325 -#define gaim_blist_node_remove_setting purple_blist_node_remove_setting
30.326 -
30.327 -#define gaim_blist_node_set_flags purple_blist_node_set_flags
30.328 -#define gaim_blist_node_get_flags purple_blist_node_get_flags
30.329 -
30.330 -#define gaim_blist_node_get_extended_menu purple_blist_node_get_extended_menu
30.331 -
30.332 -#define gaim_blist_set_ui_ops purple_blist_set_ui_ops
30.333 -#define gaim_blist_get_ui_ops purple_blist_get_ui_ops
30.334 -
30.335 -#define gaim_blist_get_handle purple_blist_get_handle
30.336 -
30.337 -#define gaim_blist_init purple_blist_init
30.338 -#define gaim_blist_uninit purple_blist_uninit
30.339 -
30.340 -
30.341 -#define GaimBuddyIcon PurpleBuddyIcon
30.342 -
30.343 -#define gaim_buddy_icon_new(account, username, icon_data, icon_len)\
30.344 - purple_buddy_icon_new(account, username, g_memdup(icon_data, icon_len), icon_len)
30.345 -#define gaim_buddy_icon_ref purple_buddy_icon_ref
30.346 -#define gaim_buddy_icon_unref purple_buddy_icon_unref
30.347 -#define gaim_buddy_icon_update purple_buddy_icon_update
30.348 -
30.349 -#define gaim_buddy_icon_set_data(icon, data, len) \
30.350 - purple_buddy_icon_set_data(icon, g_memdup(data, len), len, NULL);
30.351 -
30.352 -#define gaim_buddy_icon_get_account purple_buddy_icon_get_account
30.353 -#define gaim_buddy_icon_get_username purple_buddy_icon_get_username
30.354 -#define gaim_buddy_icon_get_data purple_buddy_icon_get_data
30.355 -#define gaim_buddy_icon_get_type purple_buddy_icon_get_extension
30.356 -
30.357 -#define gaim_buddy_icons_set_for_user(icon, data, len) \
30.358 - purple_buddy_icons_set_for_user(icon, g_memdup(data, len), len, NULL)
30.359 -#define gaim_buddy_icons_set_caching purple_buddy_icons_set_caching
30.360 -#define gaim_buddy_icons_is_caching purple_buddy_icons_is_caching
30.361 -#define gaim_buddy_icons_set_cache_dir purple_buddy_icons_set_cache_dir
30.362 -#define gaim_buddy_icons_get_cache_dir purple_buddy_icons_get_cache_dir
30.363 -#define gaim_buddy_icons_get_handle purple_buddy_icons_get_handle
30.364 -
30.365 -#define gaim_buddy_icons_init purple_buddy_icons_init
30.366 -#define gaim_buddy_icons_uninit purple_buddy_icons_uninit
30.367 -
30.368 -#define gaim_buddy_icon_get_scale_size purple_buddy_icon_get_scale_size
30.369 -
30.370 -/* from cipher.h */
30.371 -
30.372 -#define GAIM_CIPHER PURPLE_CIPHER
30.373 -#define GAIM_CIPHER_OPS PURPLE_CIPHER_OPS
30.374 -#define GAIM_CIPHER_CONTEXT PURPLE_CIPHER_CONTEXT
30.375 -
30.376 -#define GaimCipher PurpleCipher
30.377 -#define GaimCipherOps PurpleCipherOps
30.378 -#define GaimCipherContext PurpleCipherContext
30.379 -
30.380 -#define GAIM_CIPHER_CAPS_SET_OPT PURPLE_CIPHER_CAPS_SET_OPT
30.381 -#define GAIM_CIPHER_CAPS_GET_OPT PURPLE_CIPHER_CAPS_GET_OPT
30.382 -#define GAIM_CIPHER_CAPS_INIT PURPLE_CIPHER_CAPS_INIT
30.383 -#define GAIM_CIPHER_CAPS_RESET PURPLE_CIPHER_CAPS_RESET
30.384 -#define GAIM_CIPHER_CAPS_UNINIT PURPLE_CIPHER_CAPS_UNINIT
30.385 -#define GAIM_CIPHER_CAPS_SET_IV PURPLE_CIPHER_CAPS_SET_IV
30.386 -#define GAIM_CIPHER_CAPS_APPEND PURPLE_CIPHER_CAPS_APPEND
30.387 -#define GAIM_CIPHER_CAPS_DIGEST PURPLE_CIPHER_CAPS_DIGEST
30.388 -#define GAIM_CIPHER_CAPS_ENCRYPT PURPLE_CIPHER_CAPS_ENCRYPT
30.389 -#define GAIM_CIPHER_CAPS_DECRYPT PURPLE_CIPHER_CAPS_DECRYPT
30.390 -#define GAIM_CIPHER_CAPS_SET_SALT PURPLE_CIPHER_CAPS_SET_SALT
30.391 -#define GAIM_CIPHER_CAPS_GET_SALT_SIZE PURPLE_CIPHER_CAPS_GET_SALT_SIZE
30.392 -#define GAIM_CIPHER_CAPS_SET_KEY PURPLE_CIPHER_CAPS_SET_KEY
30.393 -#define GAIM_CIPHER_CAPS_GET_KEY_SIZE PURPLE_CIPHER_CAPS_GET_KEY_SIZE
30.394 -#define GAIM_CIPHER_CAPS_UNKNOWN PURPLE_CIPHER_CAPS_UNKNOWN
30.395 -
30.396 -#define gaim_cipher_get_name purple_cipher_get_name
30.397 -#define gaim_cipher_get_capabilities purple_cipher_get_capabilities
30.398 -#define gaim_cipher_digest_region purple_cipher_digest_region
30.399 -
30.400 -#define gaim_ciphers_find_cipher purple_ciphers_find_cipher
30.401 -#define gaim_ciphers_register_cipher purple_ciphers_register_cipher
30.402 -#define gaim_ciphers_unregister_cipher purple_ciphers_unregister_cipher
30.403 -#define gaim_ciphers_get_ciphers purple_ciphers_get_ciphers
30.404 -
30.405 -#define gaim_ciphers_get_handle purple_ciphers_get_handle
30.406 -#define gaim_ciphers_init purple_ciphers_init
30.407 -#define gaim_ciphers_uninit purple_ciphers_uninit
30.408 -
30.409 -#define gaim_cipher_context_set_option purple_cipher_context_set_option
30.410 -#define gaim_cipher_context_get_option purple_cipher_context_get_option
30.411 -
30.412 -#define gaim_cipher_context_new purple_cipher_context_new
30.413 -#define gaim_cipher_context_new_by_name purple_cipher_context_new_by_name
30.414 -#define gaim_cipher_context_reset purple_cipher_context_reset
30.415 -#define gaim_cipher_context_destroy purple_cipher_context_destroy
30.416 -#define gaim_cipher_context_set_iv purple_cipher_context_set_iv
30.417 -#define gaim_cipher_context_append purple_cipher_context_append
30.418 -#define gaim_cipher_context_digest purple_cipher_context_digest
30.419 -#define gaim_cipher_context_digest_to_str purple_cipher_context_digest_to_str
30.420 -#define gaim_cipher_context_encrypt purple_cipher_context_encrypt
30.421 -#define gaim_cipher_context_decrypt purple_cipher_context_decrypt
30.422 -#define gaim_cipher_context_set_salt purple_cipher_context_set_salt
30.423 -#define gaim_cipher_context_get_salt_size purple_cipher_context_get_salt_size
30.424 -#define gaim_cipher_context_set_key purple_cipher_context_set_key
30.425 -#define gaim_cipher_context_get_key_size purple_cipher_context_get_key_size
30.426 -#define gaim_cipher_context_set_data purple_cipher_context_set_data
30.427 -#define gaim_cipher_context_get_data purple_cipher_context_get_data
30.428 -
30.429 -#define gaim_cipher_http_digest_calculate_session_key \
30.430 - purple_cipher_http_digest_calculate_session_key
30.431 -
30.432 -#define gaim_cipher_http_digest_calculate_response \
30.433 - purple_cipher_http_digest_calculate_response
30.434 -
30.435 -/* from circbuffer.h */
30.436 -
30.437 -#define GaimCircBuffer PurpleCircBuffer
30.438 -
30.439 -#define gaim_circ_buffer_new purple_circ_buffer_new
30.440 -#define gaim_circ_buffer_destroy purple_circ_buffer_destroy
30.441 -#define gaim_circ_buffer_append purple_circ_buffer_append
30.442 -#define gaim_circ_buffer_get_max_read purple_circ_buffer_get_max_read
30.443 -#define gaim_circ_buffer_mark_read purple_circ_buffer_mark_read
30.444 -
30.445 -/* from cmds.h */
30.446 -
30.447 -#define GaimCmdPriority PurpleCmdPriority
30.448 -#define GaimCmdFlag PurpleCmdFlag
30.449 -#define GaimCmdStatus PurpleCmdStatus
30.450 -#define GaimCmdRet PurpleCmdRet
30.451 -
30.452 -#define GAIM_CMD_STATUS_OK PURPLE_CMD_STATUS_OK
30.453 -#define GAIM_CMD_STATUS_FAILED PURPLE_CMD_STATUS_FAILED
30.454 -#define GAIM_CMD_STATUS_NOT_FOUND PURPLE_CMD_STATUS_NOT_FOUND
30.455 -#define GAIM_CMD_STATUS_WRONG_ARGS PURPLE_CMD_STATUS_WRONG_ARGS
30.456 -#define GAIM_CMD_STATUS_WRONG_PRPL PURPLE_CMD_STATUS_WRONG_PRPL
30.457 -#define GAIM_CMD_STATUS_WRONG_TYPE PURPLE_CMD_STATUS_WRONG_TYPE
30.458 -
30.459 -#define GAIM_CMD_FUNC PURPLE_CMD_FUNC
30.460 -
30.461 -#define GAIM_CMD_RET_OK PURPLE_CMD_RET_OK
30.462 -#define GAIM_CMD_RET_FAILED PURPLE_CMD_RET_FAILED
30.463 -#define GAIM_CMD_RET_CONTINUE PURPLE_CMD_RET_CONTINUE
30.464 -
30.465 -#define GAIM_CMD_P_VERY_LOW PURPLE_CMD_P_VERY_LOW
30.466 -#define GAIM_CMD_P_LOW PURPLE_CMD_P_LOW
30.467 -#define GAIM_CMD_P_DEFAULT PURPLE_CMD_P_DEFAULT
30.468 -#define GAIM_CMD_P_PRPL PURPLE_CMD_P_PRPL
30.469 -#define GAIM_CMD_P_PLUGIN PURPLE_CMD_P_PLUGIN
30.470 -#define GAIM_CMD_P_ALIAS PURPLE_CMD_P_ALIAS
30.471 -#define GAIM_CMD_P_HIGH PURPLE_CMD_P_HIGH
30.472 -#define GAIM_CMD_P_VERY_HIGH PURPLE_CMD_P_VERY_HIGH
30.473 -
30.474 -#define GAIM_CMD_FLAG_IM PURPLE_CMD_FLAG_IM
30.475 -#define GAIM_CMD_FLAG_CHAT PURPLE_CMD_FLAG_CHAT
30.476 -#define GAIM_CMD_FLAG_PRPL_ONLY PURPLE_CMD_FLAG_PRPL_ONLY
30.477 -#define GAIM_CMD_FLAG_ALLOW_WRONG_ARGS PURPLE_CMD_FLAG_ALLOW_WRONG_ARGS
30.478 -
30.479 -
30.480 -#define GaimCmdFunc PurpleCmdFunc
30.481 -
30.482 -#define GaimCmdId PurpleCmdId
30.483 -
30.484 -#define gaim_cmd_register purple_cmd_register
30.485 -#define gaim_cmd_unregister purple_cmd_unregister
30.486 -#define gaim_cmd_do_command purple_cmd_do_command
30.487 -#define gaim_cmd_list purple_cmd_list
30.488 -#define gaim_cmd_help purple_cmd_help
30.489 -
30.490 -/* from connection.h */
30.491 -
30.492 -#define GaimConnection PurpleConnection
30.493 -
30.494 -#define GAIM_CONNECTION_HTML PURPLE_CONNECTION_HTML
30.495 -#define GAIM_CONNECTION_NO_BGCOLOR PURPLE_CONNECTION_NO_BGCOLOR
30.496 -#define GAIM_CONNECTION_AUTO_RESP PURPLE_CONNECTION_AUTO_RESP
30.497 -#define GAIM_CONNECTION_FORMATTING_WBFO PURPLE_CONNECTION_FORMATTING_WBFO
30.498 -#define GAIM_CONNECTION_NO_NEWLINES PURPLE_CONNECTION_NO_NEWLINES
30.499 -#define GAIM_CONNECTION_NO_FONTSIZE PURPLE_CONNECTION_NO_FONTSIZE
30.500 -#define GAIM_CONNECTION_NO_URLDESC PURPLE_CONNECTION_NO_URLDESC
30.501 -#define GAIM_CONNECTION_NO_IMAGES PURPLE_CONNECTION_NO_IMAGES
30.502 -
30.503 -#define GaimConnectionFlags PurpleConnectionFlags
30.504 -
30.505 -#define GAIM_DISCONNECTED PURPLE_DISCONNECTED
30.506 -#define GAIM_CONNECTED PURPLE_CONNECTED
30.507 -#define GAIM_CONNECTING PURPLE_CONNECTING
30.508 -
30.509 -#define GaimConnectionState PurpleConnectionState
30.510 -
30.511 -#define GaimConnectionUiOps PurpleConnectionUiOps
30.512 -
30.513 -#define gaim_connection_new purple_connection_new
30.514 -#define gaim_connection_destroy purple_connection_destroy
30.515 -
30.516 -#define gaim_connection_set_state purple_connection_set_state
30.517 -#define gaim_connection_set_account purple_connection_set_account
30.518 -#define gaim_connection_set_display_name purple_connection_set_display_name
30.519 -#define gaim_connection_get_state purple_connection_get_state
30.520 -
30.521 -#define GAIM_CONNECTION_IS_CONNECTED PURPLE_CONNECTION_IS_CONNECTED
30.522 -
30.523 -#define gaim_connection_get_account purple_connection_get_account
30.524 -#define gaim_connection_get_password purple_connection_get_password
30.525 -#define gaim_connection_get_display_name purple_connection_get_display_name
30.526 -
30.527 -#define gaim_connection_update_progress purple_connection_update_progress
30.528 -
30.529 -#define gaim_connection_notice purple_connection_notice
30.530 -#define gaim_connection_error purple_connection_error
30.531 -
30.532 -#define gaim_connections_disconnect_all purple_connections_disconnect_all
30.533 -
30.534 -#define gaim_connections_get_all purple_connections_get_all
30.535 -#define gaim_connections_get_connecting purple_connections_get_connecting
30.536 -
30.537 -#define GAIM_CONNECTION_IS_VALID PURPLE_CONNECTION_IS_VALID
30.538 -
30.539 -#define gaim_connections_set_ui_ops purple_connections_set_ui_ops
30.540 -#define gaim_connections_get_ui_ops purple_connections_get_ui_ops
30.541 -
30.542 -#define gaim_connections_init purple_connections_init
30.543 -#define gaim_connections_uninit purple_connections_uninit
30.544 -#define gaim_connections_get_handle purple_connections_get_handle
30.545 -
30.546 -
30.547 -/* from conversation.h */
30.548 -
30.549 -#define GaimConversationUiOps PurpleConversationUiOps
30.550 -#define GaimConversation PurpleConversation
30.551 -#define GaimConvIm PurpleConvIm
30.552 -#define GaimConvChat PurpleConvChat
30.553 -#define GaimConvChatBuddy PurpleConvChatBuddy
30.554 -
30.555 -#define GAIM_CONV_TYPE_UNKNOWN PURPLE_CONV_TYPE_UNKNOWN
30.556 -#define GAIM_CONV_TYPE_IM PURPLE_CONV_TYPE_IM
30.557 -#define GAIM_CONV_TYPE_CHAT PURPLE_CONV_TYPE_CHAT
30.558 -#define GAIM_CONV_TYPE_MISC PURPLE_CONV_TYPE_MISC
30.559 -#define GAIM_CONV_TYPE_ANY PURPLE_CONV_TYPE_ANY
30.560 -
30.561 -#define GaimConversationType PurpleConversationType
30.562 -
30.563 -#define GAIM_CONV_UPDATE_ADD PURPLE_CONV_UPDATE_ADD
30.564 -#define GAIM_CONV_UPDATE_REMOVE PURPLE_CONV_UPDATE_REMOVE
30.565 -#define GAIM_CONV_UPDATE_ACCOUNT PURPLE_CONV_UPDATE_ACCOUNT
30.566 -#define GAIM_CONV_UPDATE_TYPING PURPLE_CONV_UPDATE_TYPING
30.567 -#define GAIM_CONV_UPDATE_UNSEEN PURPLE_CONV_UPDATE_UNSEEN
30.568 -#define GAIM_CONV_UPDATE_LOGGING PURPLE_CONV_UPDATE_LOGGING
30.569 -#define GAIM_CONV_UPDATE_TOPIC PURPLE_CONV_UPDATE_TOPIC
30.570 -#define GAIM_CONV_ACCOUNT_ONLINE PURPLE_CONV_ACCOUNT_ONLINE
30.571 -#define GAIM_CONV_ACCOUNT_OFFLINE PURPLE_CONV_ACCOUNT_OFFLINE
30.572 -#define GAIM_CONV_UPDATE_AWAY PURPLE_CONV_UPDATE_AWAY
30.573 -#define GAIM_CONV_UPDATE_ICON PURPLE_CONV_UPDATE_ICON
30.574 -#define GAIM_CONV_UPDATE_TITLE PURPLE_CONV_UPDATE_TITLE
30.575 -#define GAIM_CONV_UPDATE_CHATLEFT PURPLE_CONV_UPDATE_CHATLEFT
30.576 -#define GAIM_CONV_UPDATE_FEATURES PURPLE_CONV_UPDATE_FEATURES
30.577 -
30.578 -#define GaimConvUpdateType PurpleConvUpdateType
30.579 -
30.580 -#define GAIM_NOT_TYPING PURPLE_NOT_TYPING
30.581 -#define GAIM_TYPING PURPLE_TYPING
30.582 -#define GAIM_TYPED PURPLE_TYPED
30.583 -
30.584 -#define GaimTypingState PurpleTypingState
30.585 -
30.586 -#define GAIM_MESSAGE_SEND PURPLE_MESSAGE_SEND
30.587 -#define GAIM_MESSAGE_RECV PURPLE_MESSAGE_RECV
30.588 -#define GAIM_MESSAGE_SYSTEM PURPLE_MESSAGE_SYSTEM
30.589 -#define GAIM_MESSAGE_AUTO_RESP PURPLE_MESSAGE_AUTO_RESP
30.590 -#define GAIM_MESSAGE_ACTIVE_ONLY PURPLE_MESSAGE_ACTIVE_ONLY
30.591 -#define GAIM_MESSAGE_NICK PURPLE_MESSAGE_NICK
30.592 -#define GAIM_MESSAGE_NO_LOG PURPLE_MESSAGE_NO_LOG
30.593 -#define GAIM_MESSAGE_WHISPER PURPLE_MESSAGE_WHISPER
30.594 -#define GAIM_MESSAGE_ERROR PURPLE_MESSAGE_ERROR
30.595 -#define GAIM_MESSAGE_DELAYED PURPLE_MESSAGE_DELAYED
30.596 -#define GAIM_MESSAGE_RAW PURPLE_MESSAGE_RAW
30.597 -#define GAIM_MESSAGE_IMAGES PURPLE_MESSAGE_IMAGES
30.598 -
30.599 -#define GaimMessageFlags PurpleMessageFlags
30.600 -
30.601 -#define GAIM_CBFLAGS_NONE PURPLE_CBFLAGS_NONE
30.602 -#define GAIM_CBFLAGS_VOICE PURPLE_CBFLAGS_VOICE
30.603 -#define GAIM_CBFLAGS_HALFOP PURPLE_CBFLAGS_HALFOP
30.604 -#define GAIM_CBFLAGS_OP PURPLE_CBFLAGS_OP
30.605 -#define GAIM_CBFLAGS_FOUNDER PURPLE_CBFLAGS_FOUNDER
30.606 -#define GAIM_CBFLAGS_TYPING PURPLE_CBFLAGS_TYPING
30.607 -
30.608 -#define GaimConvChatBuddyFlags PurpleConvChatBuddyFlags
30.609 -
30.610 -#define gaim_conversations_set_ui_ops purple_conversations_set_ui_ops
30.611 -
30.612 -#define gaim_conversation_new purple_conversation_new
30.613 -#define gaim_conversation_destroy purple_conversation_destroy
30.614 -#define gaim_conversation_present purple_conversation_present
30.615 -#define gaim_conversation_get_type purple_conversation_get_type
30.616 -#define gaim_conversation_set_ui_ops purple_conversation_set_ui_ops
30.617 -#define gaim_conversation_get_ui_ops purple_conversation_get_ui_ops
30.618 -#define gaim_conversation_set_account purple_conversation_set_account
30.619 -#define gaim_conversation_get_account purple_conversation_get_account
30.620 -#define gaim_conversation_get_gc purple_conversation_get_gc
30.621 -#define gaim_conversation_set_title purple_conversation_set_title
30.622 -#define gaim_conversation_get_title purple_conversation_get_title
30.623 -#define gaim_conversation_autoset_title purple_conversation_autoset_title
30.624 -#define gaim_conversation_set_name purple_conversation_set_name
30.625 -#define gaim_conversation_get_name purple_conversation_get_name
30.626 -#define gaim_conversation_set_logging purple_conversation_set_logging
30.627 -#define gaim_conversation_is_logging purple_conversation_is_logging
30.628 -#define gaim_conversation_close_logs purple_conversation_close_logs
30.629 -#define gaim_conversation_get_im_data purple_conversation_get_im_data
30.630 -
30.631 -#define GAIM_CONV_IM PURPLE_CONV_IM
30.632 -
30.633 -#define gaim_conversation_get_chat_data purple_conversation_get_chat_data
30.634 -
30.635 -#define GAIM_CONV_CHAT PURPLE_CONV_CHAT
30.636 -
30.637 -#define gaim_conversation_set_data purple_conversation_set_data
30.638 -#define gaim_conversation_get_data purple_conversation_get_data
30.639 -
30.640 -#define gaim_get_conversations purple_get_conversations
30.641 -#define gaim_get_ims purple_get_ims
30.642 -#define gaim_get_chats purple_get_chats
30.643 -
30.644 -#define gaim_find_conversation_with_account \
30.645 - purple_find_conversation_with_account
30.646 -
30.647 -#define gaim_conversation_write purple_conversation_write
30.648 -#define gaim_conversation_set_features purple_conversation_set_features
30.649 -#define gaim_conversation_get_features purple_conversation_get_features
30.650 -#define gaim_conversation_has_focus purple_conversation_has_focus
30.651 -#define gaim_conversation_update purple_conversation_update
30.652 -#define gaim_conversation_foreach purple_conversation_foreach
30.653 -
30.654 -#define gaim_conv_im_get_conversation purple_conv_im_get_conversation
30.655 -#define gaim_conv_im_set_icon purple_conv_im_set_icon
30.656 -#define gaim_conv_im_get_icon purple_conv_im_get_icon
30.657 -#define gaim_conv_im_set_typing_state purple_conv_im_set_typing_state
30.658 -#define gaim_conv_im_get_typing_state purple_conv_im_get_typing_state
30.659 -
30.660 -#define gaim_conv_im_start_typing_timeout purple_conv_im_start_typing_timeout
30.661 -#define gaim_conv_im_stop_typing_timeout purple_conv_im_stop_typing_timeout
30.662 -#define gaim_conv_im_get_typing_timeout purple_conv_im_get_typing_timeout
30.663 -#define gaim_conv_im_set_type_again purple_conv_im_set_type_again
30.664 -#define gaim_conv_im_get_type_again purple_conv_im_get_type_again
30.665 -
30.666 -#define gaim_conv_im_start_send_typed_timeout \
30.667 - purple_conv_im_start_send_typed_timeout
30.668 -
30.669 -#define gaim_conv_im_stop_send_typed_timeout \
30.670 - purple_conv_im_stop_send_typed_timeout
30.671 -
30.672 -#define gaim_conv_im_get_send_typed_timeout \
30.673 - purple_conv_im_get_send_typed_timeout
30.674 -
30.675 -#define gaim_conv_present_error purple_conv_present_error
30.676 -#define gaim_conv_send_confirm purple_conv_send_confirm
30.677 -
30.678 -#define gaim_conv_im_update_typing purple_conv_im_update_typing
30.679 -#define gaim_conv_im_write purple_conv_im_write
30.680 -#define gaim_conv_im_send purple_conv_im_send
30.681 -#define gaim_conv_im_send_with_flags purple_conv_im_send_with_flags
30.682 -
30.683 -#define gaim_conv_custom_smiley_add purple_conv_custom_smiley_add
30.684 -#define gaim_conv_custom_smiley_write purple_conv_custom_smiley_write
30.685 -#define gaim_conv_custom_smiley_close purple_conv_custom_smiley_close
30.686 -
30.687 -#define gaim_conv_chat_get_conversation purple_conv_chat_get_conversation
30.688 -#define gaim_conv_chat_set_users purple_conv_chat_set_users
30.689 -#define gaim_conv_chat_get_users purple_conv_chat_get_users
30.690 -#define gaim_conv_chat_ignore purple_conv_chat_ignore
30.691 -#define gaim_conv_chat_unignore purple_conv_chat_unignore
30.692 -#define gaim_conv_chat_set_ignored purple_conv_chat_set_ignored
30.693 -#define gaim_conv_chat_get_ignored purple_conv_chat_get_ignored
30.694 -#define gaim_conv_chat_get_ignored_user purple_conv_chat_get_ignored_user
30.695 -#define gaim_conv_chat_is_user_ignored purple_conv_chat_is_user_ignored
30.696 -#define gaim_conv_chat_set_topic purple_conv_chat_set_topic
30.697 -#define gaim_conv_chat_get_topic purple_conv_chat_get_topic
30.698 -#define gaim_conv_chat_set_id purple_conv_chat_set_id
30.699 -#define gaim_conv_chat_get_id purple_conv_chat_get_id
30.700 -#define gaim_conv_chat_write purple_conv_chat_write
30.701 -#define gaim_conv_chat_send purple_conv_chat_send
30.702 -#define gaim_conv_chat_send_with_flags purple_conv_chat_send_with_flags
30.703 -#define gaim_conv_chat_add_user purple_conv_chat_add_user
30.704 -#define gaim_conv_chat_add_users purple_conv_chat_add_users
30.705 -#define gaim_conv_chat_rename_user purple_conv_chat_rename_user
30.706 -#define gaim_conv_chat_remove_user purple_conv_chat_remove_user
30.707 -#define gaim_conv_chat_remove_users purple_conv_chat_remove_users
30.708 -#define gaim_conv_chat_find_user purple_conv_chat_find_user
30.709 -#define gaim_conv_chat_user_set_flags purple_conv_chat_user_set_flags
30.710 -#define gaim_conv_chat_user_get_flags purple_conv_chat_user_get_flags
30.711 -#define gaim_conv_chat_clear_users purple_conv_chat_clear_users
30.712 -#define gaim_conv_chat_set_nick purple_conv_chat_set_nick
30.713 -#define gaim_conv_chat_get_nick purple_conv_chat_get_nick
30.714 -#define gaim_conv_chat_left purple_conv_chat_left
30.715 -#define gaim_conv_chat_has_left purple_conv_chat_has_left
30.716 -
30.717 -#define gaim_find_chat purple_find_chat
30.718 -
30.719 -#define gaim_conv_chat_cb_new purple_conv_chat_cb_new
30.720 -#define gaim_conv_chat_cb_find purple_conv_chat_cb_find
30.721 -#define gaim_conv_chat_cb_get_name purple_conv_chat_cb_get_name
30.722 -#define gaim_conv_chat_cb_destroy purple_conv_chat_cb_destroy
30.723 -
30.724 -#define gaim_conversations_get_handle purple_conversations_get_handle
30.725 -#define gaim_conversations_init purple_conversations_init
30.726 -#define gaim_conversations_uninit purple_conversations_uninit
30.727 -
30.728 -/* from core.h */
30.729 -
30.730 -#define GaimCore PurpleCore
30.731 -
30.732 -#define GaimCoreUiOps PurpleCoreUiOps
30.733 -
30.734 -#define gaim_core_init purple_core_init
30.735 -#define gaim_core_quit purple_core_quit
30.736 -
30.737 -#define gaim_core_quit_cb purple_core_quit_cb
30.738 -#define gaim_core_get_version purple_core_get_version
30.739 -#define gaim_core_get_ui purple_core_get_ui
30.740 -#define gaim_get_core purple_get_core
30.741 -#define gaim_core_set_ui_ops purple_core_set_ui_ops
30.742 -#define gaim_core_get_ui_ops purple_core_get_ui_ops
30.743 -
30.744 -/* from debug.h */
30.745 -
30.746 -#define GAIM_DEBUG_ALL PURPLE_DEBUG_ALL
30.747 -#define GAIM_DEBUG_MISC PURPLE_DEBUG_MISC
30.748 -#define GAIM_DEBUG_INFO PURPLE_DEBUG_INFO
30.749 -#define GAIM_DEBUG_WARNING PURPLE_DEBUG_WARNING
30.750 -#define GAIM_DEBUG_ERROR PURPLE_DEBUG_ERROR
30.751 -#define GAIM_DEBUG_FATAL PURPLE_DEBUG_FATAL
30.752 -
30.753 -#define GaimDebugLevel PurpleDebugLevel
30.754 -
30.755 -#define GaimDebugUiOps PurpleDebugUiOps
30.756 -
30.757 -
30.758 -#define gaim_debug purple_debug
30.759 -#define gaim_debug_misc purple_debug_misc
30.760 -#define gaim_debug_info purple_debug_info
30.761 -#define gaim_debug_warning purple_debug_warning
30.762 -#define gaim_debug_error purple_debug_error
30.763 -#define gaim_debug_fatal purple_debug_fatal
30.764 -
30.765 -#define gaim_debug_set_enabled purple_debug_set_enabled
30.766 -#define gaim_debug_is_enabled purple_debug_is_enabled
30.767 -
30.768 -#define gaim_debug_set_ui_ops purple_debug_set_ui_ops
30.769 -#define gaim_debug_get_ui_ops purple_debug_get_ui_ops
30.770 -
30.771 -#define gaim_debug_init purple_debug_init
30.772 -
30.773 -/* from desktopitem.h */
30.774 -
30.775 -#define GAIM_DESKTOP_ITEM_TYPE_NULL PURPLE_DESKTOP_ITEM_TYPE_NULL
30.776 -#define GAIM_DESKTOP_ITEM_TYPE_OTHER PURPLE_DESKTOP_ITEM_TYPE_OTHER
30.777 -#define GAIM_DESKTOP_ITEM_TYPE_APPLICATION PURPLE_DESKTOP_ITEM_TYPE_APPLICATION
30.778 -#define GAIM_DESKTOP_ITEM_TYPE_LINK PURPLE_DESKTOP_ITEM_TYPE_LINK
30.779 -#define GAIM_DESKTOP_ITEM_TYPE_FSDEVICE PURPLE_DESKTOP_ITEM_TYPE_FSDEVICE
30.780 -#define GAIM_DESKTOP_ITEM_TYPE_MIME_TYPE PURPLE_DESKTOP_ITEM_TYPE_MIME_TYPE
30.781 -#define GAIM_DESKTOP_ITEM_TYPE_DIRECTORY PURPLE_DESKTOP_ITEM_TYPE_DIRECTORY
30.782 -#define GAIM_DESKTOP_ITEM_TYPE_SERVICE PURPLE_DESKTOP_ITEM_TYPE_SERVICE
30.783 -#define GAIM_DESKTOP_ITEM_TYPE_SERVICE_TYPE PURPLE_DESKTOP_ITEM_TYPE_SERVICE_TYPE
30.784 -
30.785 -#define GaimDesktopItemType PurpleDesktopItemType
30.786 -
30.787 -#define GaimDesktopItem PurpleDesktopItem
30.788 -
30.789 -#define GAIM_TYPE_DESKTOP_ITEM PURPLE_TYPE_DESKTOP_ITEM
30.790 -#define gaim_desktop_item_get_type purple_desktop_item_get_type
30.791 -
30.792 -/* standard */
30.793 -/* ugh, i'm just copying these as strings, rather than pidginifying them */
30.794 -#define GAIM_DESKTOP_ITEM_ENCODING "Encoding" /* string */
30.795 -#define GAIM_DESKTOP_ITEM_VERSION "Version" /* numeric */
30.796 -#define GAIM_DESKTOP_ITEM_NAME "Name" /* localestring */
30.797 -#define GAIM_DESKTOP_ITEM_GENERIC_NAME "GenericName" /* localestring */
30.798 -#define GAIM_DESKTOP_ITEM_TYPE "Type" /* string */
30.799 -#define GAIM_DESKTOP_ITEM_FILE_PATTERN "FilePattern" /* regexp(s) */
30.800 -#define GAIM_DESKTOP_ITEM_TRY_EXEC "TryExec" /* string */
30.801 -#define GAIM_DESKTOP_ITEM_NO_DISPLAY "NoDisplay" /* boolean */
30.802 -#define GAIM_DESKTOP_ITEM_COMMENT "Comment" /* localestring */
30.803 -#define GAIM_DESKTOP_ITEM_EXEC "Exec" /* string */
30.804 -#define GAIM_DESKTOP_ITEM_ACTIONS "Actions" /* strings */
30.805 -#define GAIM_DESKTOP_ITEM_ICON "Icon" /* string */
30.806 -#define GAIM_DESKTOP_ITEM_MINI_ICON "MiniIcon" /* string */
30.807 -#define GAIM_DESKTOP_ITEM_HIDDEN "Hidden" /* boolean */
30.808 -#define GAIM_DESKTOP_ITEM_PATH "Path" /* string */
30.809 -#define GAIM_DESKTOP_ITEM_TERMINAL "Terminal" /* boolean */
30.810 -#define GAIM_DESKTOP_ITEM_TERMINAL_OPTIONS "TerminalOptions" /* string */
30.811 -#define GAIM_DESKTOP_ITEM_SWALLOW_TITLE "SwallowTitle" /* string */
30.812 -#define GAIM_DESKTOP_ITEM_SWALLOW_EXEC "SwallowExec" /* string */
30.813 -#define GAIM_DESKTOP_ITEM_MIME_TYPE "MimeType" /* regexp(s) */
30.814 -#define GAIM_DESKTOP_ITEM_PATTERNS "Patterns" /* regexp(s) */
30.815 -#define GAIM_DESKTOP_ITEM_DEFAULT_APP "DefaultApp" /* string */
30.816 -#define GAIM_DESKTOP_ITEM_DEV "Dev" /* string */
30.817 -#define GAIM_DESKTOP_ITEM_FS_TYPE "FSType" /* string */
30.818 -#define GAIM_DESKTOP_ITEM_MOUNT_POINT "MountPoint" /* string */
30.819 -#define GAIM_DESKTOP_ITEM_READ_ONLY "ReadOnly" /* boolean */
30.820 -#define GAIM_DESKTOP_ITEM_UNMOUNT_ICON "UnmountIcon" /* string */
30.821 -#define GAIM_DESKTOP_ITEM_SORT_ORDER "SortOrder" /* strings */
30.822 -#define GAIM_DESKTOP_ITEM_URL "URL" /* string */
30.823 -#define GAIM_DESKTOP_ITEM_DOC_PATH "X-GNOME-DocPath" /* string */
30.824 -
30.825 -#define gaim_desktop_item_new_from_file purple_desktop_item_new_from_file
30.826 -#define gaim_desktop_item_get_entry_type purple_desktop_item_get_entry_type
30.827 -#define gaim_desktop_item_get_string purple_desktop_item_get_string
30.828 -#define gaim_desktop_item_copy purple_desktop_item_copy
30.829 -#define gaim_desktop_item_unref purple_desktop_item_unref
30.830 -
30.831 -/* from dnsquery.h */
30.832 -
30.833 -#define GaimDnsQueryData PurpleDnsQueryData
30.834 -#define GaimDnsQueryConnectFunction PurpleDnsQueryConnectFunction
30.835 -
30.836 -#define gaim_dnsquery_a purple_dnsquery_a
30.837 -#define gaim_dnsquery_destroy purple_dnsquery_destroy
30.838 -#define gaim_dnsquery_init purple_dnsquery_init
30.839 -#define gaim_dnsquery_uninit purple_dnsquery_uninit
30.840 -#define gaim_dnsquery_set_ui_ops purple_dnsquery_set_ui_ops
30.841 -#define gaim_dnsquery_get_host purple_dnsquery_get_host
30.842 -#define gaim_dnsquery_get_port purple_dnsquery_get_port
30.843 -
30.844 -/* from dnssrv.h */
30.845 -
30.846 -#define GaimSrvResponse PurpleSrvResponse
30.847 -#define GaimSrvQueryData PurpleSrvQueryData
30.848 -#define GaimSrvCallback PurpleSrvCallback
30.849 -
30.850 -#define gaim_srv_resolve purple_srv_resolve
30.851 -#define gaim_srv_cancel purple_srv_cancel
30.852 -
30.853 -/* from eventloop.h */
30.854 -
30.855 -#define GAIM_INPUT_READ PURPLE_INPUT_READ
30.856 -#define GAIM_INPUT_WRITE PURPLE_INPUT_WRITE
30.857 -
30.858 -#define GaimInputCondition PurpleInputCondition
30.859 -#define GaimInputFunction PurpleInputFunction
30.860 -#define GaimEventLoopUiOps PurpleEventLoopUiOps
30.861 -
30.862 -#define gaim_timeout_add purple_timeout_add
30.863 -#define gaim_timeout_remove purple_timeout_remove
30.864 -#define gaim_input_add purple_input_add
30.865 -#define gaim_input_remove purple_input_remove
30.866 -
30.867 -#define gaim_eventloop_set_ui_ops purple_eventloop_set_ui_ops
30.868 -#define gaim_eventloop_get_ui_ops purple_eventloop_get_ui_ops
30.869 -
30.870 -/* from ft.h */
30.871 -
30.872 -#define GaimXfer PurpleXfer
30.873 -
30.874 -#define GAIM_XFER_UNKNOWN PURPLE_XFER_UNKNOWN
30.875 -#define GAIM_XFER_SEND PURPLE_XFER_SEND
30.876 -#define GAIM_XFER_RECEIVE PURPLE_XFER_RECEIVE
30.877 -
30.878 -#define GaimXferType PurpleXferType
30.879 -
30.880 -#define GAIM_XFER_STATUS_UNKNOWN PURPLE_XFER_STATUS_UNKNOWN
30.881 -#define GAIM_XFER_STATUS_NOT_STARTED PURPLE_XFER_STATUS_NOT_STARTED
30.882 -#define GAIM_XFER_STATUS_ACCEPTED PURPLE_XFER_STATUS_ACCEPTED
30.883 -#define GAIM_XFER_STATUS_STARTED PURPLE_XFER_STATUS_STARTED
30.884 -#define GAIM_XFER_STATUS_DONE PURPLE_XFER_STATUS_DONE
30.885 -#define GAIM_XFER_STATUS_CANCEL_LOCAL PURPLE_XFER_STATUS_CANCEL_LOCAL
30.886 -#define GAIM_XFER_STATUS_CANCEL_REMOTE PURPLE_XFER_STATUS_CANCEL_REMOTE
30.887 -
30.888 -#define GaimXferStatusType PurpleXferStatusType
30.889 -
30.890 -#define GaimXferUiOps PurpleXferUiOps
30.891 -
30.892 -#define gaim_xfer_new purple_xfer_new
30.893 -#define gaim_xfer_ref purple_xfer_ref
30.894 -#define gaim_xfer_unref purple_xfer_unref
30.895 -#define gaim_xfer_request purple_xfer_request
30.896 -#define gaim_xfer_request_accepted purple_xfer_request_accepted
30.897 -#define gaim_xfer_request_denied purple_xfer_request_denied
30.898 -#define gaim_xfer_get_type purple_xfer_get_type
30.899 -#define gaim_xfer_get_account purple_xfer_get_account
30.900 -#define gaim_xfer_get_status purple_xfer_get_status
30.901 -#define gaim_xfer_is_canceled purple_xfer_is_canceled
30.902 -#define gaim_xfer_is_completed purple_xfer_is_completed
30.903 -#define gaim_xfer_get_filename purple_xfer_get_filename
30.904 -#define gaim_xfer_get_local_filename purple_xfer_get_local_filename
30.905 -#define gaim_xfer_get_bytes_sent purple_xfer_get_bytes_sent
30.906 -#define gaim_xfer_get_bytes_remaining purple_xfer_get_bytes_remaining
30.907 -#define gaim_xfer_get_size purple_xfer_get_size
30.908 -#define gaim_xfer_get_progress purple_xfer_get_progress
30.909 -#define gaim_xfer_get_local_port purple_xfer_get_local_port
30.910 -#define gaim_xfer_get_remote_ip purple_xfer_get_remote_ip
30.911 -#define gaim_xfer_get_remote_port purple_xfer_get_remote_port
30.912 -#define gaim_xfer_set_completed purple_xfer_set_completed
30.913 -#define gaim_xfer_set_message purple_xfer_set_message
30.914 -#define gaim_xfer_set_filename purple_xfer_set_filename
30.915 -#define gaim_xfer_set_local_filename purple_xfer_set_local_filename
30.916 -#define gaim_xfer_set_size purple_xfer_set_size
30.917 -#define gaim_xfer_set_bytes_sent purple_xfer_set_bytes_sent
30.918 -#define gaim_xfer_get_ui_ops purple_xfer_get_ui_ops
30.919 -#define gaim_xfer_set_read_fnc purple_xfer_set_read_fnc
30.920 -#define gaim_xfer_set_write_fnc purple_xfer_set_write_fnc
30.921 -#define gaim_xfer_set_ack_fnc purple_xfer_set_ack_fnc
30.922 -#define gaim_xfer_set_request_denied_fnc purple_xfer_set_request_denied_fnc
30.923 -#define gaim_xfer_set_init_fnc purple_xfer_set_init_fnc
30.924 -#define gaim_xfer_set_start_fnc purple_xfer_set_start_fnc
30.925 -#define gaim_xfer_set_end_fnc purple_xfer_set_end_fnc
30.926 -#define gaim_xfer_set_cancel_send_fnc purple_xfer_set_cancel_send_fnc
30.927 -#define gaim_xfer_set_cancel_recv_fnc purple_xfer_set_cancel_recv_fnc
30.928 -
30.929 -#define gaim_xfer_read purple_xfer_read
30.930 -#define gaim_xfer_write purple_xfer_write
30.931 -#define gaim_xfer_start purple_xfer_start
30.932 -#define gaim_xfer_end purple_xfer_end
30.933 -#define gaim_xfer_add purple_xfer_add
30.934 -#define gaim_xfer_cancel_local purple_xfer_cancel_local
30.935 -#define gaim_xfer_cancel_remote purple_xfer_cancel_remote
30.936 -#define gaim_xfer_error purple_xfer_error
30.937 -#define gaim_xfer_update_progress purple_xfer_update_progress
30.938 -#define gaim_xfer_conversation_write purple_xfer_conversation_write
30.939 -
30.940 -#define gaim_xfers_get_handle purple_xfers_get_handle
30.941 -#define gaim_xfers_init purple_xfers_init
30.942 -#define gaim_xfers_uninit purple_xfers_uninit
30.943 -#define gaim_xfers_set_ui_ops purple_xfers_set_ui_ops
30.944 -#define gaim_xfers_get_ui_ops purple_xfers_get_ui_ops
30.945 -
30.946 -/* from gaim-client.h */
30.947 -
30.948 -#define gaim_init purple_init
30.949 -
30.950 -/* from idle.h */
30.951 -
30.952 -#define GaimIdleUiOps PurpleIdleUiOps
30.953 -
30.954 -#define gaim_idle_touch purple_idle_touch
30.955 -#define gaim_idle_set purple_idle_set
30.956 -#define gaim_idle_set_ui_ops purple_idle_set_ui_ops
30.957 -#define gaim_idle_get_ui_ops purple_idle_get_ui_ops
30.958 -#define gaim_idle_init purple_idle_init
30.959 -#define gaim_idle_uninit purple_idle_uninit
30.960 -
30.961 -/* from imgstore.h */
30.962 -
30.963 -#define GaimStoredImage PurpleStoredImage
30.964 -
30.965 -#define gaim_imgstore_add(data, size, filename) \
30.966 - purple_imgstore_add_with_id(g_memdup(data, size), size, filename)
30.967 -#define gaim_imgstore_get purple_imgstore_find_by_id
30.968 -#define gaim_imgstore_get_data purple_imgstore_get_data
30.969 -#define gaim_imgstore_get_size purple_imgstore_get_size
30.970 -#define gaim_imgstore_get_filename purple_imgstore_get_filename
30.971 -#define gaim_imgstore_ref purple_imgstore_ref_by_id
30.972 -#define gaim_imgstore_unref purple_imgstore_unref_by_id
30.973 -
30.974 -
30.975 -/* from log.h */
30.976 -
30.977 -#define GaimLog PurpleLog
30.978 -#define GaimLogLogger PurpleLogLogger
30.979 -#define GaimLogCommonLoggerData PurpleLogCommonLoggerData
30.980 -#define GaimLogSet PurpleLogSet
30.981 -
30.982 -#define GAIM_LOG_IM PURPLE_LOG_IM
30.983 -#define GAIM_LOG_CHAT PURPLE_LOG_CHAT
30.984 -#define GAIM_LOG_SYSTEM PURPLE_LOG_SYSTEM
30.985 -
30.986 -#define GaimLogType PurpleLogType
30.987 -
30.988 -#define GAIM_LOG_READ_NO_NEWLINE PURPLE_LOG_READ_NO_NEWLINE
30.989 -
30.990 -#define GaimLogReadFlags PurpleLogReadFlags
30.991 -
30.992 -#define GaimLogSetCallback PurpleLogSetCallback
30.993 -
30.994 -#define gaim_log_new purple_log_new
30.995 -#define gaim_log_free purple_log_free
30.996 -#define gaim_log_write purple_log_write
30.997 -#define gaim_log_read purple_log_read
30.998 -
30.999 -#define gaim_log_get_logs purple_log_get_logs
30.1000 -#define gaim_log_get_log_sets purple_log_get_log_sets
30.1001 -#define gaim_log_get_system_logs purple_log_get_system_logs
30.1002 -#define gaim_log_get_size purple_log_get_size
30.1003 -#define gaim_log_get_total_size purple_log_get_total_size
30.1004 -#define gaim_log_get_log_dir purple_log_get_log_dir
30.1005 -#define gaim_log_compare purple_log_compare
30.1006 -#define gaim_log_set_compare purple_log_set_compare
30.1007 -#define gaim_log_set_free purple_log_set_free
30.1008 -
30.1009 -#define gaim_log_common_writer purple_log_common_writer
30.1010 -#define gaim_log_common_lister purple_log_common_lister
30.1011 -#define gaim_log_common_total_sizer purple_log_common_total_sizer
30.1012 -#define gaim_log_common_sizer purple_log_common_sizer
30.1013 -
30.1014 -#define gaim_log_logger_new purple_log_logger_new
30.1015 -#define gaim_log_logger_free purple_log_logger_free
30.1016 -#define gaim_log_logger_add purple_log_logger_add
30.1017 -#define gaim_log_logger_remove purple_log_logger_remove
30.1018 -#define gaim_log_logger_set purple_log_logger_set
30.1019 -#define gaim_log_logger_get purple_log_logger_get
30.1020 -
30.1021 -#define gaim_log_logger_get_options purple_log_logger_get_options
30.1022 -
30.1023 -#define gaim_log_init purple_log_init
30.1024 -#define gaim_log_get_handle purple_log_get_handle
30.1025 -#define gaim_log_uninit purple_log_uninit
30.1026 -
30.1027 -/* from mime.h */
30.1028 -
30.1029 -#define GaimMimeDocument PurpleMimeDocument
30.1030 -#define GaimMimePart PurpleMimePart
30.1031 -
30.1032 -#define gaim_mime_document_new purple_mime_document_new
30.1033 -#define gaim_mime_document_free purple_mime_document_free
30.1034 -#define gaim_mime_document_parse purple_mime_document_parse
30.1035 -#define gaim_mime_document_parsen purple_mime_document_parsen
30.1036 -#define gaim_mime_document_write purple_mime_document_write
30.1037 -#define gaim_mime_document_get_fields purple_mime_document_get_fields
30.1038 -#define gaim_mime_document_get_field purple_mime_document_get_field
30.1039 -#define gaim_mime_document_set_field purple_mime_document_set_field
30.1040 -#define gaim_mime_document_get_parts purple_mime_document_get_parts
30.1041 -
30.1042 -#define gaim_mime_part_new purple_mime_part_new
30.1043 -#define gaim_mime_part_get_fields purple_mime_part_get_fields
30.1044 -#define gaim_mime_part_get_field purple_mime_part_get_field
30.1045 -#define gaim_mime_part_get_field_decoded purple_mime_part_get_field_decoded
30.1046 -#define gaim_mime_part_set_field purple_mime_part_set_field
30.1047 -#define gaim_mime_part_get_data purple_mime_part_get_data
30.1048 -#define gaim_mime_part_get_data_decoded purple_mime_part_get_data_decoded
30.1049 -#define gaim_mime_part_get_length purple_mime_part_get_length
30.1050 -#define gaim_mime_part_set_data purple_mime_part_set_data
30.1051 -
30.1052 -
30.1053 -/* from network.h */
30.1054 -
30.1055 -#define GaimNetworkListenData PurpleNetworkListenData
30.1056 -
30.1057 -#define GaimNetworkListenCallback PurpleNetworkListenCallback
30.1058 -
30.1059 -#define gaim_network_ip_atoi purple_network_ip_atoi
30.1060 -#define gaim_network_set_public_ip purple_network_set_public_ip
30.1061 -#define gaim_network_get_public_ip purple_network_get_public_ip
30.1062 -#define gaim_network_get_local_system_ip purple_network_get_local_system_ip
30.1063 -#define gaim_network_get_my_ip purple_network_get_my_ip
30.1064 -
30.1065 -#define gaim_network_listen purple_network_listen
30.1066 -#define gaim_network_listen_range purple_network_listen_range
30.1067 -#define gaim_network_listen_cancel purple_network_listen_cancel
30.1068 -#define gaim_network_get_port_from_fd purple_network_get_port_from_fd
30.1069 -
30.1070 -#define gaim_network_is_available purple_network_is_available
30.1071 -
30.1072 -#define gaim_network_init purple_network_init
30.1073 -#define gaim_network_uninit purple_network_uninit
30.1074 -
30.1075 -/* from notify.h */
30.1076 -
30.1077 -
30.1078 -#define GaimNotifyUserInfoEntry PurpleNotifyUserInfoEntry
30.1079 -#define GaimNotifyUserInfo PurpleNotifyUserInfo
30.1080 -
30.1081 -#define GaimNotifyCloseCallback PurpleNotifyCloseCallback
30.1082 -
30.1083 -#define GAIM_NOTIFY_MESSAGE PURPLE_NOTIFY_MESSAGE
30.1084 -#define GAIM_NOTIFY_EMAIL PURPLE_NOTIFY_EMAIL
30.1085 -#define GAIM_NOTIFY_EMAILS PURPLE_NOTIFY_EMAILS
30.1086 -#define GAIM_NOTIFY_FORMATTED PURPLE_NOTIFY_FORMATTED
30.1087 -#define GAIM_NOTIFY_SEARCHRESULTS PURPLE_NOTIFY_SEARCHRESULTS
30.1088 -#define GAIM_NOTIFY_USERINFO PURPLE_NOTIFY_USERINFO
30.1089 -#define GAIM_NOTIFY_URI PURPLE_NOTIFY_URI
30.1090 -
30.1091 -#define GaimNotifyType PurpleNotifyType
30.1092 -
30.1093 -#define GAIM_NOTIFY_MSG_ERROR PURPLE_NOTIFY_MSG_ERROR
30.1094 -#define GAIM_NOTIFY_MSG_WARNING PURPLE_NOTIFY_MSG_WARNING
30.1095 -#define GAIM_NOTIFY_MSG_INFO PURPLE_NOTIFY_MSG_INFO
30.1096 -
30.1097 -#define GaimNotifyMsgType PurpleNotifyMsgType
30.1098 -
30.1099 -#define GAIM_NOTIFY_BUTTON_LABELED PURPLE_NOTIFY_BUTTON_LABELED
30.1100 -#define GAIM_NOTIFY_BUTTON_CONTINUE PURPLE_NOTIFY_BUTTON_CONTINUE
30.1101 -#define GAIM_NOTIFY_BUTTON_ADD PURPLE_NOTIFY_BUTTON_ADD
30.1102 -#define GAIM_NOTIFY_BUTTON_INFO PURPLE_NOTIFY_BUTTON_INFO
30.1103 -#define GAIM_NOTIFY_BUTTON_IM PURPLE_NOTIFY_BUTTON_IM
30.1104 -#define GAIM_NOTIFY_BUTTON_JOIN PURPLE_NOTIFY_BUTTON_JOIN
30.1105 -#define GAIM_NOTIFY_BUTTON_INVITE PURPLE_NOTIFY_BUTTON_INVITE
30.1106 -
30.1107 -#define GaimNotifySearchButtonType PurpleNotifySearchButtonType
30.1108 -
30.1109 -#define GaimNotifySearchResults PurpleNotifySearchResults
30.1110 -
30.1111 -#define GAIM_NOTIFY_USER_INFO_ENTRY_PAIR PURPLE_NOTIFY_USER_INFO_ENTRY_PAIR
30.1112 -#define GAIM_NOTIFY_USER_INFO_ENTRY_SECTION_BREAK PURPLE_NOTIFY_USER_INFO_ENTRY_SECTION_BREAK
30.1113 -#define GAIM_NOTIFY_USER_INFO_ENTRY_SECTION_HEADER PURPLE_NOTIFY_USER_INFO_ENTRY_SECTION_HEADER
30.1114 -
30.1115 -#define GaimNotifyUserInfoEntryType PurpleNotifyUserInfoEntryType
30.1116 -
30.1117 -#define GaimNotifySearchColumn PurpleNotifySearchColumn
30.1118 -#define GaimNotifySearchResultsCallback PurpleNotifySearchResultsCallback
30.1119 -#define GaimNotifySearchButton PurpleNotifySearchButton
30.1120 -
30.1121 -#define GaimNotifyUiOps PurpleNotifyUiOps
30.1122 -
30.1123 -#define gaim_notify_searchresults purple_notify_searchresults
30.1124 -#define gaim_notify_searchresults_free purple_notify_searchresults_free
30.1125 -#define gaim_notify_searchresults_new_rows purple_notify_searchresults_new_rows
30.1126 -#define gaim_notify_searchresults_button_add purple_notify_searchresults_button_add
30.1127 -#define gaim_notify_searchresults_button_add_labeled purple_notify_searchresults_button_add_labeled
30.1128 -#define gaim_notify_searchresults_new purple_notify_searchresults_new
30.1129 -#define gaim_notify_searchresults_column_new purple_notify_searchresults_column_new
30.1130 -#define gaim_notify_searchresults_column_add purple_notify_searchresults_column_add
30.1131 -#define gaim_notify_searchresults_row_add purple_notify_searchresults_row_add
30.1132 -#define gaim_notify_searchresults_get_rows_count purple_notify_searchresults_get_rows_count
30.1133 -#define gaim_notify_searchresults_get_columns_count purple_notify_searchresults_get_columns_count
30.1134 -#define gaim_notify_searchresults_row_get purple_notify_searchresults_row_get
30.1135 -#define gaim_notify_searchresults_column_get_title purple_notify_searchresults_column_get_title
30.1136 -
30.1137 -#define gaim_notify_message purple_notify_message
30.1138 -#define gaim_notify_email purple_notify_email
30.1139 -#define gaim_notify_emails purple_notify_emails
30.1140 -#define gaim_notify_formatted purple_notify_formatted
30.1141 -#define gaim_notify_userinfo purple_notify_userinfo
30.1142 -
30.1143 -#define gaim_notify_user_info_new purple_notify_user_info_new
30.1144 -#define gaim_notify_user_info_destroy purple_notify_user_info_destroy
30.1145 -#define gaim_notify_user_info_get_entries purple_notify_user_info_get_entries
30.1146 -#define gaim_notify_user_info_get_text_with_newline purple_notify_user_info_get_text_with_newline
30.1147 -#define gaim_notify_user_info_add_pair purple_notify_user_info_add_pair
30.1148 -#define gaim_notify_user_info_prepend_pair purple_notify_user_info_prepend_pair
30.1149 -#define gaim_notify_user_info_remove_entry purple_notify_user_info_remove_entry
30.1150 -#define gaim_notify_user_info_entry_new purple_notify_user_info_entry_new
30.1151 -#define gaim_notify_user_info_add_section_break purple_notify_user_info_add_section_break
30.1152 -#define gaim_notify_user_info_add_section_header purple_notify_user_info_add_section_header
30.1153 -#define gaim_notify_user_info_remove_last_item purple_notify_user_info_remove_last_item
30.1154 -#define gaim_notify_user_info_entry_get_label purple_notify_user_info_entry_get_label
30.1155 -#define gaim_notify_user_info_entry_set_label purple_notify_user_info_entry_set_label
30.1156 -#define gaim_notify_user_info_entry_get_value purple_notify_user_info_entry_get_value
30.1157 -#define gaim_notify_user_info_entry_set_value purple_notify_user_info_entry_set_value
30.1158 -#define gaim_notify_user_info_entry_get_type purple_notify_user_info_entry_get_type
30.1159 -#define gaim_notify_user_info_entry_set_type purple_notify_user_info_entry_set_type
30.1160 -
30.1161 -#define gaim_notify_uri purple_notify_uri
30.1162 -#define gaim_notify_close purple_notify_close
30.1163 -#define gaim_notify_close_with_handle purple_notify_close_with_handle
30.1164 -
30.1165 -#define gaim_notify_info purple_notify_info
30.1166 -#define gaim_notify_warning purple_notify_warning
30.1167 -#define gaim_notify_error purple_notify_error
30.1168 -
30.1169 -#define gaim_notify_set_ui_ops purple_notify_set_ui_ops
30.1170 -#define gaim_notify_get_ui_ops purple_notify_get_ui_ops
30.1171 -
30.1172 -#define gaim_notify_get_handle purple_notify_get_handle
30.1173 -
30.1174 -#define gaim_notify_init purple_notify_init
30.1175 -#define gaim_notify_uninit purple_notify_uninit
30.1176 -
30.1177 -/* from ntlm.h */
30.1178 -
30.1179 -#define gaim_ntlm_gen_type1 purple_ntlm_gen_type1
30.1180 -#define gaim_ntlm_parse_type2 purple_ntlm_parse_type2
30.1181 -#define gaim_ntlm_gen_type3 purple_ntlm_gen_type3
30.1182 -
30.1183 -/* from plugin.h */
30.1184 -
30.1185 -#ifdef GAIM_PLUGINS
30.1186 -#ifndef PURPLE_PLUGINS
30.1187 -#define PURPLE_PLUGINS
30.1188 -#endif
30.1189 -#endif
30.1190 -
30.1191 -#define GaimPlugin PurplePlugin
30.1192 -#define GaimPluginInfo PurplePluginInfo
30.1193 -#define GaimPluginUiInfo PurplePluginUiInfo
30.1194 -#define GaimPluginLoaderInfo PurplePluginLoaderInfo
30.1195 -#define GaimPluginAction PurplePluginAction
30.1196 -#define GaimPluginPriority PurplePluginPriority
30.1197 -
30.1198 -#define GAIM_PLUGIN_UNKNOWN PURPLE_PLUGIN_UNKNOWN
30.1199 -#define GAIM_PLUGIN_STANDARD PURPLE_PLUGIN_STANDARD
30.1200 -#define GAIM_PLUGIN_LOADER PURPLE_PLUGIN_LOADER
30.1201 -#define GAIM_PLUGIN_PROTOCOL PURPLE_PLUGIN_PROTOCOL
30.1202 -
30.1203 -#define GaimPluginType PurplePluginType
30.1204 -
30.1205 -#define GAIM_PRIORITY_DEFAULT PURPLE_PRIORITY_DEFAULT
30.1206 -#define GAIM_PRIORITY_HIGHEST PURPLE_PRIORITY_HIGHEST
30.1207 -#define GAIM_PRIORITY_LOWEST PURPLE_PRIORITY_LOWEST
30.1208 -
30.1209 -#define GAIM_PLUGIN_FLAG_INVISIBLE PURPLE_PLUGIN_FLAG_INVISIBLE
30.1210 -
30.1211 -#define GAIM_PLUGIN_MAGIC PURPLE_PLUGIN_MAGIC
30.1212 -
30.1213 -#define GAIM_PLUGIN_LOADER_INFO PURPLE_PLUGIN_LOADER_INFO
30.1214 -#define GAIM_PLUGIN_HAS_PREF_FRAME PURPLE_PLUGIN_HAS_PREF_FRAME
30.1215 -#define GAIM_PLUGIN_UI_INFO PURPLE_PLUGIN_UI_INFO
30.1216 -
30.1217 -#define GAIM_PLUGIN_HAS_ACTIONS PURPLE_PLUGIN_HAS_ACTIONS
30.1218 -#define GAIM_PLUGIN_ACTIONS PURPLE_PLUGIN_ACTIONS
30.1219 -
30.1220 -#define GAIM_INIT_PLUGIN PURPLE_INIT_PLUGIN
30.1221 -
30.1222 -#define gaim_plugin_new purple_plugin_new
30.1223 -#define gaim_plugin_probe purple_plugin_probe
30.1224 -#define gaim_plugin_register purple_plugin_register
30.1225 -#define gaim_plugin_load purple_plugin_load
30.1226 -#define gaim_plugin_unload purple_plugin_unload
30.1227 -#define gaim_plugin_reload purple_plugin_reload
30.1228 -#define gaim_plugin_destroy purple_plugin_destroy
30.1229 -#define gaim_plugin_is_loaded purple_plugin_is_loaded
30.1230 -#define gaim_plugin_is_unloadable purple_plugin_is_unloadable
30.1231 -#define gaim_plugin_get_id purple_plugin_get_id
30.1232 -#define gaim_plugin_get_name purple_plugin_get_name
30.1233 -#define gaim_plugin_get_version purple_plugin_get_version
30.1234 -#define gaim_plugin_get_summary purple_plugin_get_summary
30.1235 -#define gaim_plugin_get_description purple_plugin_get_description
30.1236 -#define gaim_plugin_get_author purple_plugin_get_author
30.1237 -#define gaim_plugin_get_homepage purple_plugin_get_homepage
30.1238 -
30.1239 -#define gaim_plugin_ipc_register purple_plugin_ipc_register
30.1240 -#define gaim_plugin_ipc_unregister purple_plugin_ipc_unregister
30.1241 -#define gaim_plugin_ipc_unregister_all purple_plugin_ipc_unregister_all
30.1242 -#define gaim_plugin_ipc_get_params purple_plugin_ipc_get_params
30.1243 -#define gaim_plugin_ipc_call purple_plugin_ipc_call
30.1244 -
30.1245 -#define gaim_plugins_add_search_path purple_plugins_add_search_path
30.1246 -#define gaim_plugins_unload_all purple_plugins_unload_all
30.1247 -#define gaim_plugins_destroy_all purple_plugins_destroy_all
30.1248 -#define gaim_plugins_save_loaded purple_plugins_save_loaded
30.1249 -#define gaim_plugins_load_saved purple_plugins_load_saved
30.1250 -#define gaim_plugins_probe purple_plugins_probe
30.1251 -#define gaim_plugins_enabled purple_plugins_enabled
30.1252 -
30.1253 -#define gaim_plugins_register_probe_notify_cb purple_plugins_register_probe_notify_cb
30.1254 -#define gaim_plugins_unregister_probe_notify_cb purple_plugins_unregister_probe_notify_cb
30.1255 -#define gaim_plugins_register_load_notify_cb purple_plugins_register_load_notify_cb
30.1256 -#define gaim_plugins_unregister_load_notify_cb purple_plugins_unregister_load_notify_cb
30.1257 -#define gaim_plugins_register_unload_notify_cb purple_plugins_register_unload_notify_cb
30.1258 -#define gaim_plugins_unregister_unload_notify_cb purple_plugins_unregister_unload_notify_cb
30.1259 -
30.1260 -#define gaim_plugins_find_with_name purple_plugins_find_with_name
30.1261 -#define gaim_plugins_find_with_filename purple_plugins_find_with_filename
30.1262 -#define gaim_plugins_find_with_basename purple_plugins_find_with_basename
30.1263 -#define gaim_plugins_find_with_id purple_plugins_find_with_id
30.1264 -
30.1265 -#define gaim_plugins_get_loaded purple_plugins_get_loaded
30.1266 -#define gaim_plugins_get_protocols purple_plugins_get_protocols
30.1267 -#define gaim_plugins_get_all purple_plugins_get_all
30.1268 -
30.1269 -#define gaim_plugins_get_handle purple_plugins_get_handle
30.1270 -#define gaim_plugins_init purple_plugins_init
30.1271 -#define gaim_plugins_uninit purple_plugins_uninit
30.1272 -
30.1273 -#define gaim_plugin_action_new purple_plugin_action_new
30.1274 -#define gaim_plugin_action_free purple_plugin_action_free
30.1275 -
30.1276 -/* pluginpref.h */
30.1277 -
30.1278 -#define GaimPluginPrefFrame PurplePluginPrefFrame
30.1279 -#define GaimPluginPref PurplePluginPref
30.1280 -
30.1281 -#define GAIM_STRING_FORMAT_TYPE_NONE PURPLE_STRING_FORMAT_TYPE_NONE
30.1282 -#define GAIM_STRING_FORMAT_TYPE_MULTILINE PURPLE_STRING_FORMAT_TYPE_MULTILINE
30.1283 -#define GAIM_STRING_FORMAT_TYPE_HTML PURPLE_STRING_FORMAT_TYPE_HTML
30.1284 -
30.1285 -#define GaimStringFormatType PurpleStringFormatType
30.1286 -
30.1287 -#define GAIM_PLUGIN_PREF_NONE PURPLE_PLUGIN_PREF_NONE
30.1288 -#define GAIM_PLUGIN_PREF_CHOICE PURPLE_PLUGIN_PREF_CHOICE
30.1289 -#define GAIM_PLUGIN_PREF_INFO PURPLE_PLUGIN_PREF_INFO
30.1290 -#define GAIM_PLUGIN_PREF_STRING_FORMAT PURPLE_PLUGIN_PREF_STRING_FORMAT
30.1291 -
30.1292 -#define GaimPluginPrefType PurplePluginPrefType
30.1293 -
30.1294 -#define gaim_plugin_pref_frame_new purple_plugin_pref_frame_new
30.1295 -#define gaim_plugin_pref_frame_destroy purple_plugin_pref_frame_destroy
30.1296 -#define gaim_plugin_pref_frame_add purple_plugin_pref_frame_add
30.1297 -#define gaim_plugin_pref_frame_get_prefs purple_plugin_pref_frame_get_prefs
30.1298 -
30.1299 -#define gaim_plugin_pref_new purple_plugin_pref_new
30.1300 -#define gaim_plugin_pref_new_with_name purple_plugin_pref_new_with_name
30.1301 -#define gaim_plugin_pref_new_with_label purple_plugin_pref_new_with_label
30.1302 -#define gaim_plugin_pref_new_with_name_and_label purple_plugin_pref_new_with_name_and_label
30.1303 -#define gaim_plugin_pref_destroy purple_plugin_pref_destroy
30.1304 -#define gaim_plugin_pref_set_name purple_plugin_pref_set_name
30.1305 -#define gaim_plugin_pref_get_name purple_plugin_pref_get_name
30.1306 -#define gaim_plugin_pref_set_label purple_plugin_pref_set_label
30.1307 -#define gaim_plugin_pref_get_label purple_plugin_pref_get_label
30.1308 -#define gaim_plugin_pref_set_bounds purple_plugin_pref_set_bounds
30.1309 -#define gaim_plugin_pref_get_bounds purple_plugin_pref_get_bounds
30.1310 -#define gaim_plugin_pref_set_type purple_plugin_pref_set_type
30.1311 -#define gaim_plugin_pref_get_type purple_plugin_pref_get_type
30.1312 -#define gaim_plugin_pref_add_choice purple_plugin_pref_add_choice
30.1313 -#define gaim_plugin_pref_get_choices purple_plugin_pref_get_choices
30.1314 -#define gaim_plugin_pref_set_max_length purple_plugin_pref_set_max_length
30.1315 -#define gaim_plugin_pref_get_max_length purple_plugin_pref_get_max_length
30.1316 -#define gaim_plugin_pref_set_masked purple_plugin_pref_set_masked
30.1317 -#define gaim_plugin_pref_get_masked purple_plugin_pref_get_masked
30.1318 -#define gaim_plugin_pref_set_format_type purple_plugin_pref_set_format_type
30.1319 -#define gaim_plugin_pref_get_format_type purple_plugin_pref_get_format_type
30.1320 -
30.1321 -/* from pounce.h */
30.1322 -
30.1323 -#define GaimPounce PurplePounce
30.1324 -
30.1325 -#define GAIM_POUNCE_NONE PURPLE_POUNCE_NONE
30.1326 -#define GAIM_POUNCE_SIGNON PURPLE_POUNCE_SIGNON
30.1327 -#define GAIM_POUNCE_SIGNOFF PURPLE_POUNCE_SIGNOFF
30.1328 -#define GAIM_POUNCE_AWAY PURPLE_POUNCE_AWAY
30.1329 -#define GAIM_POUNCE_AWAY_RETURN PURPLE_POUNCE_AWAY_RETURN
30.1330 -#define GAIM_POUNCE_IDLE PURPLE_POUNCE_IDLE
30.1331 -#define GAIM_POUNCE_IDLE_RETURN PURPLE_POUNCE_IDLE_RETURN
30.1332 -#define GAIM_POUNCE_TYPING PURPLE_POUNCE_TYPING
30.1333 -#define GAIM_POUNCE_TYPED PURPLE_POUNCE_TYPED
30.1334 -#define GAIM_POUNCE_TYPING_STOPPED PURPLE_POUNCE_TYPING_STOPPED
30.1335 -#define GAIM_POUNCE_MESSAGE_RECEIVED PURPLE_POUNCE_MESSAGE_RECEIVED
30.1336 -#define GaimPounceEvent PurplePounceEvent
30.1337 -
30.1338 -#define GAIM_POUNCE_OPTION_NONE PURPLE_POUNCE_OPTION_NONE
30.1339 -#define GAIM_POUNCE_OPTION_AWAY PURPLE_POUNCE_OPTION_AWAY
30.1340 -#define GaimPounceOption PurplePounceOption
30.1341 -
30.1342 -#define GaimPounceCb PurplePounceCb
30.1343 -
30.1344 -#define gaim_pounce_new purple_pounce_new
30.1345 -#define gaim_pounce_destroy purple_pounce_destroy
30.1346 -#define gaim_pounce_destroy_all_by_account purple_pounce_destroy_all_by_account
30.1347 -#define gaim_pounce_set_events purple_pounce_set_events
30.1348 -#define gaim_pounce_set_options purple_pounce_set_options
30.1349 -#define gaim_pounce_set_pouncer purple_pounce_set_pouncer
30.1350 -#define gaim_pounce_set_pouncee purple_pounce_set_pouncee
30.1351 -#define gaim_pounce_set_save purple_pounce_set_save
30.1352 -#define gaim_pounce_action_register purple_pounce_action_register
30.1353 -#define gaim_pounce_action_set_enabled purple_pounce_action_set_enabled
30.1354 -#define gaim_pounce_action_set_attribute purple_pounce_action_set_attribute
30.1355 -#define gaim_pounce_set_data purple_pounce_set_data
30.1356 -#define gaim_pounce_get_events purple_pounce_get_events
30.1357 -#define gaim_pounce_get_options purple_pounce_get_options
30.1358 -#define gaim_pounce_get_pouncer purple_pounce_get_pouncer
30.1359 -#define gaim_pounce_get_pouncee purple_pounce_get_pouncee
30.1360 -#define gaim_pounce_get_save purple_pounce_get_save
30.1361 -#define gaim_pounce_action_is_enabled purple_pounce_action_is_enabled
30.1362 -#define gaim_pounce_action_get_attribute purple_pounce_action_get_attribute
30.1363 -#define gaim_pounce_get_data purple_pounce_get_data
30.1364 -#define gaim_pounce_execute purple_pounce_execute
30.1365 -
30.1366 -#define gaim_find_pounce purple_find_pounce
30.1367 -#define gaim_pounces_load purple_pounces_load
30.1368 -#define gaim_pounces_register_handler purple_pounces_register_handler
30.1369 -#define gaim_pounces_unregister_handler purple_pounces_unregister_handler
30.1370 -#define gaim_pounces_get_all purple_pounces_get_all
30.1371 -#define gaim_pounces_get_handle purple_pounces_get_handle
30.1372 -#define gaim_pounces_init purple_pounces_init
30.1373 -#define gaim_pounces_uninit purple_pounces_uninit
30.1374 -
30.1375 -/* from prefs.h */
30.1376 -
30.1377 -
30.1378 -#define GAIM_PREF_NONE PURPLE_PREF_NONE
30.1379 -#define GAIM_PREF_BOOLEAN PURPLE_PREF_BOOLEAN
30.1380 -#define GAIM_PREF_INT PURPLE_PREF_INT
30.1381 -#define GAIM_PREF_STRING PURPLE_PREF_STRING
30.1382 -#define GAIM_PREF_STRING_LIST PURPLE_PREF_STRING_LIST
30.1383 -#define GAIM_PREF_PATH PURPLE_PREF_PATH
30.1384 -#define GAIM_PREF_PATH_LIST PURPLE_PREF_PATH_LIST
30.1385 -#define GaimPrefType PurplePrefType
30.1386 -
30.1387 -#define GaimPrefCallback PurplePrefCallback
30.1388 -
30.1389 -#define gaim_prefs_get_handle purple_prefs_get_handle
30.1390 -#define gaim_prefs_init purple_prefs_init
30.1391 -#define gaim_prefs_uninit purple_prefs_uninit
30.1392 -#define gaim_prefs_add_none purple_prefs_add_none
30.1393 -#define gaim_prefs_add_bool purple_prefs_add_bool
30.1394 -#define gaim_prefs_add_int purple_prefs_add_int
30.1395 -#define gaim_prefs_add_string purple_prefs_add_string
30.1396 -#define gaim_prefs_add_string_list purple_prefs_add_string_list
30.1397 -#define gaim_prefs_add_path purple_prefs_add_path
30.1398 -#define gaim_prefs_add_path_list purple_prefs_add_path_list
30.1399 -#define gaim_prefs_remove purple_prefs_remove
30.1400 -#define gaim_prefs_rename purple_prefs_rename
30.1401 -#define gaim_prefs_rename_boolean_toggle purple_prefs_rename_boolean_toggle
30.1402 -#define gaim_prefs_destroy purple_prefs_destroy
30.1403 -#define gaim_prefs_set_generic purple_prefs_set_generic
30.1404 -#define gaim_prefs_set_bool purple_prefs_set_bool
30.1405 -#define gaim_prefs_set_int purple_prefs_set_int
30.1406 -#define gaim_prefs_set_string purple_prefs_set_string
30.1407 -#define gaim_prefs_set_string_list purple_prefs_set_string_list
30.1408 -#define gaim_prefs_set_path purple_prefs_set_path
30.1409 -#define gaim_prefs_set_path_list purple_prefs_set_path_list
30.1410 -#define gaim_prefs_exists purple_prefs_exists
30.1411 -#define gaim_prefs_get_type purple_prefs_get_type
30.1412 -#define gaim_prefs_get_bool purple_prefs_get_bool
30.1413 -#define gaim_prefs_get_int purple_prefs_get_int
30.1414 -#define gaim_prefs_get_string purple_prefs_get_string
30.1415 -#define gaim_prefs_get_string_list purple_prefs_get_string_list
30.1416 -#define gaim_prefs_get_path purple_prefs_get_path
30.1417 -#define gaim_prefs_get_path_list purple_prefs_get_path_list
30.1418 -#define gaim_prefs_connect_callback purple_prefs_connect_callback
30.1419 -#define gaim_prefs_disconnect_callback purple_prefs_disconnect_callback
30.1420 -#define gaim_prefs_disconnect_by_handle purple_prefs_disconnect_by_handle
30.1421 -#define gaim_prefs_trigger_callback purple_prefs_trigger_callback
30.1422 -#define gaim_prefs_load purple_prefs_load
30.1423 -#define gaim_prefs_update_old purple_prefs_update_old
30.1424 -
30.1425 -/* from privacy.h */
30.1426 -
30.1427 -#define GAIM_PRIVACY_ALLOW_ALL PURPLE_PRIVACY_ALLOW_ALL
30.1428 -#define GAIM_PRIVACY_DENY_ALL PURPLE_PRIVACY_DENY_ALL
30.1429 -#define GAIM_PRIVACY_ALLOW_USERS PURPLE_PRIVACY_ALLOW_USERS
30.1430 -#define GAIM_PRIVACY_DENY_USERS PURPLE_PRIVACY_DENY_USERS
30.1431 -#define GAIM_PRIVACY_ALLOW_BUDDYLIST PURPLE_PRIVACY_ALLOW_BUDDYLIST
30.1432 -#define GaimPrivacyType PurplePrivacyType
30.1433 -
30.1434 -#define GaimPrivacyUiOps PurplePrivacyUiOps
30.1435 -
30.1436 -#define gaim_privacy_permit_add purple_privacy_permit_add
30.1437 -#define gaim_privacy_permit_remove purple_privacy_permit_remove
30.1438 -#define gaim_privacy_deny_add purple_privacy_deny_add
30.1439 -#define gaim_privacy_deny_remove purple_privacy_deny_remove
30.1440 -#define gaim_privacy_allow purple_privacy_allow
30.1441 -#define gaim_privacy_deny purple_privacy_deny
30.1442 -#define gaim_privacy_check purple_privacy_check
30.1443 -#define gaim_privacy_set_ui_ops purple_privacy_set_ui_ops
30.1444 -#define gaim_privacy_get_ui_ops purple_privacy_get_ui_ops
30.1445 -#define gaim_privacy_init purple_privacy_init
30.1446 -
30.1447 -/* from proxy.h */
30.1448 -
30.1449 -#define GAIM_PROXY_USE_GLOBAL PURPLE_PROXY_USE_GLOBAL
30.1450 -#define GAIM_PROXY_NONE PURPLE_PROXY_NONE
30.1451 -#define GAIM_PROXY_HTTP PURPLE_PROXY_HTTP
30.1452 -#define GAIM_PROXY_SOCKS4 PURPLE_PROXY_SOCKS4
30.1453 -#define GAIM_PROXY_SOCKS5 PURPLE_PROXY_SOCKS5
30.1454 -#define GAIM_PROXY_USE_ENVVAR PURPLE_PROXY_USE_ENVVAR
30.1455 -#define GaimProxyType PurpleProxyType
30.1456 -
30.1457 -#define GaimProxyInfo PurpleProxyInfo
30.1458 -
30.1459 -#define GaimProxyConnectData PurpleProxyConnectData
30.1460 -#define GaimProxyConnectFunction PurpleProxyConnectFunction
30.1461 -
30.1462 -#define gaim_proxy_info_new purple_proxy_info_new
30.1463 -#define gaim_proxy_info_destroy purple_proxy_info_destroy
30.1464 -#define gaim_proxy_info_set_type purple_proxy_info_set_type
30.1465 -#define gaim_proxy_info_set_host purple_proxy_info_set_host
30.1466 -#define gaim_proxy_info_set_port purple_proxy_info_set_port
30.1467 -#define gaim_proxy_info_set_username purple_proxy_info_set_username
30.1468 -#define gaim_proxy_info_set_password purple_proxy_info_set_password
30.1469 -#define gaim_proxy_info_get_type purple_proxy_info_get_type
30.1470 -#define gaim_proxy_info_get_host purple_proxy_info_get_host
30.1471 -#define gaim_proxy_info_get_port purple_proxy_info_get_port
30.1472 -#define gaim_proxy_info_get_username purple_proxy_info_get_username
30.1473 -#define gaim_proxy_info_get_password purple_proxy_info_get_password
30.1474 -
30.1475 -#define gaim_global_proxy_get_info purple_global_proxy_get_info
30.1476 -#define gaim_proxy_get_handle purple_proxy_get_handle
30.1477 -#define gaim_proxy_init purple_proxy_init
30.1478 -#define gaim_proxy_uninit purple_proxy_uninit
30.1479 -#define gaim_proxy_get_setup purple_proxy_get_setup
30.1480 -
30.1481 -#define gaim_proxy_connect purple_proxy_connect
30.1482 -#define gaim_proxy_connect_socks5 purple_proxy_connect_socks5
30.1483 -#define gaim_proxy_connect_cancel purple_proxy_connect_cancel
30.1484 -#define gaim_proxy_connect_cancel_with_handle purple_proxy_connect_cancel_with_handle
30.1485 -
30.1486 -/* from prpl.h */
30.1487 -
30.1488 -#define GaimPluginProtocolInfo PurplePluginProtocolInfo
30.1489 -
30.1490 -#define GAIM_ICON_SCALE_DISPLAY PURPLE_ICON_SCALE_DISPLAY
30.1491 -#define GAIM_ICON_SCALE_SEND PURPLE_ICON_SCALE_SEND
30.1492 -#define GaimIconScaleRules PurpleIconScaleRules
30.1493 -
30.1494 -#define GaimBuddyIconSpec PurpleBuddyIconSpec
30.1495 -
30.1496 -#define GaimProtocolOptions PurpleProtocolOptions
30.1497 -
30.1498 -#define GAIM_IS_PROTOCOL_PLUGIN PURPLE_IS_PROTOCOL_PLUGIN
30.1499 -
30.1500 -#define GAIM_PLUGIN_PROTOCOL_INFO PURPLE_PLUGIN_PROTOCOL_INFO
30.1501 -
30.1502 -#define gaim_prpl_got_account_idle purple_prpl_got_account_idle
30.1503 -#define gaim_prpl_got_account_login_time purple_prpl_got_account_login_time
30.1504 -#define gaim_prpl_got_account_status purple_prpl_got_account_status
30.1505 -#define gaim_prpl_got_user_idle purple_prpl_got_user_idle
30.1506 -#define gaim_prpl_got_user_login_time purple_prpl_got_user_login_time
30.1507 -#define gaim_prpl_got_user_status purple_prpl_got_user_status
30.1508 -#define gaim_prpl_change_account_status purple_prpl_change_account_status
30.1509 -#define gaim_prpl_get_statuses purple_prpl_get_statuses
30.1510 -
30.1511 -#define gaim_find_prpl purple_find_prpl
30.1512 -
30.1513 -/* from request.h */
30.1514 -
30.1515 -#define GAIM_DEFAULT_ACTION_NONE PURPLE_DEFAULT_ACTION_NONE
30.1516 -
30.1517 -#define GAIM_REQUEST_INPUT PURPLE_REQUEST_INPUT
30.1518 -#define GAIM_REQUEST_CHOICE PURPLE_REQUEST_CHOICE
30.1519 -#define GAIM_REQUEST_ACTION PURPLE_REQUEST_ACTION
30.1520 -#define GAIM_REQUEST_FIELDS PURPLE_REQUEST_FIELDS
30.1521 -#define GAIM_REQUEST_FILE PURPLE_REQUEST_FILE
30.1522 -#define GAIM_REQUEST_FOLDER PURPLE_REQUEST_FOLDER
30.1523 -#define GaimRequestType PurpleRequestType
30.1524 -
30.1525 -#define GAIM_REQUEST_FIELD_NONE PURPLE_REQUEST_FIELD_NONE
30.1526 -#define GAIM_REQUEST_FIELD_STRING PURPLE_REQUEST_FIELD_STRING
30.1527 -#define GAIM_REQUEST_FIELD_INTEGER PURPLE_REQUEST_FIELD_INTEGER
30.1528 -#define GAIM_REQUEST_FIELD_BOOLEAN PURPLE_REQUEST_FIELD_BOOLEAN
30.1529 -#define GAIM_REQUEST_FIELD_CHOICE PURPLE_REQUEST_FIELD_CHOICE
30.1530 -#define GAIM_REQUEST_FIELD_LIST PURPLE_REQUEST_FIELD_LIST
30.1531 -#define GAIM_REQUEST_FIELD_LABEL PURPLE_REQUEST_FIELD_LABEL
30.1532 -#define GAIM_REQUEST_FIELD_IMAGE PURPLE_REQUEST_FIELD_IMAGE
30.1533 -#define GAIM_REQUEST_FIELD_ACCOUNT PURPLE_REQUEST_FIELD_ACCOUNT
30.1534 -#define GaimRequestFieldType PurpleRequestFieldType
30.1535 -
30.1536 -#define GaimRequestFields PurpleRequestFields
30.1537 -
30.1538 -#define GaimRequestFieldGroup PurpleRequestFieldGroup
30.1539 -
30.1540 -#define GaimRequestField PurpleRequestField
30.1541 -
30.1542 -#define GaimRequestUiOps PurpleRequestUiOps
30.1543 -
30.1544 -#define GaimRequestInputCb PurpleRequestInputCb
30.1545 -#define GaimRequestActionCb PurpleRequestActionCb
30.1546 -#define GaimRequestChoiceCb PurpleRequestChoiceCb
30.1547 -#define GaimRequestFieldsCb PurpleRequestFieldsCb
30.1548 -#define GaimRequestFileCb PurpleRequestFileCb
30.1549 -
30.1550 -#define gaim_request_fields_new purple_request_fields_new
30.1551 -#define gaim_request_fields_destroy purple_request_fields_destroy
30.1552 -#define gaim_request_fields_add_group purple_request_fields_add_group
30.1553 -#define gaim_request_fields_get_groups purple_request_fields_get_groups
30.1554 -#define gaim_request_fields_exists purple_request_fields_exists
30.1555 -#define gaim_request_fields_get_required purple_request_fields_get_required
30.1556 -#define gaim_request_fields_is_field_required purple_request_fields_is_field_required
30.1557 -#define gaim_request_fields_all_required_filled purple_request_fields_all_required_filled
30.1558 -#define gaim_request_fields_get_field purple_request_fields_get_field
30.1559 -#define gaim_request_fields_get_string purple_request_fields_get_string
30.1560 -#define gaim_request_fields_get_integer purple_request_fields_get_integer
30.1561 -#define gaim_request_fields_get_bool purple_request_fields_get_bool
30.1562 -#define gaim_request_fields_get_choice purple_request_fields_get_choice
30.1563 -#define gaim_request_fields_get_account purple_request_fields_get_account
30.1564 -
30.1565 -#define gaim_request_field_group_new purple_request_field_group_new
30.1566 -#define gaim_request_field_group_destroy purple_request_field_group_destroy
30.1567 -#define gaim_request_field_group_add_field purple_request_field_group_add_field
30.1568 -#define gaim_request_field_group_get_title purple_request_field_group_get_title
30.1569 -#define gaim_request_field_group_get_fields purple_request_field_group_get_fields
30.1570 -
30.1571 -#define gaim_request_field_new purple_request_field_new
30.1572 -#define gaim_request_field_destroy purple_request_field_destroy
30.1573 -#define gaim_request_field_set_label purple_request_field_set_label
30.1574 -#define gaim_request_field_set_visible purple_request_field_set_visible
30.1575 -#define gaim_request_field_set_type_hint purple_request_field_set_type_hint
30.1576 -#define gaim_request_field_set_required purple_request_field_set_required
30.1577 -#define gaim_request_field_get_type purple_request_field_get_type
30.1578 -#define gaim_request_field_get_id purple_request_field_get_id
30.1579 -#define gaim_request_field_get_label purple_request_field_get_label
30.1580 -#define gaim_request_field_is_visible purple_request_field_is_visible
30.1581 -#define gaim_request_field_get_type_hint purple_request_field_get_type_hint
30.1582 -#define gaim_request_field_is_required purple_request_field_is_required
30.1583 -
30.1584 -#define gaim_request_field_string_new purple_request_field_string_new
30.1585 -#define gaim_request_field_string_set_default_value \
30.1586 - purple_request_field_string_set_default_value
30.1587 -#define gaim_request_field_string_set_value purple_request_field_string_set_value
30.1588 -#define gaim_request_field_string_set_masked purple_request_field_string_set_masked
30.1589 -#define gaim_request_field_string_set_editable purple_request_field_string_set_editable
30.1590 -#define gaim_request_field_string_get_default_value \
30.1591 - purple_request_field_string_get_default_value
30.1592 -#define gaim_request_field_string_get_value purple_request_field_string_get_value
30.1593 -#define gaim_request_field_string_is_multiline purple_request_field_string_is_multiline
30.1594 -#define gaim_request_field_string_is_masked purple_request_field_string_is_masked
30.1595 -#define gaim_request_field_string_is_editable purple_request_field_string_is_editable
30.1596 -
30.1597 -#define gaim_request_field_int_new purple_request_field_int_new
30.1598 -#define gaim_request_field_int_set_default_value \
30.1599 - purple_request_field_int_set_default_value
30.1600 -#define gaim_request_field_int_set_value purple_request_field_int_set_value
30.1601 -#define gaim_request_field_int_get_default_value \
30.1602 - purple_request_field_int_get_default_value
30.1603 -#define gaim_request_field_int_get_value purple_request_field_int_get_value
30.1604 -
30.1605 -#define gaim_request_field_bool_new purple_request_field_bool_new
30.1606 -#define gaim_request_field_bool_set_default_value \
30.1607 - purple_request_field_book_set_default_value
30.1608 -#define gaim_request_field_bool_set_value purple_request_field_bool_set_value
30.1609 -#define gaim_request_field_bool_get_default_value \
30.1610 - purple_request_field_bool_get_default_value
30.1611 -#define gaim_request_field_bool_get_value purple_request_field_bool_get_value
30.1612 -
30.1613 -#define gaim_request_field_choice_new purple_request_field_choice_new
30.1614 -#define gaim_request_field_choice_add purple_request_field_choice_add
30.1615 -#define gaim_request_field_choice_set_default_value \
30.1616 - purple_request_field_choice_set_default_value
30.1617 -#define gaim_request_field_choice_set_value purple_request_field_choice_set_value
30.1618 -#define gaim_request_field_choice_get_default_value \
30.1619 - purple_request_field_choice_get_default_value
30.1620 -#define gaim_request_field_choice_get_value purple_request_field_choice_get_value
30.1621 -#define gaim_request_field_choice_get_labels purple_request_field_choice_get_labels
30.1622 -
30.1623 -#define gaim_request_field_list_new purple_request_field_list_new
30.1624 -#define gaim_request_field_list_set_multi_select purple_request_field_list_set_multi_select
30.1625 -#define gaim_request_field_list_get_multi_select purple_request_field_list_get_multi_select
30.1626 -#define gaim_request_field_list_get_data purple_request_field_list_get_data
30.1627 -#define gaim_request_field_list_add purple_request_field_list_add
30.1628 -#define gaim_request_field_list_add_selected purple_request_field_list_add_selected
30.1629 -#define gaim_request_field_list_clear_selected purple_request_field_list_clear_selected
30.1630 -#define gaim_request_field_list_set_selected purple_request_field_list_set_selected
30.1631 -#define gaim_request_field_list_is_selected purple_request_field_list_is_selected
30.1632 -#define gaim_request_field_list_get_selected purple_request_field_list_get_selected
30.1633 -#define gaim_request_field_list_get_items purple_request_field_list_get_items
30.1634 -
30.1635 -#define gaim_request_field_label_new purple_request_field_label_new
30.1636 -
30.1637 -#define gaim_request_field_image_new purple_request_field_image_new
30.1638 -#define gaim_request_field_image_set_scale purple_request_field_image_set_scale
30.1639 -#define gaim_request_field_image_get_buffer purple_request_field_image_get_buffer
30.1640 -#define gaim_request_field_image_get_size purple_request_field_image_get_size
30.1641 -#define gaim_request_field_image_get_scale_x purple_request_field_image_get_scale_x
30.1642 -#define gaim_request_field_image_get_scale_y purple_request_field_image_get_scale_y
30.1643 -
30.1644 -#define gaim_request_field_account_new purple_request_field_account_new
30.1645 -#define gaim_request_field_account_set_default_value purple_request_field_account_set_default_value
30.1646 -#define gaim_request_field_account_set_value purple_request_field_account_set_value
30.1647 -#define gaim_request_field_account_set_show_all purple_request_field_account_set_show_all
30.1648 -#define gaim_request_field_account_set_filter purple_request_field_account_set_filter
30.1649 -#define gaim_request_field_account_get_default_value purple_request_field_account_get_default_value
30.1650 -#define gaim_request_field_account_get_value purple_request_field_account_get_value
30.1651 -#define gaim_request_field_account_get_show_all purple_request_field_account_get_show_all
30.1652 -#define gaim_request_field_account_get_filter purple_request_field_account_get_filter
30.1653 -
30.1654 -#define gaim_request_input purple_request_input
30.1655 -#define gaim_request_choice purple_request_choice
30.1656 -#define gaim_request_choice_varg purple_request_choice_varg
30.1657 -#define gaim_request_action purple_request_action
30.1658 -#define gaim_request_action_varg purple_request_action_varg
30.1659 -#define gaim_request_fields(handle, title, primary, secondary, fields, ok_text, ok_cb, cancel_text, cancel_cb, user_data) purple_request_fields(handle, title, primary, secondary, fields, ok_text, ok_cb, cancel_text, cancel_cb, NULL, NULL, NULL, user_data)
30.1660 -#define gaim_request_close purple_request_close
30.1661 -#define gaim_request_close_with_handle purple_request_close_with_handle
30.1662 -
30.1663 -#define gaim_request_yes_no purple_request_yes_no
30.1664 -#define gaim_request_ok_cancel purple_request_ok_cancel
30.1665 -#define gaim_request_accept_cancel purple_request_accept_cancel
30.1666 -
30.1667 -#define gaim_request_file purple_request_file
30.1668 -#define gaim_request_folder purple_request_folder
30.1669 -
30.1670 -#define gaim_request_set_ui_ops purple_request_set_ui_ops
30.1671 -#define gaim_request_get_ui_ops purple_request_get_ui_ops
30.1672 -
30.1673 -/* from roomlist.h */
30.1674 -
30.1675 -#define GaimRoomlist PurpleRoomlist
30.1676 -#define GaimRoomlistRoom PurpleRoomlistRoom
30.1677 -#define GaimRoomlistField PurpleRoomlistField
30.1678 -#define GaimRoomlistUiOps PurpleRoomlistUiOps
30.1679 -
30.1680 -#define GAIM_ROOMLIST_ROOMTYPE_CATEGORY PURPLE_ROOMLIST_ROOMTYPE_CATEGORY
30.1681 -#define GAIM_ROOMLIST_ROOMTYPE_ROOM PURPLE_ROOMLIST_ROOMTYPE_ROOM
30.1682 -#define GaimRoomlistRoomType PurpleRoomlistRoomType
30.1683 -
30.1684 -#define GAIM_ROOMLIST_FIELD_BOOL PURPLE_ROOMLIST_BOOL
30.1685 -#define GAIM_ROOMLIST_FIELD_INT PURPLE_ROOMLIST_INT
30.1686 -#define GAIM_ROOMLIST_FIELD_STRING PURPLE_ROOMLIST_STRING
30.1687 -#define GaimRoomlistFieldType PurpleRoomlistFieldType
30.1688 -
30.1689 -#define gaim_roomlist_show_with_account purple_roomlist_show_with_account
30.1690 -#define gaim_roomlist_new purple_roomlist_new
30.1691 -#define gaim_roomlist_ref purple_roomlist_ref
30.1692 -#define gaim_roomlist_unref purple_roomlist_unref
30.1693 -#define gaim_roomlist_set_fields purple_roomlist_set_fields
30.1694 -#define gaim_roomlist_set_in_progress purple_roomlist_set_in_progress
30.1695 -#define gaim_roomlist_get_in_progress purple_roomlist_get_in_progress
30.1696 -#define gaim_roomlist_room_add purple_roomlist_room_add
30.1697 -
30.1698 -#define gaim_roomlist_get_list purple_roomlist_get_list
30.1699 -#define gaim_roomlist_cancel_get_list purple_roomlist_cancel_get_list
30.1700 -#define gaim_roomlist_expand_category purple_roomlist_expand_category
30.1701 -
30.1702 -#define gaim_roomlist_room_new purple_roomlist_room_new
30.1703 -#define gaim_roomlist_room_add_field purple_roomlist_room_add_field
30.1704 -#define gaim_roomlist_room_join purple_roomlist_room_join
30.1705 -#define gaim_roomlist_field_new purple_roomlist_field_new
30.1706 -
30.1707 -#define gaim_roomlist_set_ui_ops purple_roomlist_set_ui_ops
30.1708 -#define gaim_roomlist_get_ui_ops purple_roomlist_get_ui_ops
30.1709 -
30.1710 -/* from savedstatuses.h */
30.1711 -
30.1712 -#define GaimSavedStatus PurpleSavedStatus
30.1713 -#define GaimSavedStatusSub PurpleSavedStatusSub
30.1714 -
30.1715 -#define gaim_savedstatus_new purple_savedstatus_new
30.1716 -#define gaim_savedstatus_set_title purple_savedstatus_set_title
30.1717 -#define gaim_savedstatus_set_type purple_savedstatus_set_type
30.1718 -#define gaim_savedstatus_set_message purple_savedstatus_set_message
30.1719 -#define gaim_savedstatus_set_substatus purple_savedstatus_set_substatus
30.1720 -#define gaim_savedstatus_unset_substatus purple_savedstatus_unset_substatus
30.1721 -#define gaim_savedstatus_delete purple_savedstatus_delete
30.1722 -
30.1723 -#define gaim_savedstatuses_get_all purple_savedstatuses_get_all
30.1724 -#define gaim_savedstatuses_get_popular purple_savedstatuses_get_popular
30.1725 -#define gaim_savedstatus_get_current purple_savedstatus_get_current
30.1726 -#define gaim_savedstatus_get_default purple_savedstatus_get_default
30.1727 -#define gaim_savedstatus_get_idleaway purple_savedstatus_get_idleaway
30.1728 -#define gaim_savedstatus_is_idleaway purple_savedstatus_is_idleaway
30.1729 -#define gaim_savedstatus_set_idleaway purple_savedstatus_set_idleaway
30.1730 -#define gaim_savedstatus_get_startup purple_savedstatus_get_startup
30.1731 -#define gaim_savedstatus_find purple_savedstatus_find
30.1732 -#define gaim_savedstatus_find_by_creation_time purple_savedstatus_find_by_creation_time
30.1733 -#define gaim_savedstatus_find_transient_by_type_and_message \
30.1734 - purple_savedstatus_find_transient_by_type_and_message
30.1735 -
30.1736 -#define gaim_savedstatus_is_transient purple_savedstatus_is_transient
30.1737 -#define gaim_savedstatus_get_title purple_savedstatus_get_title
30.1738 -#define gaim_savedstatus_get_type purple_savedstatus_get_type
30.1739 -#define gaim_savedstatus_get_message purple_savedstatus_get_message
30.1740 -#define gaim_savedstatus_get_creation_time purple_savedstatus_get_creation_time
30.1741 -#define gaim_savedstatus_has_substatuses purple_savedstatus_has_substatuses
30.1742 -#define gaim_savedstatus_get_substatus purple_savedstatus_get_substatus
30.1743 -#define gaim_savedstatus_substatus_get_type purple_savedstatus_substatus_get_type
30.1744 -#define gaim_savedstatus_substatus_get_message purple_savedstatus_substatus_get_message
30.1745 -#define gaim_savedstatus_activate purple_savedstatus_activate
30.1746 -#define gaim_savedstatus_activate_for_account purple_savedstatus_activate_for_account
30.1747 -
30.1748 -#define gaim_savedstatuses_get_handle purple_savedstatuses_get_handle
30.1749 -#define gaim_savedstatuses_init purple_savedstatuses_init
30.1750 -#define gaim_savedstatuses_uninit purple_savedstatuses_uninit
30.1751 -
30.1752 -/* from signals.h */
30.1753 -
30.1754 -#define GAIM_CALLBACK PURPLE_CALLBACK
30.1755 -
30.1756 -#define GaimCallback PurpleCallback
30.1757 -#define GaimSignalMarshalFunc PurpleSignalMarshalFunc
30.1758 -
30.1759 -#define GAIM_SIGNAL_PRIORITY_DEFAULT PURPLE_SIGNAL_PRIORITY_DEFAULT
30.1760 -#define GAIM_SIGNAL_PRIORITY_HIGHEST PURPLE_SIGNAL_PRIORITY_HIGHEST
30.1761 -#define GAIM_SIGNAL_PRIORITY_LOWEST PURPLE_SIGNAL_PRIORITY_LOWEST
30.1762 -
30.1763 -#define gaim_signal_register purple_signal_register
30.1764 -#define gaim_signal_unregister purple_signal_unregister
30.1765 -
30.1766 -#define gaim_signals_unregister_by_instance purple_signals_unregister_by_instance
30.1767 -
30.1768 -#define gaim_signal_get_values purple_signal_get_values
30.1769 -#define gaim_signal_connect_priority purple_signal_connect_priority
30.1770 -#define gaim_signal_connect purple_signal_connect
30.1771 -#define gaim_signal_connect_priority_vargs purple_signal_connect_priority_vargs
30.1772 -#define gaim_signal_connect_vargs purple_signal_connect_vargs
30.1773 -#define gaim_signal_disconnect purple_signal_disconnect
30.1774 -
30.1775 -#define gaim_signals_disconnect_by_handle purple_signals_disconnect_by_handle
30.1776 -
30.1777 -#define gaim_signal_emit purple_signal_emit
30.1778 -#define gaim_signal_emit_vargs purple_signal_emit_vargs
30.1779 -#define gaim_signal_emit_return_1 purple_signal_emit_vargs
30.1780 -#define gaim_signal_emit_vargs_return_1 purple_signal_emit_vargs_return_1
30.1781 -
30.1782 -#define gaim_signals_init purple_signals_init
30.1783 -#define gaim_signals_uninit purple_signals_uninit
30.1784 -
30.1785 -#define gaim_marshal_VOID \
30.1786 - purple_marshal_VOID
30.1787 -#define gaim_marshal_VOID__INT \
30.1788 - purple_marshal_VOID__INT
30.1789 -#define gaim_marshal_VOID__INT_INT \
30.1790 - purple_marshal_VOID_INT_INT
30.1791 -#define gaim_marshal_VOID__POINTER \
30.1792 - purple_marshal_VOID__POINTER
30.1793 -#define gaim_marshal_VOID__POINTER_UINT \
30.1794 - purple_marshal_VOID__POINTER_UINT
30.1795 -#define gaim_marshal_VOID__POINTER_INT_INT \
30.1796 - purple_marshal_VOID__POINTER_INT_INT
30.1797 -#define gaim_marshal_VOID__POINTER_POINTER \
30.1798 - purple_marshal_VOID__POINTER_POINTER
30.1799 -#define gaim_marshal_VOID__POINTER_POINTER_UINT \
30.1800 - purple_marshal_VOID__POINTER_POINTER_UINT
30.1801 -#define gaim_marshal_VOID__POINTER_POINTER_UINT_UINT \
30.1802 - purple_marshal_VOID__POINTER_POINTER_UINT_UINT
30.1803 -#define gaim_marshal_VOID__POINTER_POINTER_POINTER \
30.1804 - purple_marshal_VOID__POINTER_POINTER_POINTER
30.1805 -#define gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER \
30.1806 - purple_marshal_VOID__POINTER_POINTER_POINTER_POINTER
30.1807 -#define gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER_POINTER \
30.1808 - purple_marshal_VOID__POINTER_POINTER_POINTER_POINTER_POINTER
30.1809 -#define gaim_marshal_VOID__POINTER_POINTER_POINTER_UINT \
30.1810 - purple_marshal_VOID__POINTER_POINTER_POINTER_UINT
30.1811 -#define gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT \
30.1812 - purple_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT
30.1813 -#define gaim_marshal_VOID__POINTER_POINTER_POINTER_UINT_UINT \
30.1814 - purple_marshal_VOID__POINTER_POINTER_POINTER_UINT_UINT
30.1815 -
30.1816 -#define gaim_marshal_INT__INT \
30.1817 - purple_marshal_INT__INT
30.1818 -#define gaim_marshal_INT__INT_INT \
30.1819 - purple_marshal_INT__INT_INT
30.1820 -#define gaim_marshal_INT__POINTER_POINTER_POINTER_POINTER_POINTER \
30.1821 - purple_marshal_INT__POINTER_POINTER_POINTER_POINTER_POINTER
30.1822 -
30.1823 -#define gaim_marshal_BOOLEAN__POINTER \
30.1824 - purple_marshal_BOOLEAN__POINTER
30.1825 -#define gaim_marshal_BOOLEAN__POINTER_POINTER \
30.1826 - purple_marshal_BOOLEAN__POINTER_POINTER
30.1827 -#define gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER \
30.1828 - purple_marshal_BOOLEAN__POINTER_POINTER_POINTER
30.1829 -#define gaim_marshal_BOOLEAN__POINTER_POINTER_UINT \
30.1830 - purple_marshal_BOOLEAN__POINTER_POINTER_UINT
30.1831 -#define gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT \
30.1832 - purple_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT
30.1833 -#define gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER \
30.1834 - purple_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER
30.1835 -#define gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER \
30.1836 - purple_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER
30.1837 -
30.1838 -#define gaim_marshal_BOOLEAN__INT_POINTER \
30.1839 - purple_marshal_BOOLEAN__INT_POINTER
30.1840 -
30.1841 -#define gaim_marshal_POINTER__POINTER_INT \
30.1842 - purple_marshal_POINTER__POINTER_INT
30.1843 -#define gaim_marshal_POINTER__POINTER_INT64 \
30.1844 - purple_marshal_POINTER__POINTER_INT64
30.1845 -#define gaim_marshal_POINTER__POINTER_INT_BOOLEAN \
30.1846 - purple_marshal_POINTER__POINTER_INT_BOOLEAN
30.1847 -#define gaim_marshal_POINTER__POINTER_INT64_BOOLEAN \
30.1848 - purple_marshal_POINTER__POINTER_INT64_BOOLEAN
30.1849 -#define gaim_marshal_POINTER__POINTER_POINTER \
30.1850 - purple_marshal_POINTER__POINTER_POINTER
30.1851 -
30.1852 -/* from sound.h */
30.1853 -
30.1854 -#define GAIM_SOUND_BUDDY_ARRIVE PURPLE_SOUND_BUDDY_ARRIVE
30.1855 -#define GAIM_SOUND_BUDDY_LEAVE PURPLE_SOUND_BUDDY_LEAVE
30.1856 -#define GAIM_SOUND_RECEIVE PURPLE_SOUND_RECEIVE
30.1857 -#define GAIM_SOUND_FIRST_RECEIVE PURPLE_SOUND_FIRST_RECEIVE
30.1858 -#define GAIM_SOUND_SEND PURPLE_SOUND_SEND
30.1859 -#define GAIM_SOUND_CHAT_JOIN PURPLE_SOUND_CHAT_JOIN
30.1860 -#define GAIM_SOUND_CHAT_LEAVE PURPLE_SOUND_CHAT_LEAVE
30.1861 -#define GAIM_SOUND_CHAT_YOU_SAY PURPLE_SOUND_CHAT_YOU_SAY
30.1862 -#define GAIM_SOUND_CHAT_SAY PURPLE_SOUND_CHAT_SAY
30.1863 -#define GAIM_SOUND_POUNCE_DEFAULT PURPLE_SOUND_POUNCE_DEFAULT
30.1864 -#define GAIM_SOUND_CHAT_NICK PURPLE_SOUND_CHAT_NICK
30.1865 -#define GAIM_NUM_SOUNDS PURPLE_NUM_SOUNDS
30.1866 -#define GaimSoundEventID PurpleSoundEventID
30.1867 -
30.1868 -#define GaimSoundUiOps PurpleSoundUiOps
30.1869 -
30.1870 -#define gaim_sound_play_file purple_sound_play_file
30.1871 -#define gaim_sound_play_event purple_sound_play_event
30.1872 -#define gaim_sound_set_ui_ops purple_sound_set_ui_ops
30.1873 -#define gaim_sound_get_ui_ops purple_sound_get_ui_ops
30.1874 -#define gaim_sound_init purple_sound_init
30.1875 -#define gaim_sound_uninit purple_sound_uninit
30.1876 -
30.1877 -#define gaim_sounds_get_handle purple_sounds_get_handle
30.1878 -
30.1879 -/* from sslconn.h */
30.1880 -
30.1881 -#define GAIM_SSL_DEFAULT_PORT PURPLE_SSL_DEFAULT_PORT
30.1882 -
30.1883 -#define GAIM_SSL_HANDSHAKE_FAILED PURPLE_SSL_HANDSHAKE_FAILED
30.1884 -#define GAIM_SSL_CONNECT_FAILED PURPLE_SSL_CONNECT_FAILED
30.1885 -#define GaimSslErrorType PurpleSslErrorType
30.1886 -
30.1887 -#define GaimSslConnection PurpleSslConnection
30.1888 -
30.1889 -#define GaimSslInputFunction PurpleSslInputFunction
30.1890 -#define GaimSslErrorFunction PurpleSslErrorFunction
30.1891 -
30.1892 -#define GaimSslOps PurpleSslOps
30.1893 -
30.1894 -#define gaim_ssl_is_supported purple_ssl_is_supported
30.1895 -#define gaim_ssl_connect purple_ssl_connect
30.1896 -#define gaim_ssl_connect_fd purple_ssl_connect_fd
30.1897 -#define gaim_ssl_input_add purple_ssl_input_add
30.1898 -#define gaim_ssl_close purple_ssl_close
30.1899 -#define gaim_ssl_read purple_ssl_read
30.1900 -#define gaim_ssl_write purple_ssl_write
30.1901 -
30.1902 -#define gaim_ssl_set_ops purple_ssl_set_ops
30.1903 -#define gaim_ssl_get_ops purple_ssl_get_ops
30.1904 -#define gaim_ssl_init purple_ssl_init
30.1905 -#define gaim_ssl_uninit purple_ssl_uninit
30.1906 -
30.1907 -/* from status.h */
30.1908 -
30.1909 -#define GaimStatusType PurpleStatusType
30.1910 -#define GaimStatusAttr PurpleStatusAttr
30.1911 -#define GaimPresence PurplePresence
30.1912 -#define GaimStatus PurpleStatus
30.1913 -
30.1914 -#define GAIM_PRESENCE_CONTEXT_UNSET PURPLE_PRESENCE_CONTEXT_UNSET
30.1915 -#define GAIM_PRESENCE_CONTEXT_ACCOUNT PURPLE_PRESENCE_CONTEXT_ACCOUNT
30.1916 -#define GAIM_PRESENCE_CONTEXT_CONV PURPLE_PRESENCE_CONTEXT_CONV
30.1917 -#define GAIM_PRESENCE_CONTEXT_BUDDY PURPLE_PRESENCE_CONTEXT_BUDDY
30.1918 -#define GaimPresenceContext PurplePresenceContext
30.1919 -
30.1920 -#define GAIM_STATUS_UNSET PURPLE_STATUS_UNSET
30.1921 -#define GAIM_STATUS_OFFLINE PURPLE_STATUS_OFFLINE
30.1922 -#define GAIM_STATUS_AVAILABLE PURPLE_STATUS_AVAILABLE
30.1923 -#define GAIM_STATUS_UNAVAILABLE PURPLE_STATUS_UNAVAILABLE
30.1924 -#define GAIM_STATUS_INVISIBLE PURPLE_STATUS_INVISIBLE
30.1925 -#define GAIM_STATUS_AWAY PURPLE_STATUS_AWAY
30.1926 -#define GAIM_STATUS_EXTENDED_AWAY PURPLE_STATUS_EXTENDED_AWAY
30.1927 -#define GAIM_STATUS_MOBILE PURPLE_STATUS_MOBILE
30.1928 -#define GAIM_STATUS_NUM_PRIMITIVES PURPLE_STATUS_NUM_PRIMITIVES
30.1929 -#define GaimStatusPrimitive PurpleStatusPrimitive
30.1930 -
30.1931 -#define gaim_primitive_get_id_from_type purple_primitive_get_id_from_type
30.1932 -#define gaim_primitive_get_name_from_type purple_primitive_get_name_from_type
30.1933 -#define gaim_primitive_get_type_from_id purple_primitive_get_type_from_id
30.1934 -
30.1935 -#define gaim_status_type_new_full purple_status_type_new_full
30.1936 -#define gaim_status_type_new purple_status_type_new
30.1937 -#define gaim_status_type_new_with_attrs purple_status_type_new_with_attrs
30.1938 -#define gaim_status_type_destroy purple_status_type_destroy
30.1939 -#define gaim_status_type_set_primary_attr purple_status_type_set_primary_attr
30.1940 -#define gaim_status_type_add_attr purple_status_type_add_attr
30.1941 -#define gaim_status_type_add_attrs purple_status_type_add_attrs
30.1942 -#define gaim_status_type_add_attrs_vargs purple_status_type_add_attrs_vargs
30.1943 -#define gaim_status_type_get_primitive purple_status_type_get_primitive
30.1944 -#define gaim_status_type_get_id purple_status_type_get_id
30.1945 -#define gaim_status_type_get_name purple_status_type_get_name
30.1946 -#define gaim_status_type_is_saveable purple_status_type_is_saveable
30.1947 -#define gaim_status_type_is_user_settable purple_status_type_is_user_settable
30.1948 -#define gaim_status_type_is_independent purple_status_type_is_independent
30.1949 -#define gaim_status_type_is_exclusive purple_status_type_is_exclusive
30.1950 -#define gaim_status_type_is_available purple_status_type_is_available
30.1951 -#define gaim_status_type_get_primary_attr purple_status_type_get_primary_attr
30.1952 -#define gaim_status_type_get_attr purple_status_type_get_attr
30.1953 -#define gaim_status_type_get_attrs purple_status_type_get_attrs
30.1954 -#define gaim_status_type_find_with_id purple_status_type_find_with_id
30.1955 -
30.1956 -#define gaim_status_attr_new purple_status_attr_new
30.1957 -#define gaim_status_attr_destroy purple_status_attr_destroy
30.1958 -#define gaim_status_attr_get_id purple_status_attr_get_id
30.1959 -#define gaim_status_attr_get_name purple_status_attr_get_name
30.1960 -#define gaim_status_attr_get_value purple_status_attr_get_value
30.1961 -
30.1962 -#define gaim_status_new purple_status_new
30.1963 -#define gaim_status_destroy purple_status_destroy
30.1964 -#define gaim_status_set_active purple_status_set_active
30.1965 -#define gaim_status_set_active_with_attrs purple_status_set_active_with_attrs
30.1966 -#define gaim_status_set_active_with_attrs_list purple_status_set_active_with_attrs_list
30.1967 -#define gaim_status_set_attr_boolean purple_status_set_attr_boolean
30.1968 -#define gaim_status_set_attr_int purple_status_set_attr_int
30.1969 -#define gaim_status_set_attr_string purple_status_set_attr_string
30.1970 -#define gaim_status_get_type purple_status_get_type
30.1971 -#define gaim_status_get_presence purple_status_get_presence
30.1972 -#define gaim_status_get_id purple_status_get_id
30.1973 -#define gaim_status_get_name purple_status_get_name
30.1974 -#define gaim_status_is_independent purple_status_is_independent
30.1975 -#define gaim_status_is_exclusive purple_status_is_exclusive
30.1976 -#define gaim_status_is_available purple_status_is_available
30.1977 -#define gaim_status_is_active purple_status_is_active
30.1978 -#define gaim_status_is_online purple_status_is_online
30.1979 -#define gaim_status_get_attr_value purple_status_get_attr_value
30.1980 -#define gaim_status_get_attr_boolean purple_status_get_attr_boolean
30.1981 -#define gaim_status_get_attr_int purple_status_get_attr_int
30.1982 -#define gaim_status_get_attr_string purple_status_get_attr_string
30.1983 -#define gaim_status_compare purple_status_compare
30.1984 -
30.1985 -#define gaim_presence_new purple_presence_new
30.1986 -#define gaim_presence_new_for_account purple_presence_new_for_account
30.1987 -#define gaim_presence_new_for_conv purple_presence_new_for_conv
30.1988 -#define gaim_presence_new_for_buddy purple_presence_new_for_buddy
30.1989 -#define gaim_presence_destroy purple_presence_destroy
30.1990 -#define gaim_presence_add_status purple_presence_add_status
30.1991 -#define gaim_presence_add_list purple_presence_add_list
30.1992 -#define gaim_presence_set_status_active purple_presence_set_status_active
30.1993 -#define gaim_presence_switch_status purple_presence_switch_status
30.1994 -#define gaim_presence_set_idle purple_presence_set_idle
30.1995 -#define gaim_presence_set_login_time purple_presence_set_login_time
30.1996 -#define gaim_presence_get_context purple_presence_get_context
30.1997 -#define gaim_presence_get_account purple_presence_get_account
30.1998 -#define gaim_presence_get_conversation purple_presence_get_conversation
30.1999 -#define gaim_presence_get_chat_user purple_presence_get_chat_user
30.2000 -#define gaim_presence_get_statuses purple_presence_get_statuses
30.2001 -#define gaim_presence_get_status purple_presence_get_status
30.2002 -#define gaim_presence_get_active_status purple_presence_get_active_status
30.2003 -#define gaim_presence_is_available purple_presence_is_available
30.2004 -#define gaim_presence_is_online purple_presence_is_online
30.2005 -#define gaim_presence_is_status_active purple_presence_is_status_active
30.2006 -#define gaim_presence_is_status_primitive_active \
30.2007 - purple_presence_is_status_primitive_active
30.2008 -#define gaim_presence_is_idle purple_presence_is_idle
30.2009 -#define gaim_presence_get_idle_time purple_presence_get_idle_time
30.2010 -#define gaim_presence_get_login_time purple_presence_get_login_time
30.2011 -#define gaim_presence_compare purple_presence_compare
30.2012 -
30.2013 -#define gaim_status_get_handle purple_status_get_handle
30.2014 -#define gaim_status_init purple_status_init
30.2015 -#define gaim_status_uninit purple_status_uninit
30.2016 -
30.2017 -/* from stringref.h */
30.2018 -
30.2019 -#define GaimStringref PurpleStringref
30.2020 -
30.2021 -#define gaim_stringref_new purple_stringref_new
30.2022 -#define gaim_stringref_new_noref purple_stringref_new_noref
30.2023 -#define gaim_stringref_printf purple_stringref_printf
30.2024 -#define gaim_stringref_ref purple_stringref_ref
30.2025 -#define gaim_stringref_unref purple_stringref_unref
30.2026 -#define gaim_stringref_value purple_stringref_value
30.2027 -#define gaim_stringref_cmp purple_stringref_cmp
30.2028 -#define gaim_stringref_len purple_stringref_len
30.2029 -
30.2030 -/* from stun.h */
30.2031 -
30.2032 -#define GaimStunNatDiscovery PurpleStunNatDiscovery
30.2033 -
30.2034 -#define GAIM_STUN_STATUS_UNDISCOVERED PURPLE_STUN_STATUS_UNDISCOVERED
30.2035 -#define GAIM_STUN_STATUS_UNKNOWN PURPLE_STUN_STATUS_UNKNOWN
30.2036 -#define GAIM_STUN_STATUS_DISCOVERING PURPLE_STUN_STATUS_DISCOVERING
30.2037 -#define GAIM_STUN_STATUS_DISCOVERED PURPLE_STUN_STATUS_DISCOVERED
30.2038 -#define GaimStunStatus PurpleStunStatus
30.2039 -
30.2040 -#define GAIM_STUN_NAT_TYPE_PUBLIC_IP PURPLE_STUN_NAT_TYPE_PUBLIC_IP
30.2041 -#define GAIM_STUN_NAT_TYPE_UNKNOWN_NAT PURPLE_STUN_NAT_TYPE_UNKNOWN_NAT
30.2042 -#define GAIM_STUN_NAT_TYPE_FULL_CONE PURPLE_STUN_NAT_TYPE_FULL_CONE
30.2043 -#define GAIM_STUN_NAT_TYPE_RESTRICTED_CONE PURPLE_STUN_NAT_TYPE_RESTRICTED_CONE
30.2044 -#define GAIM_STUN_NAT_TYPE_PORT_RESTRICTED_CONE PURPLE_STUN_NAT_TYPE_PORT_RESTRICTED_CONE
30.2045 -#define GAIM_STUN_NAT_TYPE_SYMMETRIC PURPLE_STUN_NAT_TYPE_SYMMETRIC
30.2046 -#define GaimStunNatType PurpleStunNatType
30.2047 -
30.2048 -/* why didn't this have a Gaim prefix before? */
30.2049 -#define StunCallback PurpleStunCallback
30.2050 -
30.2051 -#define gaim_stun_discover purple_stun_discover
30.2052 -#define gaim_stun_init purple_stun_init
30.2053 -
30.2054 -/* from upnp.h */
30.2055 -
30.2056 -/* suggested rename: PurpleUPnpMappingHandle */
30.2057 -#define UPnPMappingAddRemove PurpleUPnPMappingAddRemove
30.2058 -
30.2059 -#define GaimUPnPCallback PurpleUPnPCallback
30.2060 -
30.2061 -#define gaim_upnp_discover purple_upnp_discover
30.2062 -#define gaim_upnp_get_public_ip purple_upnp_get_public_ip
30.2063 -#define gaim_upnp_cancel_port_mapping purple_upnp_cancel_port_mapping
30.2064 -#define gaim_upnp_set_port_mapping purple_upnp_set_port_mapping
30.2065 -
30.2066 -#define gaim_upnp_remove_port_mapping purple_upnp_remove_port_mapping
30.2067 -
30.2068 -/* from util.h */
30.2069 -
30.2070 -#define GaimUtilFetchUrlData PurpleUtilFetchUrlData
30.2071 -#define GaimMenuAction PurpleMenuAction
30.2072 -
30.2073 -#define GaimInfoFieldFormatCallback PurpleIntoFieldFormatCallback
30.2074 -
30.2075 -#define GaimKeyValuePair PurpleKeyValuePair
30.2076 -
30.2077 -#define gaim_menu_action_new purple_menu_action_new
30.2078 -#define gaim_menu_action_free purple_menu_action_free
30.2079 -
30.2080 -#define gaim_base16_encode purple_base16_encode
30.2081 -#define gaim_base16_decode purple_base16_decode
30.2082 -#define gaim_base64_encode purple_base64_encode
30.2083 -#define gaim_base64_decode purple_base64_decode
30.2084 -#define gaim_quotedp_decode purple_quotedp_decode
30.2085 -
30.2086 -#define gaim_mime_decode_field purple_mime_deco_field
30.2087 -
30.2088 -#define gaim_utf8_strftime purple_utf8_strftime
30.2089 -#define gaim_date_format_short purple_date_format_short
30.2090 -#define gaim_date_format_long purple_date_format_long
30.2091 -#define gaim_date_format_full purple_date_format_full
30.2092 -#define gaim_time_format purple_time_format
30.2093 -#define gaim_time_build purple_time_build
30.2094 -
30.2095 -#define GAIM_NO_TZ_OFF PURPLE_NO_TZ_OFF
30.2096 -
30.2097 -#define gaim_str_to_time purple_str_to_time
30.2098 -
30.2099 -#define gaim_markup_find_tag purple_markup_find_tag
30.2100 -#define gaim_markup_extract_info_field purple_markup_extract_info_field
30.2101 -#define gaim_markup_html_to_xhtml purple_markup_html_to_xhtml
30.2102 -#define gaim_markup_strip_html purple_markup_strip_html
30.2103 -#define gaim_markup_linkify purple_markup_linkify
30.2104 -#define gaim_markup_slice purple_markup_slice
30.2105 -#define gaim_markup_get_tag_name purple_markup_get_tag_name
30.2106 -#define gaim_unescape_html purple_unescape_html
30.2107 -
30.2108 -#define gaim_home_dir purple_home_dir
30.2109 -#define gaim_user_dir purple_user_dir
30.2110 -
30.2111 -#define gaim_util_set_user_dir purple_util_set_user_dir
30.2112 -
30.2113 -#define gaim_build_dir purple_build_dir
30.2114 -
30.2115 -#define gaim_util_write_data_to_file purple_util_write_data_to_file
30.2116 -
30.2117 -#define gaim_util_read_xml_from_file purple_util_read_xml_from_file
30.2118 -
30.2119 -#define gaim_mkstemp purple_mkstemp
30.2120 -
30.2121 -#define gaim_program_is_valid purple_program_is_valid
30.2122 -
30.2123 -#define gaim_running_gnome purple_running_gnome
30.2124 -#define gaim_running_kde purple_running_kde
30.2125 -#define gaim_running_osx purple_running_osx
30.2126 -
30.2127 -#define gaim_fd_get_ip purple_fd_get_ip
30.2128 -
30.2129 -#define gaim_normalize purple_normalize
30.2130 -#define gaim_normalize_nocase purple_normalize_nocase
30.2131 -
30.2132 -#define gaim_strdup_withhtml purple_strdup_withhtml
30.2133 -
30.2134 -#define gaim_str_has_prefix purple_str_has_prefix
30.2135 -#define gaim_str_has_suffix purple_str_has_suffix
30.2136 -#define gaim_str_add_cr purple_str_add_cr
30.2137 -#define gaim_str_strip_char purple_str_strip_char
30.2138 -
30.2139 -#define gaim_util_chrreplace purple_util_chrreplace
30.2140 -
30.2141 -#define gaim_strreplace purple_strreplace
30.2142 -
30.2143 -#define gaim_utf8_ncr_encode purple_utf8_ncr_encode
30.2144 -#define gaim_utf8_ncr_decode purple_utf8_ncr_decode
30.2145 -
30.2146 -#define gaim_strcasereplace purple_strcasereplace
30.2147 -#define gaim_strcasestr purple_strcasestr
30.2148 -
30.2149 -#define gaim_str_size_to_units purple_str_size_to_units
30.2150 -#define gaim_str_seconds_to_string purple_str_seconds_to_string
30.2151 -#define gaim_str_binary_to_ascii purple_str_binary_to_ascii
30.2152 -
30.2153 -
30.2154 -#define gaim_got_protocol_handler_uri purple_got_protocol_handler_uri
30.2155 -
30.2156 -#define gaim_url_parse purple_url_parse
30.2157 -
30.2158 -#define GaimUtilFetchUrlCallback PurpleUtilFetchUrlCallback
30.2159 -#define gaim_util_fetch_url purple_util_fetch_url
30.2160 -#define gaim_util_fetch_url_request purple_util_fetch_url_request
30.2161 -#define gaim_util_fetch_url_cancel purple_util_fetch_url_cancel
30.2162 -
30.2163 -#define gaim_url_decode purple_url_decode
30.2164 -#define gaim_url_encode purple_url_encode
30.2165 -
30.2166 -#define gaim_email_is_valid purple_email_is_valid
30.2167 -
30.2168 -#define gaim_uri_list_extract_uris purple_uri_list_extract_uris
30.2169 -#define gaim_uri_list_extract_filenames purple_uri_list_extract_filenames
30.2170 -
30.2171 -#define gaim_utf8_try_convert purple_utf8_try_convert
30.2172 -#define gaim_utf8_salvage purple_utf8_salvage
30.2173 -#define gaim_utf8_strcasecmp purple_utf8_strcasecmp
30.2174 -#define gaim_utf8_has_word purple_utf8_has_word
30.2175 -
30.2176 -#define gaim_print_utf8_to_console purple_print_utf8_to_console
30.2177 -
30.2178 -#define gaim_message_meify purple_message_meify
30.2179 -
30.2180 -#define gaim_text_strip_mnemonic purple_text_strip_mnemonic
30.2181 -
30.2182 -#define gaim_unescape_filename purple_unescape_filename
30.2183 -#define gaim_escape_filename purple_escape_filename
30.2184 -
30.2185 -/* from value.h */
30.2186 -
30.2187 -#define GAIM_TYPE_UNKNOWN PURPLE_TYPE_UNKNOWN
30.2188 -#define GAIM_TYPE_SUBTYPE PURPLE_TYPE_SUBTYPE
30.2189 -#define GAIM_TYPE_CHAR PURPLE_TYPE_CHAR
30.2190 -#define GAIM_TYPE_UCHAR PURPLE_TYPE_UCHAR
30.2191 -#define GAIM_TYPE_BOOLEAN PURPLE_TYPE_BOOLEAN
30.2192 -#define GAIM_TYPE_SHORT PURPLE_TYPE_SHORT
30.2193 -#define GAIM_TYPE_USHORT PURPLE_TYPE_USHORT
30.2194 -#define GAIM_TYPE_INT PURPLE_TYPE_INT
30.2195 -#define GAIM_TYPE_UINT PURPLE_TYPE_UINT
30.2196 -#define GAIM_TYPE_LONG PURPLE_TYPE_LONG
30.2197 -#define GAIM_TYPE_ULONG PURPLE_TYPE_ULONG
30.2198 -#define GAIM_TYPE_INT64 PURPLE_TYPE_INT64
30.2199 -#define GAIM_TYPE_UINT64 PURPLE_TYPE_UINT64
30.2200 -#define GAIM_TYPE_STRING PURPLE_TYPE_STRING
30.2201 -#define GAIM_TYPE_OBJECT PURPLE_TYPE_OBJECT
30.2202 -#define GAIM_TYPE_POINTER PURPLE_TYPE_POINTER
30.2203 -#define GAIM_TYPE_ENUM PURPLE_TYPE_ENUM
30.2204 -#define GAIM_TYPE_BOXED PURPLE_TYPE_BOXED
30.2205 -#define GaimType PurpleType
30.2206 -
30.2207 -
30.2208 -#define GAIM_SUBTYPE_UNKNOWN PURPLE_SUBTYPE_UNKNOWN
30.2209 -#define GAIM_SUBTYPE_ACCOUNT PURPLE_SUBTYPE_ACCOUNT
30.2210 -#define GAIM_SUBTYPE_BLIST PURPLE_SUBTYPE_BLIST
30.2211 -#define GAIM_SUBTYPE_BLIST_BUDDY PURPLE_SUBTYPE_BLIST_BUDDY
30.2212 -#define GAIM_SUBTYPE_BLIST_GROUP PURPLE_SUBTYPE_BLIST_GROUP
30.2213 -#define GAIM_SUBTYPE_BLIST_CHAT PURPLE_SUBTYPE_BLIST_CHAT
30.2214 -#define GAIM_SUBTYPE_BUDDY_ICON PURPLE_SUBTYPE_BUDDY_ICON
30.2215 -#define GAIM_SUBTYPE_CONNECTION PURPLE_SUBTYPE_CONNECTION
30.2216 -#define GAIM_SUBTYPE_CONVERSATION PURPLE_SUBTYPE_CONVERSATION
30.2217 -#define GAIM_SUBTYPE_PLUGIN PURPLE_SUBTYPE_PLUGIN
30.2218 -#define GAIM_SUBTYPE_BLIST_NODE PURPLE_SUBTYPE_BLIST_NODE
30.2219 -#define GAIM_SUBTYPE_CIPHER PURPLE_SUBTYPE_CIPHER
30.2220 -#define GAIM_SUBTYPE_STATUS PURPLE_SUBTYPE_STATUS
30.2221 -#define GAIM_SUBTYPE_LOG PURPLE_SUBTYPE_LOG
30.2222 -#define GAIM_SUBTYPE_XFER PURPLE_SUBTYPE_XFER
30.2223 -#define GAIM_SUBTYPE_SAVEDSTATUS PURPLE_SUBTYPE_SAVEDSTATUS
30.2224 -#define GAIM_SUBTYPE_XMLNODE PURPLE_SUBTYPE_XMLNODE
30.2225 -#define GAIM_SUBTYPE_USERINFO PURPLE_SUBTYPE_USERINFO
30.2226 -#define GaimSubType PurpleSubType
30.2227 -
30.2228 -#define GaimValue PurpleValue
30.2229 -
30.2230 -#define gaim_value_new purple_value_new
30.2231 -#define gaim_value_new_outgoing purple_value_new_outgoing
30.2232 -#define gaim_value_destroy purple_value_destroy
30.2233 -#define gaim_value_dup purple_value_dup
30.2234 -#define gaim_value_purple_buddy_icon_get_extensionget_type purple_value_get_type
30.2235 -#define gaim_value_get_subtype purple_value_get_subtype
30.2236 -#define gaim_value_get_specific_type purple_value_get_specific_type
30.2237 -#define gaim_value_is_outgoing purple_value_is_outgoing
30.2238 -#define gaim_value_set_char purple_value_set_char
30.2239 -#define gaim_value_set_uchar purple_value_set_uchar
30.2240 -#define gaim_value_set_boolean purple_value_set_boolean
30.2241 -#define gaim_value_set_short purple_value_set_short
30.2242 -#define gaim_value_set_ushort purple_value_set_ushort
30.2243 -#define gaim_value_set_int purple_value_set_int
30.2244 -#define gaim_value_set_uint purple_value_set_uint
30.2245 -#define gaim_value_set_long purple_value_set_long
30.2246 -#define gaim_value_set_ulong purple_value_set_ulong
30.2247 -#define gaim_value_set_int64 purple_value_set_int64
30.2248 -#define gaim_value_set_uint64 purple_value_set_uint64
30.2249 -#define gaim_value_set_string purple_value_set_string
30.2250 -#define gaim_value_set_object purple_value_set_object
30.2251 -#define gaim_value_set_pointer purple_value_set_pointer
30.2252 -#define gaim_value_set_enum purple_value_set_enum
30.2253 -#define gaim_value_set_boxed purple_value_set_boxed
30.2254 -#define gaim_value_get_char purple_value_get_char
30.2255 -#define gaim_value_get_uchar purple_value_get_uchar
30.2256 -#define gaim_value_get_boolean purple_value_get_boolean
30.2257 -#define gaim_value_get_short purple_value_get_short
30.2258 -#define gaim_value_get_ushort purple_value_get_ushort
30.2259 -#define gaim_value_get_int purple_value_get_int
30.2260 -#define gaim_value_get_uint purple_value_get_uint
30.2261 -#define gaim_value_get_long purple_value_get_long
30.2262 -#define gaim_value_get_ulong purple_value_get_ulong
30.2263 -#define gaim_value_get_int64 purple_value_get_int64
30.2264 -#define gaim_value_get_uint64 purple_value_get_uint64
30.2265 -#define gaim_value_get_string purple_value_get_string
30.2266 -#define gaim_value_get_object purple_value_get_object
30.2267 -#define gaim_value_get_pointer purple_value_get_pointer
30.2268 -#define gaim_value_get_enum purple_value_get_enum
30.2269 -#define gaim_value_get_boxed purple_value_get_boxed
30.2270 -
30.2271 -/* from version.h */
30.2272 -
30.2273 -#define GAIM_MAJOR_VERSION PURPLE_MAJOR_VERSION
30.2274 -#define GAIM_MINOR_VERSION PURPLE_MINOR_VERSION
30.2275 -#define GAIM_MICRO_VERSION PURPLE_MICRO_VERSION
30.2276 -
30.2277 -#define GAIM_VERSION_CHECK PURPLE_VERSION_CHECK
30.2278 -
30.2279 -/* from whiteboard.h */
30.2280 -
30.2281 -#define GaimWhiteboardPrplOps PurpleWhiteboardPrplOps
30.2282 -#define GaimWhiteboard PurpleWhiteboard
30.2283 -#define GaimWhiteboardUiOps PurpleWhiteboardUiOps
30.2284 -
30.2285 -#define gaim_whiteboard_set_ui_ops purple_whiteboard_set_ui_ops
30.2286 -#define gaim_whiteboard_set_prpl_ops purple_whiteboard_set_prpl_ops
30.2287 -
30.2288 -#define gaim_whiteboard_create purple_whiteboard_create
30.2289 -#define gaim_whiteboard_destroy purple_whiteboard_destroy
30.2290 -#define gaim_whiteboard_start purple_whiteboard_start
30.2291 -#define gaim_whiteboard_get_session purple_whiteboard_get_session
30.2292 -#define gaim_whiteboard_draw_list_destroy purple_whiteboard_draw_list_destroy
30.2293 -#define gaim_whiteboard_get_dimensions purple_whiteboard_get_dimensions
30.2294 -#define gaim_whiteboard_set_dimensions purple_whiteboard_set_dimensions
30.2295 -#define gaim_whiteboard_draw_point purple_whiteboard_draw_point
30.2296 -#define gaim_whiteboard_send_draw_list purple_whiteboard_send_draw_list
30.2297 -#define gaim_whiteboard_draw_line purple_whiteboard_draw_line
30.2298 -#define gaim_whiteboard_clear purple_whiteboard_clear
30.2299 -#define gaim_whiteboard_send_clear purple_whiteboard_send_clear
30.2300 -#define gaim_whiteboard_send_brush purple_whiteboard_send_brush
30.2301 -#define gaim_whiteboard_get_brush purple_whiteboard_get_brush
30.2302 -#define gaim_whiteboard_set_brush purple_whiteboard_set_brush
30.2303 -
30.2304 -/* for static plugins */
30.2305 -#define gaim_init_ssl_plugin purple_init_ssl_plugin
30.2306 -#define gaim_init_ssl_openssl_plugin purple_init_ssl_openssl_plugin
30.2307 -#define gaim_init_ssl_gnutls_plugin purple_init_ssl_gnutls_plugin
30.2308 -#define gaim_init_gg_plugin purple_init_gg_plugin
30.2309 -#define gaim_init_jabber_plugin purple_init_jabber_plugin
30.2310 -#define gaim_init_sametime_plugin purple_init_sametime_plugin
30.2311 -#define gaim_init_msn_plugin purple_init_msn_plugin
30.2312 -#define gaim_init_novell_plugin purple_init_novell_plugin
30.2313 -#define gaim_init_qq_plugin purple_init_qq_plugin
30.2314 -#define gaim_init_simple_plugin purple_init_simple_plugin
30.2315 -#define gaim_init_yahoo_plugin purple_init_yahoo_plugin
30.2316 -#define gaim_init_zephyr_plugin purple_init_zephyr_plugin
30.2317 -#define gaim_init_aim_plugin purple_init_aim_plugin
30.2318 -#define gaim_init_icq_plugin purple_init_icq_plugin
30.2319 -
30.2320 -#endif /* _GAIM_COMPAT_H_ */
31.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/gg.h Sun Jun 21 22:04:11 2009 -0400
31.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
31.3 @@ -1,71 +0,0 @@
31.4 -/**
31.5 - * @file gg.h
31.6 - *
31.7 - * purple
31.8 - *
31.9 - * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
31.10 - *
31.11 - * This program is free software; you can redistribute it and/or modify
31.12 - * it under the terms of the GNU General Public License as published by
31.13 - * the Free Software Foundation; either version 2 of the License, or
31.14 - * (at your option) any later version.
31.15 - *
31.16 - * This program is distributed in the hope that it will be useful,
31.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
31.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
31.19 - * GNU General Public License for more details.
31.20 - *
31.21 - * You should have received a copy of the GNU General Public License
31.22 - * along with this program; if not, write to the Free Software
31.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
31.24 - */
31.25 -
31.26 -
31.27 -#ifndef _PURPLE_GG_H
31.28 -#define _PURPLE_GG_H
31.29 -
31.30 -#include <libgadu.h>
31.31 -#include "internal.h"
31.32 -#include "search.h"
31.33 -#include "connection.h"
31.34 -
31.35 -
31.36 -#define PUBDIR_RESULTS_MAX 20
31.37 -
31.38 -
31.39 -typedef struct
31.40 -{
31.41 - char *name;
31.42 - GList *participants;
31.43 -
31.44 -} GGPChat;
31.45 -
31.46 -typedef void (*GGPTokenCallback)(PurpleConnection *);
31.47 -
31.48 -typedef struct
31.49 -{
31.50 - char *id;
31.51 - char *data;
31.52 - unsigned int size;
31.53 -
31.54 - struct gg_http *req;
31.55 - guint inpa;
31.56 -
31.57 - GGPTokenCallback cb;
31.58 -
31.59 -} GGPToken;
31.60 -
31.61 -typedef struct {
31.62 -
31.63 - struct gg_session *session;
31.64 - GGPToken *token;
31.65 - GList *chats;
31.66 - GGPSearches *searches;
31.67 - int chats_count;
31.68 - GList *pending_richtext_messages;
31.69 - GHashTable *pending_images;
31.70 -} GGPInfo;
31.71 -
31.72 -#endif /* _PURPLE_GG_H */
31.73 -
31.74 -/* vim: set ts=8 sts=0 sw=8 noet: */
32.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/group.h Sun Jun 21 22:04:11 2009 -0400
32.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
32.3 @@ -1,110 +0,0 @@
32.4 -/**
32.5 - * @file group.h Group functions
32.6 - *
32.7 - * purple
32.8 - *
32.9 - * Purple is the legal property of its developers, whose names are too numerous
32.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
32.11 - * source distribution.
32.12 - *
32.13 - * This program is free software; you can redistribute it and/or modify
32.14 - * it under the terms of the GNU General Public License as published by
32.15 - * the Free Software Foundation; either version 2 of the License, or
32.16 - * (at your option) any later version.
32.17 - *
32.18 - * This program is distributed in the hope that it will be useful,
32.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
32.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
32.21 - * GNU General Public License for more details.
32.22 - *
32.23 - * You should have received a copy of the GNU General Public License
32.24 - * along with this program; if not, write to the Free Software
32.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
32.26 - */
32.27 -#ifndef _MSN_GROUP_H_
32.28 -#define _MSN_GROUP_H_
32.29 -
32.30 -typedef struct _MsnGroup MsnGroup;
32.31 -
32.32 -#include <stdio.h>
32.33 -
32.34 -#include "session.h"
32.35 -#include "user.h"
32.36 -#include "userlist.h"
32.37 -
32.38 -#define MSN_INDIVIDUALS_GROUP_ID "1983"
32.39 -#define MSN_INDIVIDUALS_GROUP_NAME _("Other Contacts")
32.40 -
32.41 -#define MSN_NON_IM_GROUP_ID "email"
32.42 -#define MSN_NON_IM_GROUP_NAME _("Non-IM Contacts")
32.43 -
32.44 -/**
32.45 - * A group.
32.46 - */
32.47 -struct _MsnGroup
32.48 -{
32.49 - MsnSession *session; /**< The MSN session. */
32.50 -
32.51 - char *id; /**< The group ID. */
32.52 - char *name; /**< The name of the group. */
32.53 -};
32.54 -
32.55 -/**************************************************************************
32.56 - ** @name Group API *
32.57 - **************************************************************************/
32.58 -/*@{*/
32.59 -
32.60 -/**
32.61 - * Creates a new group structure.
32.62 - *
32.63 - * @param session The MSN session.
32.64 - * @param id The group ID.
32.65 - * @param name The name of the group.
32.66 - *
32.67 - * @return A new group structure.
32.68 - */
32.69 -MsnGroup *msn_group_new(MsnUserList *userlist, const char *id, const char *name);
32.70 -
32.71 -/**
32.72 - * Destroys a group structure.
32.73 - *
32.74 - * @param group The group to destroy.
32.75 - */
32.76 -void msn_group_destroy(MsnGroup *group);
32.77 -
32.78 -/**
32.79 - * Sets the ID for a group.
32.80 - *
32.81 - * @param group The group.
32.82 - * @param id The ID.
32.83 - */
32.84 -void msn_group_set_id(MsnGroup *group, const char *id);
32.85 -
32.86 -/**
32.87 - * Sets the name for a group.
32.88 - *
32.89 - * @param group The group.
32.90 - * @param name The name.
32.91 - */
32.92 -void msn_group_set_name(MsnGroup *group, const char *name);
32.93 -
32.94 -/**
32.95 - * Returns the ID for a group.
32.96 - *
32.97 - * @param group The group.
32.98 - *
32.99 - * @return The ID.
32.100 - */
32.101 -char* msn_group_get_id(const MsnGroup *group);
32.102 -
32.103 -/**
32.104 - * Returns the name for a group.
32.105 - *
32.106 - * @param group The group.
32.107 - *
32.108 - * @return The name.
32.109 - */
32.110 -const char *msn_group_get_name(const MsnGroup *group);
32.111 -
32.112 -#endif /* _MSN_GROUP_H_ */
32.113 -
33.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/history.h Sun Jun 21 22:04:11 2009 -0400
33.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
33.3 @@ -1,47 +0,0 @@
33.4 -/**
33.5 - * @file history.h MSN history functions
33.6 - *
33.7 - * purple
33.8 - *
33.9 - * Purple is the legal property of its developers, whose names are too numerous
33.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
33.11 - * source distribution.
33.12 - *
33.13 - * This program is free software; you can redistribute it and/or modify
33.14 - * it under the terms of the GNU General Public License as published by
33.15 - * the Free Software Foundation; either version 2 of the License, or
33.16 - * (at your option) any later version.
33.17 - *
33.18 - * This program is distributed in the hope that it will be useful,
33.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
33.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
33.21 - * GNU General Public License for more details.
33.22 - *
33.23 - * You should have received a copy of the GNU General Public License
33.24 - * along with this program; if not, write to the Free Software
33.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
33.26 - */
33.27 -#ifndef _MSN_HISTORY_H
33.28 -#define _MSN_HISTORY_H
33.29 -
33.30 -#define MSN_HIST_ELEMS 0x30
33.31 -
33.32 -typedef struct _MsnHistory MsnHistory;
33.33 -
33.34 -#include "transaction.h"
33.35 -
33.36 -/**
33.37 - * The history.
33.38 - */
33.39 -struct _MsnHistory
33.40 -{
33.41 - GQueue *queue;
33.42 - unsigned int trId;
33.43 -};
33.44 -
33.45 -MsnHistory *msn_history_new(void);
33.46 -void msn_history_destroy(MsnHistory *history);
33.47 -MsnTransaction *msn_history_find(MsnHistory *history, unsigned int triId);
33.48 -void msn_history_add(MsnHistory *history, MsnTransaction *trans);
33.49 -
33.50 -#endif /* _MSN_HISTORY_H */
34.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/httpconn.h Sun Jun 21 22:04:11 2009 -0400
34.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
34.3 @@ -1,111 +0,0 @@
34.4 -/**
34.5 - * @file httpconn.h HTTP connection
34.6 - *
34.7 - * purple
34.8 - *
34.9 - * Purple is the legal property of its developers, whose names are too numerous
34.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
34.11 - * source distribution.
34.12 - *
34.13 - * This program is free software; you can redistribute it and/or modify
34.14 - * it under the terms of the GNU General Public License as published by
34.15 - * the Free Software Foundation; either version 2 of the License, or
34.16 - * (at your option) any later version.
34.17 - *
34.18 - * This program is distributed in the hope that it will be useful,
34.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
34.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
34.21 - * GNU General Public License for more details.
34.22 - *
34.23 - * You should have received a copy of the GNU General Public License
34.24 - * along with this program; if not, write to the Free Software
34.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
34.26 - */
34.27 -#ifndef _MSN_HTTPCONN_H_
34.28 -#define _MSN_HTTPCONN_H_
34.29 -
34.30 -typedef struct _MsnHttpConn MsnHttpConn;
34.31 -
34.32 -#include "circbuffer.h"
34.33 -#include "servconn.h"
34.34 -
34.35 -/**
34.36 - * An HTTP Connection.
34.37 - */
34.38 -struct _MsnHttpConn
34.39 -{
34.40 - MsnSession *session; /**< The MSN Session. */
34.41 - MsnServConn *servconn; /**< The connection object. */
34.42 -
34.43 - PurpleProxyConnectData *connect_data;
34.44 -
34.45 - char *full_session_id; /**< The full session id. */
34.46 - char *session_id; /**< The trimmed session id. */
34.47 -
34.48 - int timer; /**< The timer for polling. */
34.49 -
34.50 - gboolean waiting_response; /**< The flag that states if we are waiting
34.51 - a response from the server. */
34.52 - gboolean connected; /**< The flag that states if the connection is on. */
34.53 - gboolean virgin; /**< The flag that states if this connection
34.54 - should specify the host (not gateway) to
34.55 - connect to. */
34.56 -
34.57 - char *host; /**< The HTTP gateway host. */
34.58 - GList *queue; /**< The queue of data chunks to write. */
34.59 -
34.60 - int fd; /**< The connection's file descriptor. */
34.61 - guint inpa; /**< The connection's input handler. */
34.62 -
34.63 - char *rx_buf; /**< The receive buffer. */
34.64 - int rx_len; /**< The receive buffer length. */
34.65 -
34.66 - PurpleCircBuffer *tx_buf;
34.67 - guint tx_handler;
34.68 -};
34.69 -
34.70 -/**
34.71 - * Creates a new HTTP connection object.
34.72 - *
34.73 - * @param servconn The connection object.
34.74 - *
34.75 - * @return The new object.
34.76 - */
34.77 -MsnHttpConn *msn_httpconn_new(MsnServConn *servconn);
34.78 -
34.79 -/**
34.80 - * Destroys an HTTP connection object.
34.81 - *
34.82 - * @param httpconn The HTTP connection object.
34.83 - */
34.84 -void msn_httpconn_destroy(MsnHttpConn *httpconn);
34.85 -
34.86 -/**
34.87 - * Writes a chunk of data to the HTTP connection.
34.88 - *
34.89 - * @param servconn The server connection.
34.90 - * @param data The data to write.
34.91 - * @param data_len The size of the data to write.
34.92 - *
34.93 - * @return The number of bytes written.
34.94 - */
34.95 -gssize msn_httpconn_write(MsnHttpConn *httpconn, const char *data, size_t data_len);
34.96 -
34.97 -/**
34.98 - * Connects the HTTP connection object to a host.
34.99 - *
34.100 - * @param httpconn The HTTP connection object.
34.101 - * @param host The host to connect to.
34.102 - * @param port The port to connect to.
34.103 - */
34.104 -gboolean msn_httpconn_connect(MsnHttpConn *httpconn,
34.105 - const char *host, int port);
34.106 -
34.107 -/**
34.108 - * Disconnects the HTTP connection object.
34.109 - *
34.110 - * @param httpconn The HTTP connection object.
34.111 - */
34.112 -void msn_httpconn_disconnect(MsnHttpConn *httpconn);
34.113 -
34.114 -#endif /* _MSN_HTTPCONN_H_ */
35.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/idle.h Sun Jun 21 22:04:11 2009 -0400
35.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
35.3 @@ -1,102 +0,0 @@
35.4 -/**
35.5 - * @file idle.h Idle API
35.6 - * @ingroup core
35.7 - */
35.8 -
35.9 -/* purple
35.10 - *
35.11 - * Purple is the legal property of its developers, whose names are too numerous
35.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
35.13 - * source distribution.
35.14 - *
35.15 - * This program is free software; you can redistribute it and/or modify
35.16 - * it under the terms of the GNU General Public License as published by
35.17 - * the Free Software Foundation; either version 2 of the License, or
35.18 - * (at your option) any later version.
35.19 - *
35.20 - * This program is distributed in the hope that it will be useful,
35.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
35.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
35.23 - * GNU General Public License for more details.
35.24 - *
35.25 - * You should have received a copy of the GNU General Public License
35.26 - * along with this program; if not, write to the Free Software
35.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
35.28 - */
35.29 -#ifndef _PURPLE_IDLE_H_
35.30 -#define _PURPLE_IDLE_H_
35.31 -
35.32 -/**
35.33 - * Idle UI operations.
35.34 - */
35.35 -typedef struct
35.36 -{
35.37 - time_t (*get_time_idle)(void);
35.38 -
35.39 - void (*_purple_reserved1)(void);
35.40 - void (*_purple_reserved2)(void);
35.41 - void (*_purple_reserved3)(void);
35.42 - void (*_purple_reserved4)(void);
35.43 -} PurpleIdleUiOps;
35.44 -
35.45 -#ifdef __cplusplus
35.46 -extern "C" {
35.47 -#endif
35.48 -
35.49 -/**************************************************************************/
35.50 -/** @name Idle API */
35.51 -/**************************************************************************/
35.52 -/*@{*/
35.53 -
35.54 -/**
35.55 - * Touch our idle tracker. This signifies that the user is
35.56 - * 'active'. The conversation code calls this when the
35.57 - * user sends an IM, for example.
35.58 - */
35.59 -void purple_idle_touch(void);
35.60 -
35.61 -/**
35.62 - * Fake our idle time by setting the time at which our
35.63 - * accounts purportedly became idle. This is used by
35.64 - * the I'dle Mak'er plugin.
35.65 - */
35.66 -void purple_idle_set(time_t time);
35.67 -
35.68 -/*@}*/
35.69 -
35.70 -/**************************************************************************/
35.71 -/** @name Idle Subsystem */
35.72 -/**************************************************************************/
35.73 -/*@{*/
35.74 -
35.75 -/**
35.76 - * Sets the UI operations structure to be used for idle reporting.
35.77 - *
35.78 - * @param ops The UI operations structure.
35.79 - */
35.80 -void purple_idle_set_ui_ops(PurpleIdleUiOps *ops);
35.81 -
35.82 -/**
35.83 - * Returns the UI operations structure used for idle reporting.
35.84 - *
35.85 - * @return The UI operations structure in use.
35.86 - */
35.87 -PurpleIdleUiOps *purple_idle_get_ui_ops(void);
35.88 -
35.89 -/**
35.90 - * Initializes the idle system.
35.91 - */
35.92 -void purple_idle_init(void);
35.93 -
35.94 -/**
35.95 - * Uninitializes the idle system.
35.96 - */
35.97 -void purple_idle_uninit(void);
35.98 -
35.99 -/*@}*/
35.100 -
35.101 -#ifdef __cplusplus
35.102 -}
35.103 -#endif
35.104 -
35.105 -#endif /* _PURPLE_IDLE_H_ */
36.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/imgstore.h Sun Jun 21 22:04:11 2009 -0400
36.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
36.3 @@ -1,214 +0,0 @@
36.4 -/**
36.5 - * @file imgstore.h IM Image Store API
36.6 - * @ingroup core
36.7 - * @see @ref imgstore-signals
36.8 - */
36.9 -
36.10 -/* purple
36.11 - *
36.12 - * Purple is the legal property of its developers, whose names are too numerous
36.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
36.14 - * source distribution.
36.15 - *
36.16 - * This program is free software; you can redistribute it and/or modify
36.17 - * it under the terms of the GNU General Public License as published by
36.18 - * the Free Software Foundation; either version 2 of the License, or
36.19 - * (at your option) any later version.
36.20 - *
36.21 - * This program is distributed in the hope that it will be useful,
36.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
36.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
36.24 - * GNU General Public License for more details.
36.25 - *
36.26 - * You should have received a copy of the GNU General Public License
36.27 - * along with this program; if not, write to the Free Software
36.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
36.29 - */
36.30 -#ifndef _PURPLE_IMGSTORE_H_
36.31 -#define _PURPLE_IMGSTORE_H_
36.32 -
36.33 -#include <glib.h>
36.34 -
36.35 -/** A reference-counted immutable wrapper around an image's data and its
36.36 - * filename.
36.37 - */
36.38 -typedef struct _PurpleStoredImage PurpleStoredImage;
36.39 -
36.40 -#ifdef __cplusplus
36.41 -extern "C" {
36.42 -#endif
36.43 -
36.44 -/**
36.45 - * Add an image to the store.
36.46 - *
36.47 - * The caller owns a reference to the image in the store, and must dereference
36.48 - * the image with purple_imgstore_unref() for it to be freed.
36.49 - *
36.50 - * No ID is allocated when using this function. If you need to reference the
36.51 - * image by an ID, use purple_imgstore_add_with_id() instead.
36.52 - *
36.53 - * @param data Pointer to the image data, which the imgstore will take
36.54 - * ownership of and free as appropriate. If you want a
36.55 - * copy of the data, make it before calling this function.
36.56 - * @param size Image data's size.
36.57 - * @param filename Filename associated with image. This is for your
36.58 - * convenience. It could be the full path to the
36.59 - * image or, more commonly, the filename of the image
36.60 - * without any directory information. It can also be
36.61 - * NULL, if you don't need to keep track of a filename.
36.62 - *
36.63 - * @return The stored image.
36.64 - */
36.65 -PurpleStoredImage *
36.66 -purple_imgstore_add(gpointer data, size_t size, const char *filename);
36.67 -
36.68 -/**
36.69 - * Create an image and add it to the store.
36.70 - *
36.71 - * @param path The path to the image.
36.72 - *
36.73 - * @return The stored image.
36.74 - * @since 2.X.X
36.75 - */
36.76 -PurpleStoredImage *
36.77 -purple_imgstore_new_from_file(const char *path);
36.78 -
36.79 -/**
36.80 - * Add an image to the store, allocating an ID.
36.81 - *
36.82 - * The caller owns a reference to the image in the store, and must dereference
36.83 - * the image with purple_imgstore_unref_by_id() or purple_imgstore_unref()
36.84 - * for it to be freed.
36.85 - *
36.86 - * @param data Pointer to the image data, which the imgstore will take
36.87 - * ownership of and free as appropriate. If you want a
36.88 - * copy of the data, make it before calling this function.
36.89 - * @param size Image data's size.
36.90 - * @param filename Filename associated with image. This is for your
36.91 - * convenience. It could be the full path to the
36.92 - * image or, more commonly, the filename of the image
36.93 - * without any directory information. It can also be
36.94 - * NULL, if you don't need to keep track of a filename.
36.95 -
36.96 - * @return ID for the image. This is a unique number that can be used
36.97 - * within libpurple to reference the image.
36.98 - */
36.99 -int purple_imgstore_add_with_id(gpointer data, size_t size, const char *filename);
36.100 -
36.101 -/**
36.102 - * Retrieve an image from the store. The caller does not own a
36.103 - * reference to the image.
36.104 - *
36.105 - * @param id The ID for the image.
36.106 - *
36.107 - * @return A pointer to the requested image, or NULL if it was not found.
36.108 - */
36.109 -PurpleStoredImage *purple_imgstore_find_by_id(int id);
36.110 -
36.111 -/**
36.112 - * Retrieves a pointer to the image's data.
36.113 - *
36.114 - * @param img The Image
36.115 - *
36.116 - * @return A pointer to the data, which must not
36.117 - * be freed or modified.
36.118 - */
36.119 -gconstpointer purple_imgstore_get_data(PurpleStoredImage *img);
36.120 -
36.121 -/**
36.122 - * Retrieves the length of the image's data.
36.123 - *
36.124 - * @param img The Image
36.125 - *
36.126 - * @return The size of the data that the pointer returned by
36.127 - * purple_imgstore_get_data points to.
36.128 - */
36.129 -size_t purple_imgstore_get_size(PurpleStoredImage *img);
36.130 -
36.131 -/**
36.132 - * Retrieves a pointer to the image's filename.
36.133 - *
36.134 - * @param img The image
36.135 - *
36.136 - * @return A pointer to the filename, which must not
36.137 - * be freed or modified.
36.138 - */
36.139 -const char *purple_imgstore_get_filename(const PurpleStoredImage *img);
36.140 -
36.141 -/**
36.142 - * Looks at the magic numbers of the image data (the first few bytes)
36.143 - * and returns an extension corresponding to the image's file type.
36.144 - *
36.145 - * @param img The image.
36.146 - *
36.147 - * @return The image's extension (for example "png") or "icon"
36.148 - * if unknown.
36.149 - */
36.150 -const char *purple_imgstore_get_extension(PurpleStoredImage *img);
36.151 -
36.152 -/**
36.153 - * Increment the reference count.
36.154 - *
36.155 - * @param img The image.
36.156 - *
36.157 - * @return @a img
36.158 - */
36.159 -PurpleStoredImage *
36.160 -purple_imgstore_ref(PurpleStoredImage *img);
36.161 -
36.162 -/**
36.163 - * Decrement the reference count.
36.164 - *
36.165 - * If the reference count reaches zero, the image will be freed.
36.166 - *
36.167 - * @param img The image.
36.168 - *
36.169 - * @return @a img or @c NULL if the reference count reached zero.
36.170 - */
36.171 -PurpleStoredImage *
36.172 -purple_imgstore_unref(PurpleStoredImage *img);
36.173 -
36.174 -/**
36.175 - * Increment the reference count using an ID.
36.176 - *
36.177 - * This is a convience wrapper for purple_imgstore_find_by_id() and
36.178 - * purple_imgstore_ref(), so if you have a PurpleStoredImage, it'll
36.179 - * be more efficient to call purple_imgstore_ref() directly.
36.180 - *
36.181 - * @param id The ID for the image.
36.182 - */
36.183 -void purple_imgstore_ref_by_id(int id);
36.184 -
36.185 -/**
36.186 - * Decrement the reference count using an ID.
36.187 - *
36.188 - * This is a convience wrapper for purple_imgstore_find_by_id() and
36.189 - * purple_imgstore_unref(), so if you have a PurpleStoredImage, it'll
36.190 - * be more efficient to call purple_imgstore_unref() directly.
36.191 - *
36.192 - * @param id The ID for the image.
36.193 - */
36.194 -void purple_imgstore_unref_by_id(int id);
36.195 -
36.196 -/**
36.197 - * Returns the image store subsystem handle.
36.198 - *
36.199 - * @return The subsystem handle.
36.200 - */
36.201 -void *purple_imgstore_get_handle(void);
36.202 -
36.203 -/**
36.204 - * Initializes the image store subsystem.
36.205 - */
36.206 -void purple_imgstore_init(void);
36.207 -
36.208 -/**
36.209 - * Uninitializes the image store subsystem.
36.210 - */
36.211 -void purple_imgstore_uninit(void);
36.212 -
36.213 -#ifdef __cplusplus
36.214 -}
36.215 -#endif
36.216 -
36.217 -#endif /* _PURPLE_IMGSTORE_H_ */
37.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/internal.h Sun Jun 21 22:04:11 2009 -0400
37.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
37.3 @@ -1,300 +0,0 @@
37.4 -/**
37.5 - * @file internal.h Internal definitions and includes
37.6 - * @ingroup core
37.7 - */
37.8 -
37.9 -/* purple
37.10 - *
37.11 - * Purple is the legal property of its developers, whose names are too numerous
37.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
37.13 - * source distribution.
37.14 - *
37.15 - * This program is free software; you can redistribute it and/or modify
37.16 - * it under the terms of the GNU General Public License as published by
37.17 - * the Free Software Foundation; either version 2 of the License, or
37.18 - * (at your option) any later version.
37.19 - *
37.20 - * This program is distributed in the hope that it will be useful,
37.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
37.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
37.23 - * GNU General Public License for more details.
37.24 - *
37.25 - * You should have received a copy of the GNU General Public License
37.26 - * along with this program; if not, write to the Free Software
37.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
37.28 - */
37.29 -#ifndef _PURPLE_INTERNAL_H_
37.30 -#define _PURPLE_INTERNAL_H_
37.31 -
37.32 -#ifdef HAVE_CONFIG_H
37.33 -# include <config.h>
37.34 -#endif
37.35 -
37.36 -/* for SIOCGIFCONF in SKYOS */
37.37 -#ifdef SKYOS
37.38 -#include <net/sockios.h>
37.39 -#endif
37.40 -/*
37.41 - * If we're using NLS, make sure gettext works. If not, then define
37.42 - * dummy macros in place of the normal gettext macros.
37.43 - *
37.44 - * Also, the perl XS config.h file sometimes defines _ So we need to
37.45 - * make sure _ isn't already defined before trying to define it.
37.46 - *
37.47 - * The Singular/Plural/Number ngettext dummy definition below was
37.48 - * taken from an email to the texinfo mailing list by Manuel Guerrero.
37.49 - * Thank you Manuel, and thank you Alex's good friend Google.
37.50 - */
37.51 -#ifdef ENABLE_NLS
37.52 -# include <locale.h>
37.53 -# include <libintl.h>
37.54 -# define _(String) ((const char *)dgettext(PACKAGE, String))
37.55 -# ifdef gettext_noop
37.56 -# define N_(String) gettext_noop (String)
37.57 -# else
37.58 -# define N_(String) (String)
37.59 -# endif
37.60 -#else
37.61 -# include <locale.h>
37.62 -# define N_(String) (String)
37.63 -# ifndef _
37.64 -# define _(String) ((const char *)String)
37.65 -# endif
37.66 -# define ngettext(Singular, Plural, Number) ((Number == 1) ? ((const char *)Singular) : ((const char *)Plural))
37.67 -# define dngettext(Domain, Singular, Plural, Number) ((Number == 1) ? ((const char *)Singular) : ((const char *)Plural))
37.68 -#endif
37.69 -
37.70 -#ifdef HAVE_ENDIAN_H
37.71 -# include <endian.h>
37.72 -#endif
37.73 -
37.74 -#define MSG_LEN 2048
37.75 -/* The above should normally be the same as BUF_LEN,
37.76 - * but just so we're explicitly asking for the max message
37.77 - * length. */
37.78 -#define BUF_LEN MSG_LEN
37.79 -#define BUF_LONG BUF_LEN * 2
37.80 -
37.81 -#include <sys/stat.h>
37.82 -#include <sys/types.h>
37.83 -#ifndef _WIN32
37.84 -#include <sys/time.h>
37.85 -#include <sys/wait.h>
37.86 -#include <sys/time.h>
37.87 -#endif
37.88 -#include <ctype.h>
37.89 -#include <errno.h>
37.90 -#include <fcntl.h>
37.91 -#include <math.h>
37.92 -#include <stdio.h>
37.93 -#include <stdlib.h>
37.94 -#include <string.h>
37.95 -#include <time.h>
37.96 -
37.97 -#ifdef HAVE_ICONV
37.98 -#include <iconv.h>
37.99 -#endif
37.100 -
37.101 -#ifdef HAVE_LANGINFO_CODESET
37.102 -#include <langinfo.h>
37.103 -#endif
37.104 -
37.105 -#include <gmodule.h>
37.106 -
37.107 -#ifdef PURPLE_PLUGINS
37.108 -# ifdef HAVE_DLFCN_H
37.109 -# include <dlfcn.h>
37.110 -# endif
37.111 -#endif
37.112 -
37.113 -#ifndef _WIN32
37.114 -# include <netinet/in.h>
37.115 -# include <sys/socket.h>
37.116 -# include <arpa/inet.h>
37.117 -# include <sys/un.h>
37.118 -# include <sys/utsname.h>
37.119 -# include <netdb.h>
37.120 -# include <signal.h>
37.121 -# include <unistd.h>
37.122 -#endif
37.123 -
37.124 -/* MAXPATHLEN should only be used with readlink() on glib < 2.4.0. For
37.125 - * anything else, use g_file_read_link() or other dynamic functions. This is
37.126 - * important because Hurd has no hard limits on path length. */
37.127 -#if !GLIB_CHECK_VERSION(2,4,0)
37.128 -# ifndef MAXPATHLEN
37.129 -# ifdef PATH_MAX
37.130 -# define MAXPATHLEN PATH_MAX
37.131 -# else
37.132 -# define MAXPATHLEN 1024
37.133 -# endif
37.134 -# endif
37.135 -#endif
37.136 -
37.137 -#ifndef HOST_NAME_MAX
37.138 -# define HOST_NAME_MAX 255
37.139 -#endif
37.140 -
37.141 -#include <glib.h>
37.142 -#if !GLIB_CHECK_VERSION(2,4,0)
37.143 -# define G_MAXUINT32 ((guint32) 0xffffffff)
37.144 -#endif
37.145 -
37.146 -#ifndef G_MAXSIZE
37.147 -# if GLIB_SIZEOF_LONG == 8
37.148 -# define G_MAXSIZE ((gsize) 0xffffffffffffffff)
37.149 -# else
37.150 -# define G_MAXSIZE ((gsize) 0xffffffff)
37.151 -# endif
37.152 -#endif
37.153 -
37.154 -#if GLIB_CHECK_VERSION(2,6,0)
37.155 -# include <glib/gstdio.h>
37.156 -#endif
37.157 -
37.158 -#if !GLIB_CHECK_VERSION(2,6,0)
37.159 -# define g_freopen freopen
37.160 -# define g_fopen fopen
37.161 -# define g_rmdir rmdir
37.162 -# define g_remove remove
37.163 -# define g_unlink unlink
37.164 -# define g_lstat lstat
37.165 -# define g_stat stat
37.166 -# define g_mkdir mkdir
37.167 -# define g_rename rename
37.168 -# define g_open open
37.169 -#endif
37.170 -
37.171 -#if !GLIB_CHECK_VERSION(2,8,0) && !defined _WIN32
37.172 -# define g_access access
37.173 -#endif
37.174 -
37.175 -#if !GLIB_CHECK_VERSION(2,10,0)
37.176 -# define g_slice_new(type) g_new(type, 1)
37.177 -# define g_slice_new0(type) g_new0(type, 1)
37.178 -# define g_slice_free(type, mem) g_free(mem)
37.179 -#endif
37.180 -
37.181 -#ifdef _WIN32
37.182 -#include "win32dep.h"
37.183 -#endif
37.184 -
37.185 -/* ugly ugly ugly */
37.186 -/* This is a workaround for the fact that G_GINT64_MODIFIER and G_GSIZE_FORMAT
37.187 - * are only defined in Glib >= 2.4 */
37.188 -#ifndef G_GINT64_MODIFIER
37.189 -# if GLIB_SIZEOF_LONG == 8
37.190 -# define G_GINT64_MODIFIER "l"
37.191 -# else
37.192 -# define G_GINT64_MODIFIER "ll"
37.193 -# endif
37.194 -#endif
37.195 -
37.196 -#ifndef G_GSIZE_MODIFIER
37.197 -# if GLIB_SIZEOF_LONG == 8
37.198 -# define G_GSIZE_MODIFIER "l"
37.199 -# else
37.200 -# define G_GSIZE_MODIFIER ""
37.201 -# endif
37.202 -#endif
37.203 -
37.204 -#ifndef G_GSIZE_FORMAT
37.205 -# if GLIB_SIZEOF_LONG == 8
37.206 -# define G_GSIZE_FORMAT "lu"
37.207 -# else
37.208 -# define G_GSIZE_FORMAT "u"
37.209 -# endif
37.210 -#endif
37.211 -
37.212 -#ifndef G_GSSIZE_FORMAT
37.213 -# if GLIB_SIZEOF_LONG == 8
37.214 -# define G_GSSIZE_FORMAT "li"
37.215 -# else
37.216 -# define G_GSSIZE_FORMAT "i"
37.217 -# endif
37.218 -#endif
37.219 -
37.220 -#ifndef G_GNUC_NULL_TERMINATED
37.221 -# if __GNUC__ >= 4
37.222 -# define G_GNUC_NULL_TERMINATED __attribute__((__sentinel__))
37.223 -# else
37.224 -# define G_GNUC_NULL_TERMINATED
37.225 -# endif
37.226 -#endif
37.227 -
37.228 -/* Safer ways to work with static buffers. When using non-static
37.229 - * buffers, either use g_strdup_* functions (preferred) or use
37.230 - * g_strlcpy/g_strlcpy directly. */
37.231 -#define purple_strlcpy(dest, src) g_strlcpy(dest, src, sizeof(dest))
37.232 -#define purple_strlcat(dest, src) g_strlcat(dest, src, sizeof(dest))
37.233 -
37.234 -#define PURPLE_WEBSITE "http://pidgin.im/"
37.235 -#define PURPLE_DEVEL_WEBSITE "http://developer.pidgin.im/"
37.236 -
37.237 -
37.238 -/* INTERNAL FUNCTIONS */
37.239 -
37.240 -#include "account.h"
37.241 -#include "connection.h"
37.242 -
37.243 -/* This is for the accounts code to notify the buddy icon code that
37.244 - * it's done loading. We may want to replace this with a signal. */
37.245 -void
37.246 -_purple_buddy_icons_account_loaded_cb(void);
37.247 -
37.248 -/* This is for the buddy list to notify the buddy icon code that
37.249 - * it's done loading. We may want to replace this with a signal. */
37.250 -void
37.251 -_purple_buddy_icons_blist_loaded_cb(void);
37.252 -
37.253 -/* This is for the purple_core_migrate() code to tell the buddy
37.254 - * icon subsystem about the old icons directory so it can
37.255 - * migrate any icons in use. */
37.256 -void
37.257 -_purple_buddy_icon_set_old_icons_dir(const char *dirname);
37.258 -
37.259 -/**
37.260 - * Creates a connection to the specified account and either connects
37.261 - * or attempts to register a new account. If you are logging in,
37.262 - * the connection uses the current active status for this account.
37.263 - * So if you want to sign on as "away," for example, you need to
37.264 - * have called purple_account_set_status(account, "away").
37.265 - * (And this will call purple_account_connect() automatically).
37.266 - *
37.267 - * @note This function should only be called by purple_account_connect()
37.268 - * in account.c. If you're trying to sign on an account, use that
37.269 - * function instead.
37.270 - *
37.271 - * @param account The account the connection should be connecting to.
37.272 - * @param regist Whether we are registering a new account or just
37.273 - * trying to do a normal signon.
37.274 - * @param password The password to use.
37.275 - */
37.276 -void _purple_connection_new(PurpleAccount *account, gboolean regist,
37.277 - const char *password);
37.278 -/**
37.279 - * Tries to unregister the account on the server. If the account is not
37.280 - * connected, also creates a new connection.
37.281 - *
37.282 - * @note This function should only be called by purple_account_unregister()
37.283 - * in account.c.
37.284 - *
37.285 - * @param account The account to unregister
37.286 - * @param password The password to use.
37.287 - * @param cb Optional callback to be called when unregistration is complete
37.288 - * @param user_data user data to pass to the callback
37.289 - */
37.290 -void _purple_connection_new_unregister(PurpleAccount *account, const char *password,
37.291 - PurpleAccountUnregistrationCb cb, void *user_data);
37.292 -/**
37.293 - * Disconnects and destroys a PurpleConnection.
37.294 - *
37.295 - * @note This function should only be called by purple_account_disconnect()
37.296 - * in account.c. If you're trying to sign off an account, use that
37.297 - * function instead.
37.298 - *
37.299 - * @param gc The purple connection to destroy.
37.300 - */
37.301 -void _purple_connection_destroy(PurpleConnection *gc);
37.302 -
37.303 -#endif /* _PURPLE_INTERNAL_H_ */
38.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/jabber.h Sun Jun 21 22:04:11 2009 -0400
38.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
38.3 @@ -1,315 +0,0 @@
38.4 -/**
38.5 - * @file jabber.h
38.6 - *
38.7 - * purple
38.8 - *
38.9 - * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
38.10 - *
38.11 - * This program is free software; you can redistribute it and/or modify
38.12 - * it under the terms of the GNU General Public License as published by
38.13 - * the Free Software Foundation; either version 2 of the License, or
38.14 - * (at your option) any later version.
38.15 - *
38.16 - * This program is distributed in the hope that it will be useful,
38.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
38.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
38.19 - * GNU General Public License for more details.
38.20 - *
38.21 - * You should have received a copy of the GNU General Public License
38.22 - * along with this program; if not, write to the Free Software
38.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
38.24 - */
38.25 -#ifndef _PURPLE_JABBER_H_
38.26 -#define _PURPLE_JABBER_H_
38.27 -
38.28 -typedef enum {
38.29 - JABBER_CAP_NONE = 0,
38.30 - JABBER_CAP_XHTML = 1 << 0,
38.31 - JABBER_CAP_COMPOSING = 1 << 1,
38.32 - JABBER_CAP_SI = 1 << 2,
38.33 - JABBER_CAP_SI_FILE_XFER = 1 << 3,
38.34 - JABBER_CAP_BYTESTREAMS = 1 << 4,
38.35 - JABBER_CAP_IBB = 1 << 5,
38.36 - JABBER_CAP_CHAT_STATES = 1 << 6,
38.37 - JABBER_CAP_IQ_SEARCH = 1 << 7,
38.38 - JABBER_CAP_IQ_REGISTER = 1 << 8,
38.39 -
38.40 - /* Google Talk extensions:
38.41 - * http://code.google.com/apis/talk/jep_extensions/extensions.html
38.42 - */
38.43 - JABBER_CAP_GMAIL_NOTIFY = 1 << 9,
38.44 - JABBER_CAP_GOOGLE_ROSTER = 1 << 10,
38.45 -
38.46 - JABBER_CAP_PING = 1 << 11,
38.47 - JABBER_CAP_ADHOC = 1 << 12,
38.48 - JABBER_CAP_BLOCKING = 1 << 13,
38.49 -
38.50 - JABBER_CAP_RETRIEVED = 1 << 31
38.51 -} JabberCapabilities;
38.52 -
38.53 -typedef struct _JabberStream JabberStream;
38.54 -
38.55 -#include <libxml/parser.h>
38.56 -#include <glib.h>
38.57 -#include "circbuffer.h"
38.58 -#include "connection.h"
38.59 -#include "dnssrv.h"
38.60 -#include "roomlist.h"
38.61 -#include "sslconn.h"
38.62 -
38.63 -#include "jutil.h"
38.64 -#include "xmlnode.h"
38.65 -#include "buddy.h"
38.66 -
38.67 -#ifdef HAVE_CYRUS_SASL
38.68 -#include <sasl/sasl.h>
38.69 -#endif
38.70 -
38.71 -#define CAPS0115_NODE "http://pidgin.im/caps"
38.72 -
38.73 -/* Index into attention_types list */
38.74 -#define JABBER_BUZZ 0
38.75 -
38.76 -typedef enum {
38.77 - JABBER_STREAM_OFFLINE,
38.78 - JABBER_STREAM_CONNECTING,
38.79 - JABBER_STREAM_INITIALIZING,
38.80 - JABBER_STREAM_INITIALIZING_ENCRYPTION,
38.81 - JABBER_STREAM_AUTHENTICATING,
38.82 - JABBER_STREAM_REINITIALIZING,
38.83 - JABBER_STREAM_CONNECTED
38.84 -} JabberStreamState;
38.85 -
38.86 -struct _JabberStream
38.87 -{
38.88 - int fd;
38.89 -
38.90 - PurpleSrvQueryData *srv_query_data;
38.91 -
38.92 - xmlParserCtxt *context;
38.93 - xmlnode *current;
38.94 -
38.95 - enum {
38.96 - JABBER_PROTO_0_9,
38.97 - JABBER_PROTO_1_0
38.98 - } protocol_version;
38.99 - enum {
38.100 - JABBER_AUTH_UNKNOWN,
38.101 - JABBER_AUTH_DIGEST_MD5,
38.102 - JABBER_AUTH_PLAIN,
38.103 - JABBER_AUTH_IQ_AUTH,
38.104 - JABBER_AUTH_CYRUS
38.105 - } auth_type;
38.106 - char *stream_id;
38.107 - JabberStreamState state;
38.108 -
38.109 - /* SASL authentication */
38.110 - char *expected_rspauth;
38.111 -
38.112 - GHashTable *buddies;
38.113 - gboolean roster_parsed;
38.114 -
38.115 - /*
38.116 - * This boolean was added to eliminate a heinous bug where we would
38.117 - * get into a loop with the server and move a buddy back and forth
38.118 - * from one group to another.
38.119 - *
38.120 - * The sequence goes something like this:
38.121 - * 1. Our resource and another resource both approve an authorization
38.122 - * request at the exact same time. We put the buddy in group A and
38.123 - * the other resource put the buddy in group B.
38.124 - * 2. The server receives the roster add for group B and sends us a
38.125 - * roster push.
38.126 - * 3. We receive this roster push and modify our local blist. This
38.127 - * triggers us to send a roster add for group B.
38.128 - * 4. The server recieves our earlier roster add for group A and sends
38.129 - * us a roster push.
38.130 - * 5. We receive this roster push and modify our local blist. This
38.131 - * triggers us to send a roster add for group A.
38.132 - * 6. The server receives our earlier roster add for group B and sends
38.133 - * us a roster push.
38.134 - * (repeat steps 3 through 6 ad infinitum)
38.135 - *
38.136 - * This boolean is used to short-circuit the sending of a roster add
38.137 - * when we receive a roster push.
38.138 - *
38.139 - * See these bug reports:
38.140 - * http://trac.adiumx.com/ticket/8834
38.141 - * http://developer.pidgin.im/ticket/5484
38.142 - * http://developer.pidgin.im/ticket/6188
38.143 - */
38.144 - gboolean currently_parsing_roster_push;
38.145 -
38.146 - GHashTable *chats;
38.147 - GList *chat_servers;
38.148 - PurpleRoomlist *roomlist;
38.149 - GList *user_directories;
38.150 -
38.151 - GHashTable *iq_callbacks;
38.152 - GHashTable *disco_callbacks;
38.153 - int next_id;
38.154 -
38.155 - GList *bs_proxies;
38.156 - GList *oob_file_transfers;
38.157 - GList *file_transfers;
38.158 -
38.159 - time_t idle;
38.160 -
38.161 - JabberID *user;
38.162 - PurpleConnection *gc;
38.163 - PurpleSslConnection *gsc;
38.164 -
38.165 - gboolean registration;
38.166 -
38.167 - char *avatar_hash;
38.168 - GSList *pending_avatar_requests;
38.169 -
38.170 - GSList *pending_buddy_info_requests;
38.171 -
38.172 - PurpleCircBuffer *write_buffer;
38.173 - guint writeh;
38.174 -
38.175 - gboolean reinit;
38.176 -
38.177 - JabberCapabilities server_caps;
38.178 - gboolean googletalk;
38.179 - char *server_name;
38.180 -
38.181 - char *gmail_last_time;
38.182 - char *gmail_last_tid;
38.183 -
38.184 - char *serverFQDN;
38.185 -
38.186 - /* OK, this stays at the end of the struct, so plugins can depend
38.187 - * on the rest of the stuff being in the right place
38.188 - */
38.189 -#ifdef HAVE_CYRUS_SASL
38.190 - sasl_conn_t *sasl;
38.191 - sasl_callback_t *sasl_cb;
38.192 -#else /* keep the struct the same size */
38.193 - void *sasl;
38.194 - void *sasl_cb;
38.195 -#endif
38.196 - /* did someone say something about the end of the struct? */
38.197 -#ifdef HAVE_CYRUS_SASL
38.198 - const char *current_mech;
38.199 - int auth_fail_count;
38.200 -#endif
38.201 -
38.202 - int sasl_state;
38.203 - int sasl_maxbuf;
38.204 - GString *sasl_mechs;
38.205 -
38.206 - gboolean unregistration;
38.207 - PurpleAccountUnregistrationCb unregistration_cb;
38.208 - void *unregistration_user_data;
38.209 -
38.210 - gboolean vcard_fetched;
38.211 -
38.212 - /* does the local server support PEP? */
38.213 - gboolean pep;
38.214 -
38.215 - /* Is Buzz enabled? */
38.216 - gboolean allowBuzz;
38.217 -
38.218 - /* A list of JabberAdHocCommands supported by the server */
38.219 - GList *commands;
38.220 -
38.221 - /* last presence update to check for differences */
38.222 - JabberBuddyState old_state;
38.223 - char *old_msg;
38.224 - int old_priority;
38.225 - char *old_avatarhash;
38.226 -
38.227 - /* same for user tune */
38.228 - char *old_artist;
38.229 - char *old_title;
38.230 - char *old_source;
38.231 - char *old_uri;
38.232 - int old_length;
38.233 - char *old_track;
38.234 -
38.235 - char *certificate_CN;
38.236 -
38.237 - /* A purple timeout tag for the keepalive */
38.238 - int keepalive_timeout;
38.239 -
38.240 - PurpleSrvResponse *srv_rec;
38.241 - guint srv_rec_idx;
38.242 - guint max_srv_rec_idx;
38.243 - /**
38.244 - * This linked list contains PurpleUtilFetchUrlData structs
38.245 - * for when we lookup buddy icons from a url
38.246 - */
38.247 - GSList *url_datas;
38.248 -};
38.249 -
38.250 -typedef gboolean (JabberFeatureEnabled)(JabberStream *js, const gchar *shortname, const gchar *namespace);
38.251 -
38.252 -typedef struct _JabberFeature
38.253 -{
38.254 - gchar *shortname;
38.255 - gchar *namespace;
38.256 - JabberFeatureEnabled *is_enabled;
38.257 -} JabberFeature;
38.258 -
38.259 -typedef struct _JabberBytestreamsStreamhost {
38.260 - char *jid;
38.261 - char *host;
38.262 - int port;
38.263 - char *zeroconf;
38.264 -} JabberBytestreamsStreamhost;
38.265 -
38.266 -/* what kind of additional features as returned from disco#info are supported? */
38.267 -extern GList *jabber_features;
38.268 -
38.269 -void jabber_process_packet(JabberStream *js, xmlnode **packet);
38.270 -void jabber_send(JabberStream *js, xmlnode *data);
38.271 -void jabber_send_raw(JabberStream *js, const char *data, int len);
38.272 -
38.273 -void jabber_stream_set_state(JabberStream *js, JabberStreamState state);
38.274 -
38.275 -void jabber_register_parse(JabberStream *js, xmlnode *packet);
38.276 -void jabber_register_start(JabberStream *js);
38.277 -
38.278 -char *jabber_get_next_id(JabberStream *js);
38.279 -
38.280 -/** Parse an error into a human-readable string and optionally a disconnect
38.281 - * reason.
38.282 - * @param js the stream on which the error occurred.
38.283 - * @param packet the error packet
38.284 - * @param reason where to store the disconnection reason, or @c NULL if you
38.285 - * don't care or you don't intend to close the connection.
38.286 - */
38.287 -char *jabber_parse_error(JabberStream *js, xmlnode *packet, PurpleConnectionError *reason);
38.288 -
38.289 -void jabber_add_feature(const gchar *shortname, const gchar *namespace, JabberFeatureEnabled cb); /* cb may be NULL */
38.290 -void jabber_remove_feature(const gchar *shortname);
38.291 -
38.292 -/** PRPL functions */
38.293 -const char *jabber_list_icon(PurpleAccount *a, PurpleBuddy *b);
38.294 -const char* jabber_list_emblem(PurpleBuddy *b);
38.295 -char *jabber_status_text(PurpleBuddy *b);
38.296 -void jabber_tooltip_text(PurpleBuddy *b, PurpleNotifyUserInfo *user_info, gboolean full);
38.297 -GList *jabber_status_types(PurpleAccount *account);
38.298 -void jabber_login(PurpleAccount *account);
38.299 -void jabber_close(PurpleConnection *gc);
38.300 -void jabber_idle_set(PurpleConnection *gc, int idle);
38.301 -void jabber_request_block_list(JabberStream *js);
38.302 -void jabber_add_deny(PurpleConnection *gc, const char *who);
38.303 -void jabber_rem_deny(PurpleConnection *gc, const char *who);
38.304 -void jabber_keepalive(PurpleConnection *gc);
38.305 -void jabber_register_gateway(JabberStream *js, const char *gateway);
38.306 -void jabber_register_account(PurpleAccount *account);
38.307 -void jabber_unregister_account(PurpleAccount *account, PurpleAccountUnregistrationCb cb, void *user_data);
38.308 -gboolean jabber_send_attention(PurpleConnection *gc, const char *username, guint code);
38.309 -GList *jabber_attention_types(PurpleAccount *account);
38.310 -void jabber_convo_closed(PurpleConnection *gc, const char *who);
38.311 -PurpleChat *jabber_find_blist_chat(PurpleAccount *account, const char *name);
38.312 -gboolean jabber_offline_message(const PurpleBuddy *buddy);
38.313 -int jabber_prpl_send_raw(PurpleConnection *gc, const char *buf, int len);
38.314 -GList *jabber_actions(PurplePlugin *plugin, gpointer context);
38.315 -void jabber_register_commands(void);
38.316 -void jabber_init_plugin(PurplePlugin *plugin);
38.317 -
38.318 -#endif /* _PURPLE_JABBER_H_ */
39.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/jutil.h Sun Jun 21 22:04:11 2009 -0400
39.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
39.3 @@ -1,46 +0,0 @@
39.4 -/**
39.5 - * @file jutil.h utility functions
39.6 - *
39.7 - * purple
39.8 - *
39.9 - * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
39.10 - *
39.11 - * This program is free software; you can redistribute it and/or modify
39.12 - * it under the terms of the GNU General Public License as published by
39.13 - * the Free Software Foundation; either version 2 of the License, or
39.14 - * (at your option) any later version.
39.15 - *
39.16 - * This program is distributed in the hope that it will be useful,
39.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
39.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
39.19 - * GNU General Public License for more details.
39.20 - *
39.21 - * You should have received a copy of the GNU General Public License
39.22 - * along with this program; if not, write to the Free Software
39.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
39.24 - */
39.25 -#ifndef _PURPLE_JABBER_JUTIL_H_
39.26 -#define _PURPLE_JABBER_JUTIL_H_
39.27 -
39.28 -typedef struct _JabberID {
39.29 - char *node;
39.30 - char *domain;
39.31 - char *resource;
39.32 -} JabberID;
39.33 -
39.34 -JabberID* jabber_id_new(const char *str);
39.35 -void jabber_id_free(JabberID *jid);
39.36 -
39.37 -char *jabber_get_resource(const char *jid);
39.38 -char *jabber_get_bare_jid(const char *jid);
39.39 -
39.40 -const char *jabber_normalize(const PurpleAccount *account, const char *in);
39.41 -
39.42 -gboolean jabber_nodeprep_validate(const char *);
39.43 -gboolean jabber_nameprep_validate(const char *);
39.44 -gboolean jabber_resourceprep_validate(const char *);
39.45 -
39.46 -PurpleConversation *jabber_find_unnormalized_conv(const char *name, PurpleAccount *account);
39.47 -
39.48 -char *jabber_calculate_data_sha1sum(gconstpointer data, size_t len);
39.49 -#endif /* _PURPLE_JABBER_JUTIL_H_ */
40.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/libgadu-i386.h Sun Jun 21 22:04:11 2009 -0400
40.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
40.3 @@ -1,1393 +0,0 @@
40.4 -/* include/libgadu.h. Generated from libgadu.h.in by configure. */
40.5 -/* $Id: libgadu.h.in,v 1.5.2.1 2007-04-21 23:44:25 wojtekka Exp $ */
40.6 -
40.7 -/*
40.8 - * (C) Copyright 2001-2003 Wojtek Kaniewski <wojtekka@irc.pl>
40.9 - * Robert J. Wo¼ny <speedy@ziew.org>
40.10 - * Arkadiusz Mi¶kiewicz <arekm@pld-linux.org>
40.11 - * Tomasz Chiliñski <chilek@chilan.com>
40.12 - * Piotr Wysocki <wysek@linux.bydg.org>
40.13 - * Dawid Jarosz <dawjar@poczta.onet.pl>
40.14 - *
40.15 - * This program is free software; you can redistribute it and/or modify
40.16 - * it under the terms of the GNU Lesser General Public License Version
40.17 - * 2.1 as published by the Free Software Foundation.
40.18 - *
40.19 - * This program is distributed in the hope that it will be useful,
40.20 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
40.21 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
40.22 - * GNU Lesser General Public License for more details.
40.23 - *
40.24 - * You should have received a copy of the GNU Lesser General Public
40.25 - * License along with this program; if not, write to the Free Software
40.26 - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307,
40.27 - * USA.
40.28 - */
40.29 -
40.30 -#ifndef __GG_LIBGADU_H
40.31 -#define __GG_LIBGADU_H
40.32 -
40.33 -#ifdef __cplusplus
40.34 -#ifdef _WIN32
40.35 -#pragma pack(push, 1)
40.36 -#endif
40.37 -extern "C" {
40.38 -#endif
40.39 -
40.40 -#include <sys/types.h>
40.41 -#include <stdio.h>
40.42 -#include <stdarg.h>
40.43 -
40.44 -/* Defined if libgadu was compiled for bigendian machine. */
40.45 -/* #undef GG_CONFIG_BIGENDIAN */
40.46 -
40.47 -/* Defined if this machine has gethostbyname_r(). */
40.48 -/* #undef GG_CONFIG_HAVE_GETHOSTBYNAME_R */
40.49 -
40.50 -/* Defined if libgadu was compiled and linked with pthread support. */
40.51 -/* #undef GG_CONFIG_HAVE_PTHREAD */
40.52 -
40.53 -/* Defined if this machine has C99-compiliant vsnprintf(). */
40.54 -#define GG_CONFIG_HAVE_C99_VSNPRINTF
40.55 -
40.56 -/* Defined if this machine has va_copy(). */
40.57 -#define GG_CONFIG_HAVE_VA_COPY
40.58 -
40.59 -/* Defined if this machine has __va_copy(). */
40.60 -#define GG_CONFIG_HAVE___VA_COPY
40.61 -
40.62 -/* Defined if this machine supports long long. */
40.63 -#define GG_CONFIG_HAVE_LONG_LONG
40.64 -
40.65 -/* Defined if libgadu was compiled and linked with TLS support. */
40.66 -#define GG_CONFIG_HAVE_OPENSSL
40.67 -
40.68 -/* Defined if uintX_t types are defined in <stdint.h>. */
40.69 -#define GG_CONFIG_HAVE_STDINT_H
40.70 -
40.71 -/* Defined if uintX_t types are defined in <inttypes.h>. */
40.72 -/* #undef GG_CONFIG_HAVE_INTTYPES_H */
40.73 -
40.74 -/* Defined if uintX_t types are defined in <sys/inttypes.h>. */
40.75 -/* #undef GG_CONFIG_HAVE_SYS_INTTYPES_H */
40.76 -
40.77 -/* Defined if uintX_t types are defined in <sys/int_types.h>. */
40.78 -/* #undef GG_CONFIG_HAVE_SYS_INT_TYPES_H */
40.79 -
40.80 -/* Defined if uintX_t types are defined in <sys/types.h>. */
40.81 -/* #undef GG_CONFIG_HAVE_SYS_TYPES_H */
40.82 -
40.83 -#ifdef GG_CONFIG_HAVE_OPENSSL
40.84 -#include <openssl/ssl.h>
40.85 -#endif
40.86 -
40.87 -#ifdef GG_CONFIG_HAVE_STDINT_H
40.88 -#include <stdint.h>
40.89 -#else
40.90 -# ifdef GG_CONFIG_HAVE_INTTYPES_H
40.91 -# include <inttypes.h>
40.92 -# else
40.93 -# ifdef GG_CONFIG_HAVE_SYS_INTTYPES_H
40.94 -# include <sys/inttypes.h>
40.95 -# else
40.96 -# ifdef GG_CONFIG_HAVE_SYS_INT_TYPES_H
40.97 -# include <sys/int_types.h>
40.98 -# else
40.99 -# ifdef GG_CONFIG_HAVE_SYS_TYPES_H
40.100 -# include <sys/types.h>
40.101 -# else
40.102 -
40.103 -#ifndef __AC_STDINT_H
40.104 -#define __AC_STDINT_H
40.105 -
40.106 -/* ISO C 9X: 7.18 Integer types <stdint.h> */
40.107 -
40.108 -typedef unsigned char uint8_t;
40.109 -typedef unsigned short uint16_t;
40.110 -typedef unsigned int uint32_t;
40.111 -
40.112 -#ifndef __CYGWIN__
40.113 -#define __int8_t_defined
40.114 -typedef signed char int8_t;
40.115 -typedef signed short int16_t;
40.116 -typedef signed int int32_t;
40.117 -#endif
40.118 -
40.119 -#endif /* __AC_STDINT_H */
40.120 -
40.121 -# endif
40.122 -# endif
40.123 -# endif
40.124 -# endif
40.125 -#endif
40.126 -
40.127 -/*
40.128 - * typedef uin_t
40.129 - *
40.130 - * typ reprezentuj±cy numer osoby.
40.131 - */
40.132 -typedef uint32_t uin_t;
40.133 -
40.134 -/*
40.135 - * ogólna struktura opisuj±ca ró¿ne sesje. przydatna w klientach.
40.136 - */
40.137 -#define gg_common_head(x) \
40.138 - int fd; /* podgl±dany deskryptor */ \
40.139 - int check; /* sprawdzamy zapis czy odczyt */ \
40.140 - int state; /* aktualny stan maszynki */ \
40.141 - int error; /* kod b³êdu dla GG_STATE_ERROR */ \
40.142 - int type; /* rodzaj sesji */ \
40.143 - int id; /* identyfikator */ \
40.144 - int timeout; /* sugerowany timeout w sekundach */ \
40.145 - int (*callback)(x*); /* callback przy zmianach */ \
40.146 - void (*destroy)(x*); /* funkcja niszczenia */
40.147 -
40.148 -struct gg_common {
40.149 - gg_common_head(struct gg_common)
40.150 -};
40.151 -
40.152 -struct gg_image_queue;
40.153 -
40.154 -/*
40.155 - * struct gg_session
40.156 - *
40.157 - * struktura opisuj±ca dan± sesjê. tworzona przez gg_login(), zwalniana
40.158 - * przez gg_free_session().
40.159 - */
40.160 -struct gg_session {
40.161 - gg_common_head(struct gg_session)
40.162 -
40.163 - int async; /* czy po³±czenie jest asynchroniczne */
40.164 - int pid; /* pid procesu resolvera */
40.165 - int port; /* port, z którym siê ³±czymy */
40.166 - int seq; /* numer sekwencyjny ostatniej wiadomo¶ci */
40.167 - int last_pong; /* czas otrzymania ostatniego ping/pong */
40.168 - int last_event; /* czas otrzymania ostatniego pakietu */
40.169 -
40.170 - struct gg_event *event; /* zdarzenie po ->callback() */
40.171 -
40.172 - uint32_t proxy_addr; /* adres proxy, keszowany */
40.173 - uint16_t proxy_port; /* port proxy */
40.174 -
40.175 - uint32_t hub_addr; /* adres huba po resolvniêciu */
40.176 - uint32_t server_addr; /* adres serwera, od huba */
40.177 -
40.178 - uint32_t client_addr; /* adres klienta */
40.179 - uint16_t client_port; /* port, na którym klient s³ucha */
40.180 -
40.181 - uint32_t external_addr; /* adres zewnetrzny klienta */
40.182 - uint16_t external_port; /* port zewnetrzny klienta */
40.183 -
40.184 - uin_t uin; /* numerek klienta */
40.185 - char *password; /* i jego has³o. zwalniane automagicznie */
40.186 -
40.187 - int initial_status; /* pocz±tkowy stan klienta */
40.188 - int status; /* aktualny stan klienta */
40.189 -
40.190 - char *recv_buf; /* bufor na otrzymywane pakiety */
40.191 - int recv_done; /* ile ju¿ wczytano do bufora */
40.192 - int recv_left; /* i ile jeszcze trzeba wczytaæ */
40.193 -
40.194 - int protocol_version; /* wersja u¿ywanego protoko³u */
40.195 - char *client_version; /* wersja u¿ywanego klienta */
40.196 - int last_sysmsg; /* ostatnia wiadomo¶æ systemowa */
40.197 -
40.198 - char *initial_descr; /* pocz±tkowy opis stanu klienta */
40.199 -
40.200 - void *resolver; /* wska¼nik na informacje resolvera */
40.201 -
40.202 - char *header_buf; /* bufor na pocz±tek nag³ówka */
40.203 - unsigned int header_done;/* ile ju¿ mamy */
40.204 -
40.205 -#ifdef GG_CONFIG_HAVE_OPENSSL
40.206 - SSL *ssl; /* sesja TLS */
40.207 - SSL_CTX *ssl_ctx; /* kontekst sesji? */
40.208 -#else
40.209 - void *ssl; /* zachowujemy ABI */
40.210 - void *ssl_ctx;
40.211 -#endif
40.212 -
40.213 - int image_size; /* maksymalny rozmiar obrazków w KiB */
40.214 -
40.215 - char *userlist_reply; /* fragment odpowiedzi listy kontaktów */
40.216 -
40.217 - int userlist_blocks; /* na ile kawa³ków podzielono listê kontaktów */
40.218 -
40.219 - struct gg_image_queue *images; /* aktualnie wczytywane obrazki */
40.220 -};
40.221 -
40.222 -/*
40.223 - * struct gg_http
40.224 - *
40.225 - * ogólna struktura opisuj±ca stan wszystkich operacji HTTP. tworzona
40.226 - * przez gg_http_connect(), zwalniana przez gg_http_free().
40.227 - */
40.228 -struct gg_http {
40.229 - gg_common_head(struct gg_http)
40.230 -
40.231 - int async; /* czy po³±czenie asynchroniczne */
40.232 - int pid; /* pid procesu resolvera */
40.233 - int port; /* port, z którym siê ³±czymy */
40.234 -
40.235 - char *query; /* bufor zapytania http */
40.236 - char *header; /* bufor nag³ówka */
40.237 - int header_size; /* rozmiar wczytanego nag³ówka */
40.238 - char *body; /* bufor otrzymanych informacji */
40.239 - unsigned int body_size; /* oczekiwana ilo¶æ informacji */
40.240 -
40.241 - void *data; /* dane danej operacji http */
40.242 -
40.243 - char *user_data; /* dane u¿ytkownika, nie s± zwalniane przez gg_http_free() */
40.244 -
40.245 - void *resolver; /* wska¼nik na informacje resolvera */
40.246 -
40.247 - unsigned int body_done; /* ile ju¿ tre¶ci odebrano? */
40.248 -};
40.249 -
40.250 -#ifdef __GNUC__
40.251 -#define GG_PACKED __attribute__ ((packed))
40.252 -#else
40.253 -#define GG_PACKED
40.254 -#endif
40.255 -
40.256 -#define GG_MAX_PATH 276
40.257 -
40.258 -/*
40.259 - * struct gg_file_info
40.260 - *
40.261 - * odpowiednik windowsowej struktury WIN32_FIND_DATA niezbêdnej przy
40.262 - * wysy³aniu plików.
40.263 - */
40.264 -struct gg_file_info {
40.265 - uint32_t mode; /* dwFileAttributes */
40.266 - uint32_t ctime[2]; /* ftCreationTime */
40.267 - uint32_t atime[2]; /* ftLastAccessTime */
40.268 - uint32_t mtime[2]; /* ftLastWriteTime */
40.269 - uint32_t size_hi; /* nFileSizeHigh */
40.270 - uint32_t size; /* nFileSizeLow */
40.271 - uint32_t reserved0; /* dwReserved0 */
40.272 - uint32_t reserved1; /* dwReserved1 */
40.273 - unsigned char filename[GG_MAX_PATH - 14]; /* cFileName */
40.274 - unsigned char short_filename[14]; /* cAlternateFileName */
40.275 -} GG_PACKED;
40.276 -
40.277 -/*
40.278 - * struct gg_dcc
40.279 - *
40.280 - * struktura opisuj±ca nas³uchuj±ce gniazdo po³±czeñ miêdzy klientami.
40.281 - * tworzona przez gg_dcc_socket_create(), zwalniana przez gg_dcc_free().
40.282 - */
40.283 -struct gg_dcc {
40.284 - gg_common_head(struct gg_dcc)
40.285 -
40.286 - struct gg_event *event; /* opis zdarzenia */
40.287 -
40.288 - int active; /* czy to my siê ³±czymy? */
40.289 - int port; /* port, na którym siedzi */
40.290 - uin_t uin; /* uin klienta */
40.291 - uin_t peer_uin; /* uin drugiej strony */
40.292 - int file_fd; /* deskryptor pliku */
40.293 - unsigned int offset; /* offset w pliku */
40.294 - unsigned int chunk_size;/* rozmiar kawa³ka */
40.295 - unsigned int chunk_offset;/* offset w aktualnym kawa³ku */
40.296 - struct gg_file_info file_info;
40.297 - /* informacje o pliku */
40.298 - int established; /* po³±czenie ustanowione */
40.299 - char *voice_buf; /* bufor na pakiet po³±czenia g³osowego */
40.300 - int incoming; /* po³±czenie przychodz±ce */
40.301 - char *chunk_buf; /* bufor na kawa³ek danych */
40.302 - uint32_t remote_addr; /* adres drugiej strony */
40.303 - uint16_t remote_port; /* port drugiej strony */
40.304 -};
40.305 -
40.306 -/*
40.307 - * enum gg_session_t
40.308 - *
40.309 - * rodzaje sesji.
40.310 - */
40.311 -enum gg_session_t {
40.312 - GG_SESSION_GG = 1, /* po³±czenie z serwerem gg */
40.313 - GG_SESSION_HTTP, /* ogólna sesja http */
40.314 - GG_SESSION_SEARCH, /* szukanie */
40.315 - GG_SESSION_REGISTER, /* rejestrowanie */
40.316 - GG_SESSION_REMIND, /* przypominanie has³a */
40.317 - GG_SESSION_PASSWD, /* zmiana has³a */
40.318 - GG_SESSION_CHANGE, /* zmiana informacji o sobie */
40.319 - GG_SESSION_DCC, /* ogólne po³±czenie DCC */
40.320 - GG_SESSION_DCC_SOCKET, /* nas³uchuj±cy socket */
40.321 - GG_SESSION_DCC_SEND, /* wysy³anie pliku */
40.322 - GG_SESSION_DCC_GET, /* odbieranie pliku */
40.323 - GG_SESSION_DCC_VOICE, /* rozmowa g³osowa */
40.324 - GG_SESSION_USERLIST_GET, /* pobieranie userlisty */
40.325 - GG_SESSION_USERLIST_PUT, /* wysy³anie userlisty */
40.326 - GG_SESSION_UNREGISTER, /* usuwanie konta */
40.327 - GG_SESSION_USERLIST_REMOVE, /* usuwanie userlisty */
40.328 - GG_SESSION_TOKEN, /* pobieranie tokenu */
40.329 -
40.330 - GG_SESSION_USER0 = 256, /* zdefiniowana dla u¿ytkownika */
40.331 - GG_SESSION_USER1, /* j.w. */
40.332 - GG_SESSION_USER2, /* j.w. */
40.333 - GG_SESSION_USER3, /* j.w. */
40.334 - GG_SESSION_USER4, /* j.w. */
40.335 - GG_SESSION_USER5, /* j.w. */
40.336 - GG_SESSION_USER6, /* j.w. */
40.337 - GG_SESSION_USER7 /* j.w. */
40.338 -};
40.339 -
40.340 -/*
40.341 - * enum gg_state_t
40.342 - *
40.343 - * opisuje stan asynchronicznej maszyny.
40.344 - */
40.345 -enum gg_state_t {
40.346 - /* wspólne */
40.347 - GG_STATE_IDLE = 0, /* nie powinno wyst±piæ. */
40.348 - GG_STATE_RESOLVING, /* wywo³a³ gethostbyname() */
40.349 - GG_STATE_CONNECTING, /* wywo³a³ connect() */
40.350 - GG_STATE_READING_DATA, /* czeka na dane http */
40.351 - GG_STATE_ERROR, /* wyst±pi³ b³±d. kod w x->error */
40.352 -
40.353 - /* gg_session */
40.354 - GG_STATE_CONNECTING_HUB, /* wywo³a³ connect() na huba */
40.355 - GG_STATE_CONNECTING_GG, /* wywo³a³ connect() na serwer */
40.356 - GG_STATE_READING_KEY, /* czeka na klucz */
40.357 - GG_STATE_READING_REPLY, /* czeka na odpowied¼ */
40.358 - GG_STATE_CONNECTED, /* po³±czy³ siê */
40.359 -
40.360 - /* gg_http */
40.361 - GG_STATE_SENDING_QUERY, /* wysy³a zapytanie http */
40.362 - GG_STATE_READING_HEADER, /* czeka na nag³ówek http */
40.363 - GG_STATE_PARSING, /* przetwarza dane */
40.364 - GG_STATE_DONE, /* skoñczy³ */
40.365 -
40.366 - /* gg_dcc */
40.367 - GG_STATE_LISTENING, /* czeka na po³±czenia */
40.368 - GG_STATE_READING_UIN_1, /* czeka na uin peera */
40.369 - GG_STATE_READING_UIN_2, /* czeka na swój uin */
40.370 - GG_STATE_SENDING_ACK, /* wysy³a potwierdzenie dcc */
40.371 - GG_STATE_READING_ACK, /* czeka na potwierdzenie dcc */
40.372 - GG_STATE_READING_REQUEST, /* czeka na komendê */
40.373 - GG_STATE_SENDING_REQUEST, /* wysy³a komendê */
40.374 - GG_STATE_SENDING_FILE_INFO, /* wysy³a informacje o pliku */
40.375 - GG_STATE_READING_PRE_FILE_INFO, /* czeka na pakiet przed file_info */
40.376 - GG_STATE_READING_FILE_INFO, /* czeka na informacje o pliku */
40.377 - GG_STATE_SENDING_FILE_ACK, /* wysy³a potwierdzenie pliku */
40.378 - GG_STATE_READING_FILE_ACK, /* czeka na potwierdzenie pliku */
40.379 - GG_STATE_SENDING_FILE_HEADER, /* wysy³a nag³ówek pliku */
40.380 - GG_STATE_READING_FILE_HEADER, /* czeka na nag³ówek */
40.381 - GG_STATE_GETTING_FILE, /* odbiera plik */
40.382 - GG_STATE_SENDING_FILE, /* wysy³a plik */
40.383 - GG_STATE_READING_VOICE_ACK, /* czeka na potwierdzenie voip */
40.384 - GG_STATE_READING_VOICE_HEADER, /* czeka na rodzaj bloku voip */
40.385 - GG_STATE_READING_VOICE_SIZE, /* czeka na rozmiar bloku voip */
40.386 - GG_STATE_READING_VOICE_DATA, /* czeka na dane voip */
40.387 - GG_STATE_SENDING_VOICE_ACK, /* wysy³a potwierdzenie voip */
40.388 - GG_STATE_SENDING_VOICE_REQUEST, /* wysy³a ¿±danie voip */
40.389 - GG_STATE_READING_TYPE, /* czeka na typ po³±czenia */
40.390 -
40.391 - /* nowe. bez sensu jest to API. */
40.392 - GG_STATE_TLS_NEGOTIATION /* negocjuje po³±czenie TLS */
40.393 -};
40.394 -
40.395 -/*
40.396 - * enum gg_check_t
40.397 - *
40.398 - * informuje, co proces klienta powinien sprawdziæ na deskryptorze danego
40.399 - * po³±czenia.
40.400 - */
40.401 -enum gg_check_t {
40.402 - GG_CHECK_NONE = 0, /* nic. nie powinno wyst±piæ */
40.403 - GG_CHECK_WRITE = 1, /* sprawdzamy mo¿liwo¶æ zapisu */
40.404 - GG_CHECK_READ = 2 /* sprawdzamy mo¿liwo¶æ odczytu */
40.405 -};
40.406 -
40.407 -/*
40.408 - * struct gg_login_params
40.409 - *
40.410 - * parametry gg_login(). przeniesiono do struktury, ¿eby unikn±æ problemów
40.411 - * z ci±g³ymi zmianami API, gdy dodano co¶ nowego do protoko³u.
40.412 - */
40.413 -struct gg_login_params {
40.414 - uin_t uin; /* numerek */
40.415 - char *password; /* has³o */
40.416 - int async; /* asynchroniczne sockety? */
40.417 - int status; /* pocz±tkowy status klienta */
40.418 - char *status_descr; /* opis statusu */
40.419 - uint32_t server_addr; /* adres serwera gg */
40.420 - uint16_t server_port; /* port serwera gg */
40.421 - uint32_t client_addr; /* adres dcc klienta */
40.422 - uint16_t client_port; /* port dcc klienta */
40.423 - int protocol_version; /* wersja protoko³u */
40.424 - char *client_version; /* wersja klienta */
40.425 - int has_audio; /* czy ma d¼wiêk? */
40.426 - int last_sysmsg; /* ostatnia wiadomo¶æ systemowa */
40.427 - uint32_t external_addr; /* adres widziany na zewnatrz */
40.428 - uint16_t external_port; /* port widziany na zewnatrz */
40.429 - int tls; /* czy ³±czymy po TLS? */
40.430 - int image_size; /* maksymalny rozmiar obrazka w KiB */
40.431 - int era_omnix; /* czy udawaæ klienta era omnix? */
40.432 -
40.433 - char dummy[6 * sizeof(int)]; /* miejsce na kolejnych 6 zmiennych,
40.434 - * ¿eby z dodaniem parametru nie
40.435 - * zmienia³ siê rozmiar struktury */
40.436 -};
40.437 -
40.438 -struct gg_session *gg_login(const struct gg_login_params *p);
40.439 -void gg_free_session(struct gg_session *sess);
40.440 -void gg_logoff(struct gg_session *sess);
40.441 -int gg_change_status(struct gg_session *sess, int status);
40.442 -int gg_change_status_descr(struct gg_session *sess, int status, const char *descr);
40.443 -int gg_change_status_descr_time(struct gg_session *sess, int status, const char *descr, int time);
40.444 -int gg_send_message(struct gg_session *sess, int msgclass, uin_t recipient, const unsigned char *message);
40.445 -int gg_send_message_richtext(struct gg_session *sess, int msgclass, uin_t recipient, const unsigned char *message, const unsigned char *format, int formatlen);
40.446 -int gg_send_message_confer(struct gg_session *sess, int msgclass, int recipients_count, uin_t *recipients, const unsigned char *message);
40.447 -int gg_send_message_confer_richtext(struct gg_session *sess, int msgclass, int recipients_count, uin_t *recipients, const unsigned char *message, const unsigned char *format, int formatlen);
40.448 -int gg_send_message_ctcp(struct gg_session *sess, int msgclass, uin_t recipient, const unsigned char *message, int message_len);
40.449 -int gg_ping(struct gg_session *sess);
40.450 -int gg_userlist_request(struct gg_session *sess, char type, const char *request);
40.451 -int gg_image_request(struct gg_session *sess, uin_t recipient, int size, uint32_t crc32);
40.452 -int gg_image_reply(struct gg_session *sess, uin_t recipient, const char *filename, const char *image, int size);
40.453 -
40.454 -uint32_t gg_crc32(uint32_t crc, const unsigned char *buf, int len);
40.455 -
40.456 -struct gg_image_queue {
40.457 - uin_t sender; /* nadawca obrazka */
40.458 - uint32_t size; /* rozmiar */
40.459 - uint32_t crc32; /* suma kontrolna */
40.460 - char *filename; /* nazwa pliku */
40.461 - char *image; /* bufor z obrazem */
40.462 - uint32_t done; /* ile ju¿ wczytano */
40.463 -
40.464 - struct gg_image_queue *next; /* nastêpny na li¶cie */
40.465 -};
40.466 -
40.467 -/*
40.468 - * enum gg_event_t
40.469 - *
40.470 - * rodzaje zdarzeñ.
40.471 - */
40.472 -enum gg_event_t {
40.473 - GG_EVENT_NONE = 0, /* nic siê nie wydarzy³o */
40.474 - GG_EVENT_MSG, /* otrzymano wiadomo¶æ */
40.475 - GG_EVENT_NOTIFY, /* kto¶ siê pojawi³ */
40.476 - GG_EVENT_NOTIFY_DESCR, /* kto¶ siê pojawi³ z opisem */
40.477 - GG_EVENT_STATUS, /* kto¶ zmieni³ stan */
40.478 - GG_EVENT_ACK, /* potwierdzenie wys³ania wiadomo¶ci */
40.479 - GG_EVENT_PONG, /* pakiet pong */
40.480 - GG_EVENT_CONN_FAILED, /* po³±czenie siê nie uda³o */
40.481 - GG_EVENT_CONN_SUCCESS, /* po³±czenie siê powiod³o */
40.482 - GG_EVENT_DISCONNECT, /* serwer zrywa po³±czenie */
40.483 -
40.484 - GG_EVENT_DCC_NEW, /* nowe po³±czenie miêdzy klientami */
40.485 - GG_EVENT_DCC_ERROR, /* b³±d po³±czenia miêdzy klientami */
40.486 - GG_EVENT_DCC_DONE, /* zakoñczono po³±czenie */
40.487 - GG_EVENT_DCC_CLIENT_ACCEPT, /* moment akceptacji klienta */
40.488 - GG_EVENT_DCC_CALLBACK, /* klient siê po³±czy³ na ¿±danie */
40.489 - GG_EVENT_DCC_NEED_FILE_INFO, /* nale¿y wype³niæ file_info */
40.490 - GG_EVENT_DCC_NEED_FILE_ACK, /* czeka na potwierdzenie pliku */
40.491 - GG_EVENT_DCC_NEED_VOICE_ACK, /* czeka na potwierdzenie rozmowy */
40.492 - GG_EVENT_DCC_VOICE_DATA, /* ramka danych rozmowy g³osowej */
40.493 -
40.494 - GG_EVENT_PUBDIR50_SEARCH_REPLY, /* odpowiedz wyszukiwania */
40.495 - GG_EVENT_PUBDIR50_READ, /* odczytano w³asne dane z katalogu */
40.496 - GG_EVENT_PUBDIR50_WRITE, /* wpisano w³asne dane do katalogu */
40.497 -
40.498 - GG_EVENT_STATUS60, /* kto¶ zmieni³ stan w GG 6.0 */
40.499 - GG_EVENT_NOTIFY60, /* kto¶ siê pojawi³ w GG 6.0 */
40.500 - GG_EVENT_USERLIST, /* odpowied¼ listy kontaktów w GG 6.0 */
40.501 - GG_EVENT_IMAGE_REQUEST, /* pro¶ba o wys³anie obrazka GG 6.0 */
40.502 - GG_EVENT_IMAGE_REPLY, /* podes³any obrazek GG 6.0 */
40.503 - GG_EVENT_DCC_ACK /* potwierdzenie transmisji */
40.504 -};
40.505 -
40.506 -#define GG_EVENT_SEARCH50_REPLY GG_EVENT_PUBDIR50_SEARCH_REPLY
40.507 -
40.508 -/*
40.509 - * enum gg_failure_t
40.510 - *
40.511 - * okre¶la powód nieudanego po³±czenia.
40.512 - */
40.513 -enum gg_failure_t {
40.514 - GG_FAILURE_RESOLVING = 1, /* nie znaleziono serwera */
40.515 - GG_FAILURE_CONNECTING, /* nie mo¿na siê po³±czyæ */
40.516 - GG_FAILURE_INVALID, /* serwer zwróci³ nieprawid³owe dane */
40.517 - GG_FAILURE_READING, /* zerwano po³±czenie podczas odczytu */
40.518 - GG_FAILURE_WRITING, /* zerwano po³±czenie podczas zapisu */
40.519 - GG_FAILURE_PASSWORD, /* nieprawid³owe has³o */
40.520 - GG_FAILURE_404, /* XXX nieu¿ywane */
40.521 - GG_FAILURE_TLS, /* b³±d negocjacji TLS */
40.522 - GG_FAILURE_NEED_EMAIL, /* serwer roz³±czy³ nas z pro¶b± o zmianê emaila */
40.523 - GG_FAILURE_INTRUDER, /* za du¿o prób po³±czenia siê z nieprawid³owym has³em */
40.524 - GG_FAILURE_UNAVAILABLE /* serwery s± wy³±czone */
40.525 -};
40.526 -
40.527 -/*
40.528 - * enum gg_error_t
40.529 - *
40.530 - * okre¶la rodzaj b³êdu wywo³anego przez dan± operacjê. nie zawiera
40.531 - * przesadnie szczegó³owych informacji o powodzie b³êdu, by nie komplikowaæ
40.532 - * obs³ugi b³êdów. je¶li wymagana jest wiêksza dok³adno¶æ, nale¿y sprawdziæ
40.533 - * zawarto¶æ zmiennej errno.
40.534 - */
40.535 -enum gg_error_t {
40.536 - GG_ERROR_RESOLVING = 1, /* b³±d znajdowania hosta */
40.537 - GG_ERROR_CONNECTING, /* b³±d ³aczenia siê */
40.538 - GG_ERROR_READING, /* b³±d odczytu */
40.539 - GG_ERROR_WRITING, /* b³±d wysy³ania */
40.540 -
40.541 - GG_ERROR_DCC_HANDSHAKE, /* b³±d negocjacji */
40.542 - GG_ERROR_DCC_FILE, /* b³±d odczytu/zapisu pliku */
40.543 - GG_ERROR_DCC_EOF, /* plik siê skoñczy³? */
40.544 - GG_ERROR_DCC_NET, /* b³±d wysy³ania/odbierania */
40.545 - GG_ERROR_DCC_REFUSED /* po³±czenie odrzucone przez usera */
40.546 -};
40.547 -
40.548 -/*
40.549 - * struktury dotycz±ce wyszukiwania w GG 5.0. NIE NALE¯Y SIÊ DO NICH
40.550 - * ODWO£YWAÆ BEZPO¦REDNIO! do dostêpu do nich s³u¿± funkcje gg_pubdir50_*()
40.551 - */
40.552 -struct gg_pubdir50_entry {
40.553 - int num;
40.554 - char *field;
40.555 - char *value;
40.556 -};
40.557 -
40.558 -struct gg_pubdir50_s {
40.559 - int count;
40.560 - uin_t next;
40.561 - int type;
40.562 - uint32_t seq;
40.563 - struct gg_pubdir50_entry *entries;
40.564 - int entries_count;
40.565 -};
40.566 -
40.567 -/*
40.568 - * typedef gg_pubdir_50_t
40.569 - *
40.570 - * typ opisuj±cy zapytanie lub wynik zapytania katalogu publicznego
40.571 - * z protoko³u GG 5.0. nie nale¿y siê odwo³ywaæ bezpo¶rednio do jego
40.572 - * pól -- s³u¿± do tego funkcje gg_pubdir50_*()
40.573 - */
40.574 -typedef struct gg_pubdir50_s *gg_pubdir50_t;
40.575 -
40.576 -/*
40.577 - * struct gg_event
40.578 - *
40.579 - * struktura opisuj±ca rodzaj zdarzenia. wychodzi z gg_watch_fd() lub
40.580 - * z gg_dcc_watch_fd()
40.581 - */
40.582 -struct gg_event {
40.583 - int type; /* rodzaj zdarzenia -- gg_event_t */
40.584 - union { /* @event */
40.585 - struct gg_notify_reply *notify; /* informacje o li¶cie kontaktów -- GG_EVENT_NOTIFY */
40.586 -
40.587 - enum gg_failure_t failure; /* b³±d po³±czenia -- GG_EVENT_FAILURE */
40.588 -
40.589 - struct gg_dcc *dcc_new; /* nowe po³±czenie bezpo¶rednie -- GG_EVENT_DCC_NEW */
40.590 -
40.591 - int dcc_error; /* b³±d po³±czenia bezpo¶redniego -- GG_EVENT_DCC_ERROR */
40.592 -
40.593 - gg_pubdir50_t pubdir50; /* wynik operacji zwi±zanej z katalogiem publicznym -- GG_EVENT_PUBDIR50_* */
40.594 -
40.595 - struct { /* @msg odebrano wiadomo¶æ -- GG_EVENT_MSG */
40.596 - uin_t sender; /* numer nadawcy */
40.597 - int msgclass; /* klasa wiadomo¶ci */
40.598 - time_t time; /* czas nadania */
40.599 - unsigned char *message; /* tre¶æ wiadomo¶ci */
40.600 -
40.601 - int recipients_count; /* ilo¶æ odbiorców konferencji */
40.602 - uin_t *recipients; /* odbiorcy konferencji */
40.603 -
40.604 - int formats_length; /* d³ugo¶æ informacji o formatowaniu tekstu */
40.605 - void *formats; /* informacje o formatowaniu tekstu */
40.606 - } msg;
40.607 -
40.608 - struct { /* @notify_descr informacje o li¶cie kontaktów z opisami stanu -- GG_EVENT_NOTIFY_DESCR */
40.609 - struct gg_notify_reply *notify; /* informacje o li¶cie kontaktów */
40.610 - char *descr; /* opis stanu */
40.611 - } notify_descr;
40.612 -
40.613 - struct { /* @status zmiana stanu -- GG_EVENT_STATUS */
40.614 - uin_t uin; /* numer */
40.615 - uint32_t status; /* nowy stan */
40.616 - char *descr; /* opis stanu */
40.617 - } status;
40.618 -
40.619 - struct { /* @status60 zmiana stanu -- GG_EVENT_STATUS60 */
40.620 - uin_t uin; /* numer */
40.621 - int status; /* nowy stan */
40.622 - uint32_t remote_ip; /* adres ip */
40.623 - uint16_t remote_port; /* port */
40.624 - int version; /* wersja klienta */
40.625 - int image_size; /* maksymalny rozmiar grafiki w KiB */
40.626 - char *descr; /* opis stanu */
40.627 - time_t time; /* czas powrotu */
40.628 - } status60;
40.629 -
40.630 - struct { /* @notify60 informacja o li¶cie kontaktów -- GG_EVENT_NOTIFY60 */
40.631 - uin_t uin; /* numer */
40.632 - int status; /* stan */
40.633 - uint32_t remote_ip; /* adres ip */
40.634 - uint16_t remote_port; /* port */
40.635 - int version; /* wersja klienta */
40.636 - int image_size; /* maksymalny rozmiar grafiki w KiB */
40.637 - char *descr; /* opis stanu */
40.638 - time_t time; /* czas powrotu */
40.639 - } *notify60;
40.640 -
40.641 - struct { /* @ack potwierdzenie wiadomo¶ci -- GG_EVENT_ACK */
40.642 - uin_t recipient; /* numer odbiorcy */
40.643 - int status; /* stan dorêczenia wiadomo¶ci */
40.644 - int seq; /* numer sekwencyjny wiadomo¶ci */
40.645 - } ack;
40.646 -
40.647 - struct { /* @dcc_voice_data otrzymano dane d¼wiêkowe -- GG_EVENT_DCC_VOICE_DATA */
40.648 - uint8_t *data; /* dane d¼wiêkowe */
40.649 - int length; /* ilo¶æ danych d¼wiêkowych */
40.650 - } dcc_voice_data;
40.651 -
40.652 - struct { /* @userlist odpowied¼ listy kontaktów serwera */
40.653 - char type; /* rodzaj odpowiedzi */
40.654 - char *reply; /* tre¶æ odpowiedzi */
40.655 - } userlist;
40.656 -
40.657 - struct { /* @image_request pro¶ba o obrazek */
40.658 - uin_t sender; /* nadawca pro¶by */
40.659 - uint32_t size; /* rozmiar obrazka */
40.660 - uint32_t crc32; /* suma kontrolna */
40.661 - } image_request;
40.662 -
40.663 - struct { /* @image_reply odpowied¼ z obrazkiem */
40.664 - uin_t sender; /* nadawca odpowiedzi */
40.665 - uint32_t size; /* rozmiar obrazka */
40.666 - uint32_t crc32; /* suma kontrolna */
40.667 - char *filename; /* nazwa pliku */
40.668 - char *image; /* bufor z obrazkiem */
40.669 - } image_reply;
40.670 - } event;
40.671 -};
40.672 -
40.673 -struct gg_event *gg_watch_fd(struct gg_session *sess);
40.674 -void gg_event_free(struct gg_event *e);
40.675 -#define gg_free_event gg_event_free
40.676 -
40.677 -/*
40.678 - * funkcje obs³ugi listy kontaktów.
40.679 - */
40.680 -int gg_notify_ex(struct gg_session *sess, uin_t *userlist, char *types, int count);
40.681 -int gg_notify(struct gg_session *sess, uin_t *userlist, int count);
40.682 -int gg_add_notify_ex(struct gg_session *sess, uin_t uin, char type);
40.683 -int gg_add_notify(struct gg_session *sess, uin_t uin);
40.684 -int gg_remove_notify_ex(struct gg_session *sess, uin_t uin, char type);
40.685 -int gg_remove_notify(struct gg_session *sess, uin_t uin);
40.686 -
40.687 -/*
40.688 - * funkcje obs³ugi http.
40.689 - */
40.690 -struct gg_http *gg_http_connect(const char *hostname, int port, int async, const char *method, const char *path, const char *header);
40.691 -int gg_http_watch_fd(struct gg_http *h);
40.692 -void gg_http_stop(struct gg_http *h);
40.693 -void gg_http_free(struct gg_http *h);
40.694 -void gg_http_free_fields(struct gg_http *h);
40.695 -#define gg_free_http gg_http_free
40.696 -
40.697 -/*
40.698 - * struktury opisuj±ca kryteria wyszukiwania dla gg_search(). nieaktualne,
40.699 - * zast±pione przez gg_pubdir50_t. pozostawiono je dla zachowania ABI.
40.700 - */
40.701 -struct gg_search_request {
40.702 - int active;
40.703 - unsigned int start;
40.704 - char *nickname;
40.705 - char *first_name;
40.706 - char *last_name;
40.707 - char *city;
40.708 - int gender;
40.709 - int min_birth;
40.710 - int max_birth;
40.711 - char *email;
40.712 - char *phone;
40.713 - uin_t uin;
40.714 -};
40.715 -
40.716 -struct gg_search {
40.717 - int count;
40.718 - struct gg_search_result *results;
40.719 -};
40.720 -
40.721 -struct gg_search_result {
40.722 - uin_t uin;
40.723 - char *first_name;
40.724 - char *last_name;
40.725 - char *nickname;
40.726 - int born;
40.727 - int gender;
40.728 - char *city;
40.729 - int active;
40.730 -};
40.731 -
40.732 -#define GG_GENDER_NONE 0
40.733 -#define GG_GENDER_FEMALE 1
40.734 -#define GG_GENDER_MALE 2
40.735 -
40.736 -/*
40.737 - * funkcje wyszukiwania.
40.738 - */
40.739 -struct gg_http *gg_search(const struct gg_search_request *r, int async);
40.740 -int gg_search_watch_fd(struct gg_http *f);
40.741 -void gg_free_search(struct gg_http *f);
40.742 -#define gg_search_free gg_free_search
40.743 -
40.744 -const struct gg_search_request *gg_search_request_mode_0(char *nickname, char *first_name, char *last_name, char *city, int gender, int min_birth, int max_birth, int active, int start);
40.745 -const struct gg_search_request *gg_search_request_mode_1(char *email, int active, int start);
40.746 -const struct gg_search_request *gg_search_request_mode_2(char *phone, int active, int start);
40.747 -const struct gg_search_request *gg_search_request_mode_3(uin_t uin, int active, int start);
40.748 -void gg_search_request_free(struct gg_search_request *r);
40.749 -
40.750 -/*
40.751 - * funkcje obs³ugi katalogu publicznego zgodne z GG 5.0. tym razem funkcje
40.752 - * zachowuj± pewien poziom abstrakcji, ¿eby unikn±æ zmian ABI przy zmianach
40.753 - * w protokole.
40.754 - *
40.755 - * NIE NALE¯Y SIÊ ODWO£YWAÆ DO PÓL gg_pubdir50_t BEZPO¦REDNIO!
40.756 - */
40.757 -uint32_t gg_pubdir50(struct gg_session *sess, gg_pubdir50_t req);
40.758 -gg_pubdir50_t gg_pubdir50_new(int type);
40.759 -int gg_pubdir50_add(gg_pubdir50_t req, const char *field, const char *value);
40.760 -int gg_pubdir50_seq_set(gg_pubdir50_t req, uint32_t seq);
40.761 -const char *gg_pubdir50_get(gg_pubdir50_t res, int num, const char *field);
40.762 -int gg_pubdir50_type(gg_pubdir50_t res);
40.763 -int gg_pubdir50_count(gg_pubdir50_t res);
40.764 -uin_t gg_pubdir50_next(gg_pubdir50_t res);
40.765 -uint32_t gg_pubdir50_seq(gg_pubdir50_t res);
40.766 -void gg_pubdir50_free(gg_pubdir50_t res);
40.767 -
40.768 -#define GG_PUBDIR50_UIN "FmNumber"
40.769 -#define GG_PUBDIR50_STATUS "FmStatus"
40.770 -#define GG_PUBDIR50_FIRSTNAME "firstname"
40.771 -#define GG_PUBDIR50_LASTNAME "lastname"
40.772 -#define GG_PUBDIR50_NICKNAME "nickname"
40.773 -#define GG_PUBDIR50_BIRTHYEAR "birthyear"
40.774 -#define GG_PUBDIR50_CITY "city"
40.775 -#define GG_PUBDIR50_GENDER "gender"
40.776 -#define GG_PUBDIR50_GENDER_FEMALE "1"
40.777 -#define GG_PUBDIR50_GENDER_MALE "2"
40.778 -#define GG_PUBDIR50_GENDER_SET_FEMALE "2"
40.779 -#define GG_PUBDIR50_GENDER_SET_MALE "1"
40.780 -#define GG_PUBDIR50_ACTIVE "ActiveOnly"
40.781 -#define GG_PUBDIR50_ACTIVE_TRUE "1"
40.782 -#define GG_PUBDIR50_START "fmstart"
40.783 -#define GG_PUBDIR50_FAMILYNAME "familyname"
40.784 -#define GG_PUBDIR50_FAMILYCITY "familycity"
40.785 -
40.786 -int gg_pubdir50_handle_reply(struct gg_event *e, const char *packet, int length);
40.787 -
40.788 -/*
40.789 - * struct gg_pubdir
40.790 - *
40.791 - * operacje na katalogu publicznym.
40.792 - */
40.793 -struct gg_pubdir {
40.794 - int success; /* czy siê uda³o */
40.795 - uin_t uin; /* otrzymany numerek. 0 je¶li b³±d */
40.796 -};
40.797 -
40.798 -/* ogólne funkcje, nie powinny byæ u¿ywane */
40.799 -int gg_pubdir_watch_fd(struct gg_http *f);
40.800 -void gg_pubdir_free(struct gg_http *f);
40.801 -#define gg_free_pubdir gg_pubdir_free
40.802 -
40.803 -struct gg_token {
40.804 - int width; /* szeroko¶æ obrazka */
40.805 - int height; /* wysoko¶æ obrazka */
40.806 - int length; /* ilo¶æ znaków w tokenie */
40.807 - char *tokenid; /* id tokenu */
40.808 -};
40.809 -
40.810 -/* funkcje dotycz±ce tokenów */
40.811 -struct gg_http *gg_token(int async);
40.812 -int gg_token_watch_fd(struct gg_http *h);
40.813 -void gg_token_free(struct gg_http *h);
40.814 -
40.815 -/* rejestracja nowego numerka */
40.816 -struct gg_http *gg_register(const char *email, const char *password, int async);
40.817 -struct gg_http *gg_register2(const char *email, const char *password, const char *qa, int async);
40.818 -struct gg_http *gg_register3(const char *email, const char *password, const char *tokenid, const char *tokenval, int async);
40.819 -#define gg_register_watch_fd gg_pubdir_watch_fd
40.820 -#define gg_register_free gg_pubdir_free
40.821 -#define gg_free_register gg_pubdir_free
40.822 -
40.823 -struct gg_http *gg_unregister(uin_t uin, const char *password, const char *email, int async);
40.824 -struct gg_http *gg_unregister2(uin_t uin, const char *password, const char *qa, int async);
40.825 -struct gg_http *gg_unregister3(uin_t uin, const char *password, const char *tokenid, const char *tokenval, int async);
40.826 -#define gg_unregister_watch_fd gg_pubdir_watch_fd
40.827 -#define gg_unregister_free gg_pubdir_free
40.828 -
40.829 -/* przypomnienie has³a e-mailem */
40.830 -struct gg_http *gg_remind_passwd(uin_t uin, int async);
40.831 -struct gg_http *gg_remind_passwd2(uin_t uin, const char *tokenid, const char *tokenval, int async);
40.832 -struct gg_http *gg_remind_passwd3(uin_t uin, const char *email, const char *tokenid, const char *tokenval, int async);
40.833 -#define gg_remind_passwd_watch_fd gg_pubdir_watch_fd
40.834 -#define gg_remind_passwd_free gg_pubdir_free
40.835 -#define gg_free_remind_passwd gg_pubdir_free
40.836 -
40.837 -/* zmiana has³a */
40.838 -struct gg_http *gg_change_passwd(uin_t uin, const char *passwd, const char *newpasswd, const char *newemail, int async);
40.839 -struct gg_http *gg_change_passwd2(uin_t uin, const char *passwd, const char *newpasswd, const char *email, const char *newemail, int async);
40.840 -struct gg_http *gg_change_passwd3(uin_t uin, const char *passwd, const char *newpasswd, const char *qa, int async);
40.841 -struct gg_http *gg_change_passwd4(uin_t uin, const char *email, const char *passwd, const char *newpasswd, const char *tokenid, const char *tokenval, int async);
40.842 -#define gg_change_passwd_free gg_pubdir_free
40.843 -#define gg_free_change_passwd gg_pubdir_free
40.844 -
40.845 -/*
40.846 - * struct gg_change_info_request
40.847 - *
40.848 - * opis ¿±dania zmiany informacji w katalogu publicznym.
40.849 - */
40.850 -struct gg_change_info_request {
40.851 - char *first_name; /* imiê */
40.852 - char *last_name; /* nazwisko */
40.853 - char *nickname; /* pseudonim */
40.854 - char *email; /* email */
40.855 - int born; /* rok urodzenia */
40.856 - int gender; /* p³eæ */
40.857 - char *city; /* miasto */
40.858 -};
40.859 -
40.860 -struct gg_change_info_request *gg_change_info_request_new(const char *first_name, const char *last_name, const char *nickname, const char *email, int born, int gender, const char *city);
40.861 -void gg_change_info_request_free(struct gg_change_info_request *r);
40.862 -
40.863 -struct gg_http *gg_change_info(uin_t uin, const char *passwd, const struct gg_change_info_request *request, int async);
40.864 -#define gg_change_pubdir_watch_fd gg_pubdir_watch_fd
40.865 -#define gg_change_pubdir_free gg_pubdir_free
40.866 -#define gg_free_change_pubdir gg_pubdir_free
40.867 -
40.868 -/*
40.869 - * funkcje dotycz±ce listy kontaktów na serwerze.
40.870 - */
40.871 -struct gg_http *gg_userlist_get(uin_t uin, const char *password, int async);
40.872 -int gg_userlist_get_watch_fd(struct gg_http *f);
40.873 -void gg_userlist_get_free(struct gg_http *f);
40.874 -
40.875 -struct gg_http *gg_userlist_put(uin_t uin, const char *password, const char *contacts, int async);
40.876 -int gg_userlist_put_watch_fd(struct gg_http *f);
40.877 -void gg_userlist_put_free(struct gg_http *f);
40.878 -
40.879 -struct gg_http *gg_userlist_remove(uin_t uin, const char *password, int async);
40.880 -int gg_userlist_remove_watch_fd(struct gg_http *f);
40.881 -void gg_userlist_remove_free(struct gg_http *f);
40.882 -
40.883 -
40.884 -
40.885 -/*
40.886 - * funkcje dotycz±ce komunikacji miêdzy klientami.
40.887 - */
40.888 -extern int gg_dcc_port; /* port, na którym nas³uchuje klient */
40.889 -extern unsigned long gg_dcc_ip; /* adres, na którym nas³uchuje klient */
40.890 -
40.891 -int gg_dcc_request(struct gg_session *sess, uin_t uin);
40.892 -
40.893 -struct gg_dcc *gg_dcc_send_file(uint32_t ip, uint16_t port, uin_t my_uin, uin_t peer_uin);
40.894 -struct gg_dcc *gg_dcc_get_file(uint32_t ip, uint16_t port, uin_t my_uin, uin_t peer_uin);
40.895 -struct gg_dcc *gg_dcc_voice_chat(uint32_t ip, uint16_t port, uin_t my_uin, uin_t peer_uin);
40.896 -void gg_dcc_set_type(struct gg_dcc *d, int type);
40.897 -int gg_dcc_fill_file_info(struct gg_dcc *d, const char *filename);
40.898 -int gg_dcc_fill_file_info2(struct gg_dcc *d, const char *filename, const char *local_filename);
40.899 -int gg_dcc_voice_send(struct gg_dcc *d, char *buf, int length);
40.900 -
40.901 -#define GG_DCC_VOICE_FRAME_LENGTH 195
40.902 -#define GG_DCC_VOICE_FRAME_LENGTH_505 326
40.903 -
40.904 -struct gg_dcc *gg_dcc_socket_create(uin_t uin, uint16_t port);
40.905 -#define gg_dcc_socket_free gg_free_dcc
40.906 -#define gg_dcc_socket_watch_fd gg_dcc_watch_fd
40.907 -
40.908 -struct gg_event *gg_dcc_watch_fd(struct gg_dcc *d);
40.909 -
40.910 -void gg_dcc_free(struct gg_dcc *c);
40.911 -#define gg_free_dcc gg_dcc_free
40.912 -
40.913 -/*
40.914 - * je¶li chcemy sobie podebugowaæ, wystarczy ustawiæ `gg_debug_level'.
40.915 - * niestety w miarê przybywania wpisów `gg_debug(...)' nie chcia³o mi
40.916 - * siê ustawiaæ odpowiednich leveli, wiêc wiêkszo¶æ sz³a do _MISC.
40.917 - */
40.918 -extern int gg_debug_level; /* poziom debugowania. mapa bitowa sta³ych GG_DEBUG_* */
40.919 -
40.920 -/*
40.921 - * mo¿na podaæ wska¼nik do funkcji obs³uguj±cej wywo³ania gg_debug().
40.922 - * nieoficjalne, nieudokumentowane, mo¿e siê zmieniæ. je¶li kto¶ jest
40.923 - * zainteresowany, niech da znaæ na ekg-devel.
40.924 - */
40.925 -extern void (*gg_debug_handler)(int level, const char *format, va_list ap);
40.926 -extern void (*gg_debug_handler_session)(struct gg_session *sess, int level, const char *format, va_list ap);
40.927 -
40.928 -/*
40.929 - * mo¿na podaæ plik, do którego bêd± zapisywane teksty z gg_debug().
40.930 - */
40.931 -extern FILE *gg_debug_file;
40.932 -
40.933 -#define GG_DEBUG_NET 1
40.934 -#define GG_DEBUG_TRAFFIC 2
40.935 -#define GG_DEBUG_DUMP 4
40.936 -#define GG_DEBUG_FUNCTION 8
40.937 -#define GG_DEBUG_MISC 16
40.938 -
40.939 -#ifdef GG_DEBUG_DISABLE
40.940 -#define gg_debug(x, y...) do { } while(0)
40.941 -#define gg_debug_session(z, x, y...) do { } while(0)
40.942 -#else
40.943 -void gg_debug(int level, const char *format, ...);
40.944 -void gg_debug_session(struct gg_session *sess, int level, const char *format, ...);
40.945 -#endif
40.946 -
40.947 -const char *gg_libgadu_version(void);
40.948 -
40.949 -/*
40.950 - * konfiguracja http proxy.
40.951 - */
40.952 -extern int gg_proxy_enabled; /* w³±cza obs³ugê proxy */
40.953 -extern char *gg_proxy_host; /* okre¶la adres serwera proxy */
40.954 -extern int gg_proxy_port; /* okre¶la port serwera proxy */
40.955 -extern char *gg_proxy_username; /* okre¶la nazwê u¿ytkownika przy autoryzacji serwera proxy */
40.956 -extern char *gg_proxy_password; /* okre¶la has³o u¿ytkownika przy autoryzacji serwera proxy */
40.957 -extern int gg_proxy_http_only; /* w³±cza obs³ugê proxy wy³±cznie dla us³ug HTTP */
40.958 -
40.959 -
40.960 -/*
40.961 - * adres, z którego ¶lemy pakiety (np ³±czymy siê z serwerem)
40.962 - * u¿ywany przy gg_connect()
40.963 - */
40.964 -extern unsigned long gg_local_ip;
40.965 -/*
40.966 - * -------------------------------------------------------------------------
40.967 - * poni¿ej znajduj± siê wewnêtrzne sprawy biblioteki. zwyk³y klient nie
40.968 - * powinien ich w ogóle ruszaæ, bo i nie ma po co. wszystko mo¿na za³atwiæ
40.969 - * procedurami wy¿szego poziomu, których definicje znajduj± siê na pocz±tku
40.970 - * tego pliku.
40.971 - * -------------------------------------------------------------------------
40.972 - */
40.973 -
40.974 -#ifdef GG_CONFIG_HAVE_PTHREAD
40.975 -int gg_resolve_pthread(int *fd, void **resolver, const char *hostname);
40.976 -void gg_resolve_pthread_cleanup(void *resolver, int kill);
40.977 -#endif
40.978 -
40.979 -#ifdef _WIN32
40.980 -int gg_thread_socket(int thread_id, int socket);
40.981 -#endif
40.982 -
40.983 -int gg_resolve(int *fd, int *pid, const char *hostname);
40.984 -
40.985 -#ifdef __GNUC__
40.986 -char *gg_saprintf(const char *format, ...) __attribute__ ((format (printf, 1, 2)));
40.987 -#else
40.988 -char *gg_saprintf(const char *format, ...);
40.989 -#endif
40.990 -
40.991 -char *gg_vsaprintf(const char *format, va_list ap);
40.992 -
40.993 -#define gg_alloc_sprintf gg_saprintf
40.994 -
40.995 -char *gg_get_line(char **ptr);
40.996 -
40.997 -int gg_connect(void *addr, int port, int async);
40.998 -struct in_addr *gg_gethostbyname(const char *hostname);
40.999 -char *gg_read_line(int sock, char *buf, int length);
40.1000 -void gg_chomp(char *line);
40.1001 -char *gg_urlencode(const char *str);
40.1002 -int gg_http_hash(const char *format, ...);
40.1003 -int gg_read(struct gg_session *sess, char *buf, int length);
40.1004 -int gg_write(struct gg_session *sess, const char *buf, int length);
40.1005 -void *gg_recv_packet(struct gg_session *sess);
40.1006 -int gg_send_packet(struct gg_session *sess, int type, ...);
40.1007 -unsigned int gg_login_hash(const unsigned char *password, unsigned int seed);
40.1008 -uint32_t gg_fix32(uint32_t x);
40.1009 -uint16_t gg_fix16(uint16_t x);
40.1010 -#define fix16 gg_fix16
40.1011 -#define fix32 gg_fix32
40.1012 -char *gg_proxy_auth(void);
40.1013 -char *gg_base64_encode(const char *buf);
40.1014 -char *gg_base64_decode(const char *buf);
40.1015 -int gg_image_queue_remove(struct gg_session *s, struct gg_image_queue *q, int freeq);
40.1016 -
40.1017 -#define GG_APPMSG_HOST "appmsg.gadu-gadu.pl"
40.1018 -#define GG_APPMSG_PORT 80
40.1019 -#define GG_PUBDIR_HOST "pubdir.gadu-gadu.pl"
40.1020 -#define GG_PUBDIR_PORT 80
40.1021 -#define GG_REGISTER_HOST "register.gadu-gadu.pl"
40.1022 -#define GG_REGISTER_PORT 80
40.1023 -#define GG_REMIND_HOST "retr.gadu-gadu.pl"
40.1024 -#define GG_REMIND_PORT 80
40.1025 -
40.1026 -#define GG_DEFAULT_PORT 8074
40.1027 -#define GG_HTTPS_PORT 443
40.1028 -#define GG_HTTP_USERAGENT "Mozilla/4.7 [en] (Win98; I)"
40.1029 -
40.1030 -#define GG_DEFAULT_CLIENT_VERSION "6, 1, 0, 158"
40.1031 -#define GG_DEFAULT_PROTOCOL_VERSION 0x24
40.1032 -#define GG_DEFAULT_TIMEOUT 30
40.1033 -#define GG_HAS_AUDIO_MASK 0x40000000
40.1034 -#define GG_ERA_OMNIX_MASK 0x04000000
40.1035 -#define GG_LIBGADU_VERSION "CVS"
40.1036 -
40.1037 -#define GG_DEFAULT_DCC_PORT 1550
40.1038 -
40.1039 -struct gg_header {
40.1040 - uint32_t type; /* typ pakietu */
40.1041 - uint32_t length; /* d³ugo¶æ reszty pakietu */
40.1042 -} GG_PACKED;
40.1043 -
40.1044 -#define GG_WELCOME 0x0001
40.1045 -#define GG_NEED_EMAIL 0x0014
40.1046 -
40.1047 -struct gg_welcome {
40.1048 - uint32_t key; /* klucz szyfrowania has³a */
40.1049 -} GG_PACKED;
40.1050 -
40.1051 -#define GG_LOGIN 0x000c
40.1052 -
40.1053 -struct gg_login {
40.1054 - uint32_t uin; /* mój numerek */
40.1055 - uint32_t hash; /* hash has³a */
40.1056 - uint32_t status; /* status na dzieñ dobry */
40.1057 - uint32_t version; /* moja wersja klienta */
40.1058 - uint32_t local_ip; /* mój adres ip */
40.1059 - uint16_t local_port; /* port, na którym s³ucham */
40.1060 -} GG_PACKED;
40.1061 -
40.1062 -#define GG_LOGIN_EXT 0x0013
40.1063 -
40.1064 -struct gg_login_ext {
40.1065 - uint32_t uin; /* mój numerek */
40.1066 - uint32_t hash; /* hash has³a */
40.1067 - uint32_t status; /* status na dzieñ dobry */
40.1068 - uint32_t version; /* moja wersja klienta */
40.1069 - uint32_t local_ip; /* mój adres ip */
40.1070 - uint16_t local_port; /* port, na którym s³ucham */
40.1071 - uint32_t external_ip; /* zewnêtrzny adres ip */
40.1072 - uint16_t external_port; /* zewnêtrzny port */
40.1073 -} GG_PACKED;
40.1074 -
40.1075 -#define GG_LOGIN60 0x0015
40.1076 -
40.1077 -struct gg_login60 {
40.1078 - uint32_t uin; /* mój numerek */
40.1079 - uint32_t hash; /* hash has³a */
40.1080 - uint32_t status; /* status na dzieñ dobry */
40.1081 - uint32_t version; /* moja wersja klienta */
40.1082 - uint8_t dunno1; /* 0x00 */
40.1083 - uint32_t local_ip; /* mój adres ip */
40.1084 - uint16_t local_port; /* port, na którym s³ucham */
40.1085 - uint32_t external_ip; /* zewnêtrzny adres ip */
40.1086 - uint16_t external_port; /* zewnêtrzny port */
40.1087 - uint8_t image_size; /* maksymalny rozmiar grafiki w KiB */
40.1088 - uint8_t dunno2; /* 0xbe */
40.1089 -} GG_PACKED;
40.1090 -
40.1091 -#define GG_LOGIN_OK 0x0003
40.1092 -
40.1093 -#define GG_LOGIN_FAILED 0x0009
40.1094 -
40.1095 -#define GG_PUBDIR50_REQUEST 0x0014
40.1096 -
40.1097 -#define GG_PUBDIR50_WRITE 0x01
40.1098 -#define GG_PUBDIR50_READ 0x02
40.1099 -#define GG_PUBDIR50_SEARCH 0x03
40.1100 -#define GG_PUBDIR50_SEARCH_REQUEST GG_PUBDIR50_SEARCH
40.1101 -#define GG_PUBDIR50_SEARCH_REPLY 0x05
40.1102 -
40.1103 -struct gg_pubdir50_request {
40.1104 - uint8_t type; /* GG_PUBDIR50_* */
40.1105 - uint32_t seq; /* czas wys³ania zapytania */
40.1106 -} GG_PACKED;
40.1107 -
40.1108 -#define GG_PUBDIR50_REPLY 0x000e
40.1109 -
40.1110 -struct gg_pubdir50_reply {
40.1111 - uint8_t type; /* GG_PUBDIR50_* */
40.1112 - uint32_t seq; /* czas wys³ania zapytania */
40.1113 -} GG_PACKED;
40.1114 -
40.1115 -#define GG_NEW_STATUS 0x0002
40.1116 -
40.1117 -#define GG_STATUS_NOT_AVAIL 0x0001 /* niedostêpny */
40.1118 -#define GG_STATUS_NOT_AVAIL_DESCR 0x0015 /* niedostêpny z opisem (4.8) */
40.1119 -#define GG_STATUS_AVAIL 0x0002 /* dostêpny */
40.1120 -#define GG_STATUS_AVAIL_DESCR 0x0004 /* dostêpny z opisem (4.9) */
40.1121 -#define GG_STATUS_BUSY 0x0003 /* zajêty */
40.1122 -#define GG_STATUS_BUSY_DESCR 0x0005 /* zajêty z opisem (4.8) */
40.1123 -#define GG_STATUS_INVISIBLE 0x0014 /* niewidoczny (4.6) */
40.1124 -#define GG_STATUS_INVISIBLE_DESCR 0x0016 /* niewidoczny z opisem (4.9) */
40.1125 -#define GG_STATUS_BLOCKED 0x0006 /* zablokowany */
40.1126 -
40.1127 -#define GG_STATUS_FRIENDS_MASK 0x8000 /* tylko dla znajomych (4.6) */
40.1128 -
40.1129 -#define GG_STATUS_DESCR_MAXSIZE 70
40.1130 -
40.1131 -/*
40.1132 - * makra do ³atwego i szybkiego sprawdzania stanu.
40.1133 - */
40.1134 -
40.1135 -/* GG_S_F() tryb tylko dla znajomych */
40.1136 -#define GG_S_F(x) (((x) & GG_STATUS_FRIENDS_MASK) != 0)
40.1137 -
40.1138 -/* GG_S() stan bez uwzglêdnienia trybu tylko dla znajomych */
40.1139 -#define GG_S(x) ((x) & ~GG_STATUS_FRIENDS_MASK)
40.1140 -
40.1141 -/* GG_S_A() dostêpny */
40.1142 -#define GG_S_A(x) (GG_S(x) == GG_STATUS_AVAIL || GG_S(x) == GG_STATUS_AVAIL_DESCR)
40.1143 -
40.1144 -/* GG_S_NA() niedostêpny */
40.1145 -#define GG_S_NA(x) (GG_S(x) == GG_STATUS_NOT_AVAIL || GG_S(x) == GG_STATUS_NOT_AVAIL_DESCR)
40.1146 -
40.1147 -/* GG_S_B() zajêty */
40.1148 -#define GG_S_B(x) (GG_S(x) == GG_STATUS_BUSY || GG_S(x) == GG_STATUS_BUSY_DESCR)
40.1149 -
40.1150 -/* GG_S_I() niewidoczny */
40.1151 -#define GG_S_I(x) (GG_S(x) == GG_STATUS_INVISIBLE || GG_S(x) == GG_STATUS_INVISIBLE_DESCR)
40.1152 -
40.1153 -/* GG_S_D() stan opisowy */
40.1154 -#define GG_S_D(x) (GG_S(x) == GG_STATUS_NOT_AVAIL_DESCR || GG_S(x) == GG_STATUS_AVAIL_DESCR || GG_S(x) == GG_STATUS_BUSY_DESCR || GG_S(x) == GG_STATUS_INVISIBLE_DESCR)
40.1155 -
40.1156 -/* GG_S_BL() blokowany lub blokuj±cy */
40.1157 -#define GG_S_BL(x) (GG_S(x) == GG_STATUS_BLOCKED)
40.1158 -
40.1159 -struct gg_new_status {
40.1160 - uint32_t status; /* na jaki zmieniæ? */
40.1161 -} GG_PACKED;
40.1162 -
40.1163 -#define GG_NOTIFY_FIRST 0x000f
40.1164 -#define GG_NOTIFY_LAST 0x0010
40.1165 -
40.1166 -#define GG_NOTIFY 0x0010
40.1167 -
40.1168 -struct gg_notify {
40.1169 - uint32_t uin; /* numerek danej osoby */
40.1170 - uint8_t dunno1; /* rodzaj wpisu w li¶cie */
40.1171 -} GG_PACKED;
40.1172 -
40.1173 -#define GG_USER_OFFLINE 0x01 /* bêdziemy niewidoczni dla u¿ytkownika */
40.1174 -#define GG_USER_NORMAL 0x03 /* zwyk³y u¿ytkownik */
40.1175 -#define GG_USER_BLOCKED 0x04 /* zablokowany u¿ytkownik */
40.1176 -
40.1177 -#define GG_LIST_EMPTY 0x0012
40.1178 -
40.1179 -#define GG_NOTIFY_REPLY 0x000c /* tak, to samo co GG_LOGIN */
40.1180 -
40.1181 -struct gg_notify_reply {
40.1182 - uint32_t uin; /* numerek */
40.1183 - uint32_t status; /* status danej osoby */
40.1184 - uint32_t remote_ip; /* adres ip delikwenta */
40.1185 - uint16_t remote_port; /* port, na którym s³ucha klient */
40.1186 - uint32_t version; /* wersja klienta */
40.1187 - uint16_t dunno2; /* znowu port? */
40.1188 -} GG_PACKED;
40.1189 -
40.1190 -#define GG_NOTIFY_REPLY60 0x0011
40.1191 -
40.1192 -struct gg_notify_reply60 {
40.1193 - uint32_t uin; /* numerek plus flagi w MSB */
40.1194 - uint8_t status; /* status danej osoby */
40.1195 - uint32_t remote_ip; /* adres ip delikwenta */
40.1196 - uint16_t remote_port; /* port, na którym s³ucha klient */
40.1197 - uint8_t version; /* wersja klienta */
40.1198 - uint8_t image_size; /* maksymalny rozmiar grafiki w KiB */
40.1199 - uint8_t dunno1; /* 0x00 */
40.1200 -} GG_PACKED;
40.1201 -
40.1202 -#define GG_STATUS60 0x000f
40.1203 -
40.1204 -struct gg_status60 {
40.1205 - uint32_t uin; /* numerek plus flagi w MSB */
40.1206 - uint8_t status; /* status danej osoby */
40.1207 - uint32_t remote_ip; /* adres ip delikwenta */
40.1208 - uint16_t remote_port; /* port, na którym s³ucha klient */
40.1209 - uint8_t version; /* wersja klienta */
40.1210 - uint8_t image_size; /* maksymalny rozmiar grafiki w KiB */
40.1211 - uint8_t dunno1; /* 0x00 */
40.1212 -} GG_PACKED;
40.1213 -
40.1214 -#define GG_ADD_NOTIFY 0x000d
40.1215 -#define GG_REMOVE_NOTIFY 0x000e
40.1216 -
40.1217 -struct gg_add_remove {
40.1218 - uint32_t uin; /* numerek */
40.1219 - uint8_t dunno1; /* bitmapa */
40.1220 -} GG_PACKED;
40.1221 -
40.1222 -#define GG_STATUS 0x0002
40.1223 -
40.1224 -struct gg_status {
40.1225 - uint32_t uin; /* numerek */
40.1226 - uint32_t status; /* nowy stan */
40.1227 -} GG_PACKED;
40.1228 -
40.1229 -#define GG_SEND_MSG 0x000b
40.1230 -
40.1231 -#define GG_CLASS_QUEUED 0x0001
40.1232 -#define GG_CLASS_OFFLINE GG_CLASS_QUEUED
40.1233 -#define GG_CLASS_MSG 0x0004
40.1234 -#define GG_CLASS_CHAT 0x0008
40.1235 -#define GG_CLASS_CTCP 0x0010
40.1236 -#define GG_CLASS_ACK 0x0020
40.1237 -#define GG_CLASS_EXT GG_CLASS_ACK /* kompatybilno¶æ wstecz */
40.1238 -
40.1239 -#define GG_MSG_MAXSIZE 2000
40.1240 -
40.1241 -struct gg_send_msg {
40.1242 - uint32_t recipient;
40.1243 - uint32_t seq;
40.1244 - uint32_t msgclass;
40.1245 -} GG_PACKED;
40.1246 -
40.1247 -struct gg_msg_richtext {
40.1248 - uint8_t flag;
40.1249 - uint16_t length;
40.1250 -} GG_PACKED;
40.1251 -
40.1252 -struct gg_msg_richtext_format {
40.1253 - uint16_t position;
40.1254 - uint8_t font;
40.1255 -} GG_PACKED;
40.1256 -
40.1257 -struct gg_msg_richtext_image {
40.1258 - uint16_t unknown1;
40.1259 - uint32_t size;
40.1260 - uint32_t crc32;
40.1261 -} GG_PACKED;
40.1262 -
40.1263 -#define GG_FONT_BOLD 0x01
40.1264 -#define GG_FONT_ITALIC 0x02
40.1265 -#define GG_FONT_UNDERLINE 0x04
40.1266 -#define GG_FONT_COLOR 0x08
40.1267 -#define GG_FONT_IMAGE 0x80
40.1268 -
40.1269 -struct gg_msg_richtext_color {
40.1270 - uint8_t red;
40.1271 - uint8_t green;
40.1272 - uint8_t blue;
40.1273 -} GG_PACKED;
40.1274 -
40.1275 -struct gg_msg_recipients {
40.1276 - uint8_t flag;
40.1277 - uint32_t count;
40.1278 -} GG_PACKED;
40.1279 -
40.1280 -struct gg_msg_image_request {
40.1281 - uint8_t flag;
40.1282 - uint32_t size;
40.1283 - uint32_t crc32;
40.1284 -} GG_PACKED;
40.1285 -
40.1286 -struct gg_msg_image_reply {
40.1287 - uint8_t flag;
40.1288 - uint32_t size;
40.1289 - uint32_t crc32;
40.1290 - /* char filename[]; */
40.1291 - /* char image[]; */
40.1292 -} GG_PACKED;
40.1293 -
40.1294 -#define GG_SEND_MSG_ACK 0x0005
40.1295 -
40.1296 -#define GG_ACK_BLOCKED 0x0001
40.1297 -#define GG_ACK_DELIVERED 0x0002
40.1298 -#define GG_ACK_QUEUED 0x0003
40.1299 -#define GG_ACK_MBOXFULL 0x0004
40.1300 -#define GG_ACK_NOT_DELIVERED 0x0006
40.1301 -
40.1302 -struct gg_send_msg_ack {
40.1303 - uint32_t status;
40.1304 - uint32_t recipient;
40.1305 - uint32_t seq;
40.1306 -} GG_PACKED;
40.1307 -
40.1308 -#define GG_RECV_MSG 0x000a
40.1309 -
40.1310 -struct gg_recv_msg {
40.1311 - uint32_t sender;
40.1312 - uint32_t seq;
40.1313 - uint32_t time;
40.1314 - uint32_t msgclass;
40.1315 -} GG_PACKED;
40.1316 -
40.1317 -#define GG_PING 0x0008
40.1318 -
40.1319 -#define GG_PONG 0x0007
40.1320 -
40.1321 -#define GG_DISCONNECTING 0x000b
40.1322 -
40.1323 -#define GG_USERLIST_REQUEST 0x0016
40.1324 -
40.1325 -#define GG_USERLIST_PUT 0x00
40.1326 -#define GG_USERLIST_PUT_MORE 0x01
40.1327 -#define GG_USERLIST_GET 0x02
40.1328 -
40.1329 -struct gg_userlist_request {
40.1330 - uint8_t type;
40.1331 -} GG_PACKED;
40.1332 -
40.1333 -#define GG_USERLIST_REPLY 0x0010
40.1334 -
40.1335 -#define GG_USERLIST_PUT_REPLY 0x00
40.1336 -#define GG_USERLIST_PUT_MORE_REPLY 0x02
40.1337 -#define GG_USERLIST_GET_REPLY 0x06
40.1338 -#define GG_USERLIST_GET_MORE_REPLY 0x04
40.1339 -
40.1340 -struct gg_userlist_reply {
40.1341 - uint8_t type;
40.1342 -} GG_PACKED;
40.1343 -
40.1344 -/*
40.1345 - * pakiety, sta³e, struktury dla DCC
40.1346 - */
40.1347 -
40.1348 -struct gg_dcc_tiny_packet {
40.1349 - uint8_t type; /* rodzaj pakietu */
40.1350 -} GG_PACKED;
40.1351 -
40.1352 -struct gg_dcc_small_packet {
40.1353 - uint32_t type; /* rodzaj pakietu */
40.1354 -} GG_PACKED;
40.1355 -
40.1356 -struct gg_dcc_big_packet {
40.1357 - uint32_t type; /* rodzaj pakietu */
40.1358 - uint32_t dunno1; /* niewiadoma */
40.1359 - uint32_t dunno2; /* niewiadoma */
40.1360 -} GG_PACKED;
40.1361 -
40.1362 -/*
40.1363 - * póki co, nie znamy dok³adnie protoko³u. nie wiemy, co czemu odpowiada.
40.1364 - * nazwy s± niepowa¿ne i tymczasowe.
40.1365 - */
40.1366 -#define GG_DCC_WANT_FILE 0x0003 /* peer chce plik */
40.1367 -#define GG_DCC_HAVE_FILE 0x0001 /* wiêc mu damy */
40.1368 -#define GG_DCC_HAVE_FILEINFO 0x0003 /* niech ma informacje o pliku */
40.1369 -#define GG_DCC_GIMME_FILE 0x0006 /* peer jest pewny */
40.1370 -#define GG_DCC_CATCH_FILE 0x0002 /* wysy³amy plik */
40.1371 -
40.1372 -#define GG_DCC_FILEATTR_READONLY 0x0020
40.1373 -
40.1374 -#define GG_DCC_TIMEOUT_SEND 1800 /* 30 minut */
40.1375 -#define GG_DCC_TIMEOUT_GET 1800 /* 30 minut */
40.1376 -#define GG_DCC_TIMEOUT_FILE_ACK 300 /* 5 minut */
40.1377 -#define GG_DCC_TIMEOUT_VOICE_ACK 300 /* 5 minut */
40.1378 -
40.1379 -#ifdef __cplusplus
40.1380 -}
40.1381 -#ifdef _WIN32
40.1382 -#pragma pack(pop)
40.1383 -#endif
40.1384 -#endif
40.1385 -
40.1386 -#endif /* __GG_LIBGADU_H */
40.1387 -
40.1388 -/*
40.1389 - * Local variables:
40.1390 - * c-indentation-style: k&r
40.1391 - * c-basic-offset: 8
40.1392 - * indent-tabs-mode: notnil
40.1393 - * End:
40.1394 - *
40.1395 - * vim: shiftwidth=8:
40.1396 - */
41.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/libgadu-ppc.h Sun Jun 21 22:04:11 2009 -0400
41.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
41.3 @@ -1,1393 +0,0 @@
41.4 -/* include/libgadu.h. Generated from libgadu.h.in by configure. */
41.5 -/* $Id: libgadu.h.in,v 1.5.2.1 2007-04-21 23:44:25 wojtekka Exp $ */
41.6 -
41.7 -/*
41.8 - * (C) Copyright 2001-2003 Wojtek Kaniewski <wojtekka@irc.pl>
41.9 - * Robert J. Wo¼ny <speedy@ziew.org>
41.10 - * Arkadiusz Mi¶kiewicz <arekm@pld-linux.org>
41.11 - * Tomasz Chiliñski <chilek@chilan.com>
41.12 - * Piotr Wysocki <wysek@linux.bydg.org>
41.13 - * Dawid Jarosz <dawjar@poczta.onet.pl>
41.14 - *
41.15 - * This program is free software; you can redistribute it and/or modify
41.16 - * it under the terms of the GNU Lesser General Public License Version
41.17 - * 2.1 as published by the Free Software Foundation.
41.18 - *
41.19 - * This program is distributed in the hope that it will be useful,
41.20 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
41.21 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
41.22 - * GNU Lesser General Public License for more details.
41.23 - *
41.24 - * You should have received a copy of the GNU Lesser General Public
41.25 - * License along with this program; if not, write to the Free Software
41.26 - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307,
41.27 - * USA.
41.28 - */
41.29 -
41.30 -#ifndef __GG_LIBGADU_H
41.31 -#define __GG_LIBGADU_H
41.32 -
41.33 -#ifdef __cplusplus
41.34 -#ifdef _WIN32
41.35 -#pragma pack(push, 1)
41.36 -#endif
41.37 -extern "C" {
41.38 -#endif
41.39 -
41.40 -#include <sys/types.h>
41.41 -#include <stdio.h>
41.42 -#include <stdarg.h>
41.43 -
41.44 -/* Defined if libgadu was compiled for bigendian machine. */
41.45 -#define GG_CONFIG_BIGENDIAN
41.46 -
41.47 -/* Defined if this machine has gethostbyname_r(). */
41.48 -/* #undef GG_CONFIG_HAVE_GETHOSTBYNAME_R */
41.49 -
41.50 -/* Defined if libgadu was compiled and linked with pthread support. */
41.51 -/* #undef GG_CONFIG_HAVE_PTHREAD */
41.52 -
41.53 -/* Defined if this machine has C99-compiliant vsnprintf(). */
41.54 -#define GG_CONFIG_HAVE_C99_VSNPRINTF
41.55 -
41.56 -/* Defined if this machine has va_copy(). */
41.57 -#define GG_CONFIG_HAVE_VA_COPY
41.58 -
41.59 -/* Defined if this machine has __va_copy(). */
41.60 -#define GG_CONFIG_HAVE___VA_COPY
41.61 -
41.62 -/* Defined if this machine supports long long. */
41.63 -#define GG_CONFIG_HAVE_LONG_LONG
41.64 -
41.65 -/* Defined if libgadu was compiled and linked with TLS support. */
41.66 -#define GG_CONFIG_HAVE_OPENSSL
41.67 -
41.68 -/* Defined if uintX_t types are defined in <stdint.h>. */
41.69 -#define GG_CONFIG_HAVE_STDINT_H
41.70 -
41.71 -/* Defined if uintX_t types are defined in <inttypes.h>. */
41.72 -/* #undef GG_CONFIG_HAVE_INTTYPES_H */
41.73 -
41.74 -/* Defined if uintX_t types are defined in <sys/inttypes.h>. */
41.75 -/* #undef GG_CONFIG_HAVE_SYS_INTTYPES_H */
41.76 -
41.77 -/* Defined if uintX_t types are defined in <sys/int_types.h>. */
41.78 -/* #undef GG_CONFIG_HAVE_SYS_INT_TYPES_H */
41.79 -
41.80 -/* Defined if uintX_t types are defined in <sys/types.h>. */
41.81 -/* #undef GG_CONFIG_HAVE_SYS_TYPES_H */
41.82 -
41.83 -#ifdef GG_CONFIG_HAVE_OPENSSL
41.84 -#include <openssl/ssl.h>
41.85 -#endif
41.86 -
41.87 -#ifdef GG_CONFIG_HAVE_STDINT_H
41.88 -#include <stdint.h>
41.89 -#else
41.90 -# ifdef GG_CONFIG_HAVE_INTTYPES_H
41.91 -# include <inttypes.h>
41.92 -# else
41.93 -# ifdef GG_CONFIG_HAVE_SYS_INTTYPES_H
41.94 -# include <sys/inttypes.h>
41.95 -# else
41.96 -# ifdef GG_CONFIG_HAVE_SYS_INT_TYPES_H
41.97 -# include <sys/int_types.h>
41.98 -# else
41.99 -# ifdef GG_CONFIG_HAVE_SYS_TYPES_H
41.100 -# include <sys/types.h>
41.101 -# else
41.102 -
41.103 -#ifndef __AC_STDINT_H
41.104 -#define __AC_STDINT_H
41.105 -
41.106 -/* ISO C 9X: 7.18 Integer types <stdint.h> */
41.107 -
41.108 -typedef unsigned char uint8_t;
41.109 -typedef unsigned short uint16_t;
41.110 -typedef unsigned int uint32_t;
41.111 -
41.112 -#ifndef __CYGWIN__
41.113 -#define __int8_t_defined
41.114 -typedef signed char int8_t;
41.115 -typedef signed short int16_t;
41.116 -typedef signed int int32_t;
41.117 -#endif
41.118 -
41.119 -#endif /* __AC_STDINT_H */
41.120 -
41.121 -# endif
41.122 -# endif
41.123 -# endif
41.124 -# endif
41.125 -#endif
41.126 -
41.127 -/*
41.128 - * typedef uin_t
41.129 - *
41.130 - * typ reprezentuj±cy numer osoby.
41.131 - */
41.132 -typedef uint32_t uin_t;
41.133 -
41.134 -/*
41.135 - * ogólna struktura opisuj±ca ró¿ne sesje. przydatna w klientach.
41.136 - */
41.137 -#define gg_common_head(x) \
41.138 - int fd; /* podgl±dany deskryptor */ \
41.139 - int check; /* sprawdzamy zapis czy odczyt */ \
41.140 - int state; /* aktualny stan maszynki */ \
41.141 - int error; /* kod b³êdu dla GG_STATE_ERROR */ \
41.142 - int type; /* rodzaj sesji */ \
41.143 - int id; /* identyfikator */ \
41.144 - int timeout; /* sugerowany timeout w sekundach */ \
41.145 - int (*callback)(x*); /* callback przy zmianach */ \
41.146 - void (*destroy)(x*); /* funkcja niszczenia */
41.147 -
41.148 -struct gg_common {
41.149 - gg_common_head(struct gg_common)
41.150 -};
41.151 -
41.152 -struct gg_image_queue;
41.153 -
41.154 -/*
41.155 - * struct gg_session
41.156 - *
41.157 - * struktura opisuj±ca dan± sesjê. tworzona przez gg_login(), zwalniana
41.158 - * przez gg_free_session().
41.159 - */
41.160 -struct gg_session {
41.161 - gg_common_head(struct gg_session)
41.162 -
41.163 - int async; /* czy po³±czenie jest asynchroniczne */
41.164 - int pid; /* pid procesu resolvera */
41.165 - int port; /* port, z którym siê ³±czymy */
41.166 - int seq; /* numer sekwencyjny ostatniej wiadomo¶ci */
41.167 - int last_pong; /* czas otrzymania ostatniego ping/pong */
41.168 - int last_event; /* czas otrzymania ostatniego pakietu */
41.169 -
41.170 - struct gg_event *event; /* zdarzenie po ->callback() */
41.171 -
41.172 - uint32_t proxy_addr; /* adres proxy, keszowany */
41.173 - uint16_t proxy_port; /* port proxy */
41.174 -
41.175 - uint32_t hub_addr; /* adres huba po resolvniêciu */
41.176 - uint32_t server_addr; /* adres serwera, od huba */
41.177 -
41.178 - uint32_t client_addr; /* adres klienta */
41.179 - uint16_t client_port; /* port, na którym klient s³ucha */
41.180 -
41.181 - uint32_t external_addr; /* adres zewnetrzny klienta */
41.182 - uint16_t external_port; /* port zewnetrzny klienta */
41.183 -
41.184 - uin_t uin; /* numerek klienta */
41.185 - char *password; /* i jego has³o. zwalniane automagicznie */
41.186 -
41.187 - int initial_status; /* pocz±tkowy stan klienta */
41.188 - int status; /* aktualny stan klienta */
41.189 -
41.190 - char *recv_buf; /* bufor na otrzymywane pakiety */
41.191 - int recv_done; /* ile ju¿ wczytano do bufora */
41.192 - int recv_left; /* i ile jeszcze trzeba wczytaæ */
41.193 -
41.194 - int protocol_version; /* wersja u¿ywanego protoko³u */
41.195 - char *client_version; /* wersja u¿ywanego klienta */
41.196 - int last_sysmsg; /* ostatnia wiadomo¶æ systemowa */
41.197 -
41.198 - char *initial_descr; /* pocz±tkowy opis stanu klienta */
41.199 -
41.200 - void *resolver; /* wska¼nik na informacje resolvera */
41.201 -
41.202 - char *header_buf; /* bufor na pocz±tek nag³ówka */
41.203 - unsigned int header_done;/* ile ju¿ mamy */
41.204 -
41.205 -#ifdef GG_CONFIG_HAVE_OPENSSL
41.206 - SSL *ssl; /* sesja TLS */
41.207 - SSL_CTX *ssl_ctx; /* kontekst sesji? */
41.208 -#else
41.209 - void *ssl; /* zachowujemy ABI */
41.210 - void *ssl_ctx;
41.211 -#endif
41.212 -
41.213 - int image_size; /* maksymalny rozmiar obrazków w KiB */
41.214 -
41.215 - char *userlist_reply; /* fragment odpowiedzi listy kontaktów */
41.216 -
41.217 - int userlist_blocks; /* na ile kawa³ków podzielono listê kontaktów */
41.218 -
41.219 - struct gg_image_queue *images; /* aktualnie wczytywane obrazki */
41.220 -};
41.221 -
41.222 -/*
41.223 - * struct gg_http
41.224 - *
41.225 - * ogólna struktura opisuj±ca stan wszystkich operacji HTTP. tworzona
41.226 - * przez gg_http_connect(), zwalniana przez gg_http_free().
41.227 - */
41.228 -struct gg_http {
41.229 - gg_common_head(struct gg_http)
41.230 -
41.231 - int async; /* czy po³±czenie asynchroniczne */
41.232 - int pid; /* pid procesu resolvera */
41.233 - int port; /* port, z którym siê ³±czymy */
41.234 -
41.235 - char *query; /* bufor zapytania http */
41.236 - char *header; /* bufor nag³ówka */
41.237 - int header_size; /* rozmiar wczytanego nag³ówka */
41.238 - char *body; /* bufor otrzymanych informacji */
41.239 - unsigned int body_size; /* oczekiwana ilo¶æ informacji */
41.240 -
41.241 - void *data; /* dane danej operacji http */
41.242 -
41.243 - char *user_data; /* dane u¿ytkownika, nie s± zwalniane przez gg_http_free() */
41.244 -
41.245 - void *resolver; /* wska¼nik na informacje resolvera */
41.246 -
41.247 - unsigned int body_done; /* ile ju¿ tre¶ci odebrano? */
41.248 -};
41.249 -
41.250 -#ifdef __GNUC__
41.251 -#define GG_PACKED __attribute__ ((packed))
41.252 -#else
41.253 -#define GG_PACKED
41.254 -#endif
41.255 -
41.256 -#define GG_MAX_PATH 276
41.257 -
41.258 -/*
41.259 - * struct gg_file_info
41.260 - *
41.261 - * odpowiednik windowsowej struktury WIN32_FIND_DATA niezbêdnej przy
41.262 - * wysy³aniu plików.
41.263 - */
41.264 -struct gg_file_info {
41.265 - uint32_t mode; /* dwFileAttributes */
41.266 - uint32_t ctime[2]; /* ftCreationTime */
41.267 - uint32_t atime[2]; /* ftLastAccessTime */
41.268 - uint32_t mtime[2]; /* ftLastWriteTime */
41.269 - uint32_t size_hi; /* nFileSizeHigh */
41.270 - uint32_t size; /* nFileSizeLow */
41.271 - uint32_t reserved0; /* dwReserved0 */
41.272 - uint32_t reserved1; /* dwReserved1 */
41.273 - unsigned char filename[GG_MAX_PATH - 14]; /* cFileName */
41.274 - unsigned char short_filename[14]; /* cAlternateFileName */
41.275 -} GG_PACKED;
41.276 -
41.277 -/*
41.278 - * struct gg_dcc
41.279 - *
41.280 - * struktura opisuj±ca nas³uchuj±ce gniazdo po³±czeñ miêdzy klientami.
41.281 - * tworzona przez gg_dcc_socket_create(), zwalniana przez gg_dcc_free().
41.282 - */
41.283 -struct gg_dcc {
41.284 - gg_common_head(struct gg_dcc)
41.285 -
41.286 - struct gg_event *event; /* opis zdarzenia */
41.287 -
41.288 - int active; /* czy to my siê ³±czymy? */
41.289 - int port; /* port, na którym siedzi */
41.290 - uin_t uin; /* uin klienta */
41.291 - uin_t peer_uin; /* uin drugiej strony */
41.292 - int file_fd; /* deskryptor pliku */
41.293 - unsigned int offset; /* offset w pliku */
41.294 - unsigned int chunk_size;/* rozmiar kawa³ka */
41.295 - unsigned int chunk_offset;/* offset w aktualnym kawa³ku */
41.296 - struct gg_file_info file_info;
41.297 - /* informacje o pliku */
41.298 - int established; /* po³±czenie ustanowione */
41.299 - char *voice_buf; /* bufor na pakiet po³±czenia g³osowego */
41.300 - int incoming; /* po³±czenie przychodz±ce */
41.301 - char *chunk_buf; /* bufor na kawa³ek danych */
41.302 - uint32_t remote_addr; /* adres drugiej strony */
41.303 - uint16_t remote_port; /* port drugiej strony */
41.304 -};
41.305 -
41.306 -/*
41.307 - * enum gg_session_t
41.308 - *
41.309 - * rodzaje sesji.
41.310 - */
41.311 -enum gg_session_t {
41.312 - GG_SESSION_GG = 1, /* po³±czenie z serwerem gg */
41.313 - GG_SESSION_HTTP, /* ogólna sesja http */
41.314 - GG_SESSION_SEARCH, /* szukanie */
41.315 - GG_SESSION_REGISTER, /* rejestrowanie */
41.316 - GG_SESSION_REMIND, /* przypominanie has³a */
41.317 - GG_SESSION_PASSWD, /* zmiana has³a */
41.318 - GG_SESSION_CHANGE, /* zmiana informacji o sobie */
41.319 - GG_SESSION_DCC, /* ogólne po³±czenie DCC */
41.320 - GG_SESSION_DCC_SOCKET, /* nas³uchuj±cy socket */
41.321 - GG_SESSION_DCC_SEND, /* wysy³anie pliku */
41.322 - GG_SESSION_DCC_GET, /* odbieranie pliku */
41.323 - GG_SESSION_DCC_VOICE, /* rozmowa g³osowa */
41.324 - GG_SESSION_USERLIST_GET, /* pobieranie userlisty */
41.325 - GG_SESSION_USERLIST_PUT, /* wysy³anie userlisty */
41.326 - GG_SESSION_UNREGISTER, /* usuwanie konta */
41.327 - GG_SESSION_USERLIST_REMOVE, /* usuwanie userlisty */
41.328 - GG_SESSION_TOKEN, /* pobieranie tokenu */
41.329 -
41.330 - GG_SESSION_USER0 = 256, /* zdefiniowana dla u¿ytkownika */
41.331 - GG_SESSION_USER1, /* j.w. */
41.332 - GG_SESSION_USER2, /* j.w. */
41.333 - GG_SESSION_USER3, /* j.w. */
41.334 - GG_SESSION_USER4, /* j.w. */
41.335 - GG_SESSION_USER5, /* j.w. */
41.336 - GG_SESSION_USER6, /* j.w. */
41.337 - GG_SESSION_USER7 /* j.w. */
41.338 -};
41.339 -
41.340 -/*
41.341 - * enum gg_state_t
41.342 - *
41.343 - * opisuje stan asynchronicznej maszyny.
41.344 - */
41.345 -enum gg_state_t {
41.346 - /* wspólne */
41.347 - GG_STATE_IDLE = 0, /* nie powinno wyst±piæ. */
41.348 - GG_STATE_RESOLVING, /* wywo³a³ gethostbyname() */
41.349 - GG_STATE_CONNECTING, /* wywo³a³ connect() */
41.350 - GG_STATE_READING_DATA, /* czeka na dane http */
41.351 - GG_STATE_ERROR, /* wyst±pi³ b³±d. kod w x->error */
41.352 -
41.353 - /* gg_session */
41.354 - GG_STATE_CONNECTING_HUB, /* wywo³a³ connect() na huba */
41.355 - GG_STATE_CONNECTING_GG, /* wywo³a³ connect() na serwer */
41.356 - GG_STATE_READING_KEY, /* czeka na klucz */
41.357 - GG_STATE_READING_REPLY, /* czeka na odpowied¼ */
41.358 - GG_STATE_CONNECTED, /* po³±czy³ siê */
41.359 -
41.360 - /* gg_http */
41.361 - GG_STATE_SENDING_QUERY, /* wysy³a zapytanie http */
41.362 - GG_STATE_READING_HEADER, /* czeka na nag³ówek http */
41.363 - GG_STATE_PARSING, /* przetwarza dane */
41.364 - GG_STATE_DONE, /* skoñczy³ */
41.365 -
41.366 - /* gg_dcc */
41.367 - GG_STATE_LISTENING, /* czeka na po³±czenia */
41.368 - GG_STATE_READING_UIN_1, /* czeka na uin peera */
41.369 - GG_STATE_READING_UIN_2, /* czeka na swój uin */
41.370 - GG_STATE_SENDING_ACK, /* wysy³a potwierdzenie dcc */
41.371 - GG_STATE_READING_ACK, /* czeka na potwierdzenie dcc */
41.372 - GG_STATE_READING_REQUEST, /* czeka na komendê */
41.373 - GG_STATE_SENDING_REQUEST, /* wysy³a komendê */
41.374 - GG_STATE_SENDING_FILE_INFO, /* wysy³a informacje o pliku */
41.375 - GG_STATE_READING_PRE_FILE_INFO, /* czeka na pakiet przed file_info */
41.376 - GG_STATE_READING_FILE_INFO, /* czeka na informacje o pliku */
41.377 - GG_STATE_SENDING_FILE_ACK, /* wysy³a potwierdzenie pliku */
41.378 - GG_STATE_READING_FILE_ACK, /* czeka na potwierdzenie pliku */
41.379 - GG_STATE_SENDING_FILE_HEADER, /* wysy³a nag³ówek pliku */
41.380 - GG_STATE_READING_FILE_HEADER, /* czeka na nag³ówek */
41.381 - GG_STATE_GETTING_FILE, /* odbiera plik */
41.382 - GG_STATE_SENDING_FILE, /* wysy³a plik */
41.383 - GG_STATE_READING_VOICE_ACK, /* czeka na potwierdzenie voip */
41.384 - GG_STATE_READING_VOICE_HEADER, /* czeka na rodzaj bloku voip */
41.385 - GG_STATE_READING_VOICE_SIZE, /* czeka na rozmiar bloku voip */
41.386 - GG_STATE_READING_VOICE_DATA, /* czeka na dane voip */
41.387 - GG_STATE_SENDING_VOICE_ACK, /* wysy³a potwierdzenie voip */
41.388 - GG_STATE_SENDING_VOICE_REQUEST, /* wysy³a ¿±danie voip */
41.389 - GG_STATE_READING_TYPE, /* czeka na typ po³±czenia */
41.390 -
41.391 - /* nowe. bez sensu jest to API. */
41.392 - GG_STATE_TLS_NEGOTIATION /* negocjuje po³±czenie TLS */
41.393 -};
41.394 -
41.395 -/*
41.396 - * enum gg_check_t
41.397 - *
41.398 - * informuje, co proces klienta powinien sprawdziæ na deskryptorze danego
41.399 - * po³±czenia.
41.400 - */
41.401 -enum gg_check_t {
41.402 - GG_CHECK_NONE = 0, /* nic. nie powinno wyst±piæ */
41.403 - GG_CHECK_WRITE = 1, /* sprawdzamy mo¿liwo¶æ zapisu */
41.404 - GG_CHECK_READ = 2 /* sprawdzamy mo¿liwo¶æ odczytu */
41.405 -};
41.406 -
41.407 -/*
41.408 - * struct gg_login_params
41.409 - *
41.410 - * parametry gg_login(). przeniesiono do struktury, ¿eby unikn±æ problemów
41.411 - * z ci±g³ymi zmianami API, gdy dodano co¶ nowego do protoko³u.
41.412 - */
41.413 -struct gg_login_params {
41.414 - uin_t uin; /* numerek */
41.415 - char *password; /* has³o */
41.416 - int async; /* asynchroniczne sockety? */
41.417 - int status; /* pocz±tkowy status klienta */
41.418 - char *status_descr; /* opis statusu */
41.419 - uint32_t server_addr; /* adres serwera gg */
41.420 - uint16_t server_port; /* port serwera gg */
41.421 - uint32_t client_addr; /* adres dcc klienta */
41.422 - uint16_t client_port; /* port dcc klienta */
41.423 - int protocol_version; /* wersja protoko³u */
41.424 - char *client_version; /* wersja klienta */
41.425 - int has_audio; /* czy ma d¼wiêk? */
41.426 - int last_sysmsg; /* ostatnia wiadomo¶æ systemowa */
41.427 - uint32_t external_addr; /* adres widziany na zewnatrz */
41.428 - uint16_t external_port; /* port widziany na zewnatrz */
41.429 - int tls; /* czy ³±czymy po TLS? */
41.430 - int image_size; /* maksymalny rozmiar obrazka w KiB */
41.431 - int era_omnix; /* czy udawaæ klienta era omnix? */
41.432 -
41.433 - char dummy[6 * sizeof(int)]; /* miejsce na kolejnych 6 zmiennych,
41.434 - * ¿eby z dodaniem parametru nie
41.435 - * zmienia³ siê rozmiar struktury */
41.436 -};
41.437 -
41.438 -struct gg_session *gg_login(const struct gg_login_params *p);
41.439 -void gg_free_session(struct gg_session *sess);
41.440 -void gg_logoff(struct gg_session *sess);
41.441 -int gg_change_status(struct gg_session *sess, int status);
41.442 -int gg_change_status_descr(struct gg_session *sess, int status, const char *descr);
41.443 -int gg_change_status_descr_time(struct gg_session *sess, int status, const char *descr, int time);
41.444 -int gg_send_message(struct gg_session *sess, int msgclass, uin_t recipient, const unsigned char *message);
41.445 -int gg_send_message_richtext(struct gg_session *sess, int msgclass, uin_t recipient, const unsigned char *message, const unsigned char *format, int formatlen);
41.446 -int gg_send_message_confer(struct gg_session *sess, int msgclass, int recipients_count, uin_t *recipients, const unsigned char *message);
41.447 -int gg_send_message_confer_richtext(struct gg_session *sess, int msgclass, int recipients_count, uin_t *recipients, const unsigned char *message, const unsigned char *format, int formatlen);
41.448 -int gg_send_message_ctcp(struct gg_session *sess, int msgclass, uin_t recipient, const unsigned char *message, int message_len);
41.449 -int gg_ping(struct gg_session *sess);
41.450 -int gg_userlist_request(struct gg_session *sess, char type, const char *request);
41.451 -int gg_image_request(struct gg_session *sess, uin_t recipient, int size, uint32_t crc32);
41.452 -int gg_image_reply(struct gg_session *sess, uin_t recipient, const char *filename, const char *image, int size);
41.453 -
41.454 -uint32_t gg_crc32(uint32_t crc, const unsigned char *buf, int len);
41.455 -
41.456 -struct gg_image_queue {
41.457 - uin_t sender; /* nadawca obrazka */
41.458 - uint32_t size; /* rozmiar */
41.459 - uint32_t crc32; /* suma kontrolna */
41.460 - char *filename; /* nazwa pliku */
41.461 - char *image; /* bufor z obrazem */
41.462 - uint32_t done; /* ile ju¿ wczytano */
41.463 -
41.464 - struct gg_image_queue *next; /* nastêpny na li¶cie */
41.465 -};
41.466 -
41.467 -/*
41.468 - * enum gg_event_t
41.469 - *
41.470 - * rodzaje zdarzeñ.
41.471 - */
41.472 -enum gg_event_t {
41.473 - GG_EVENT_NONE = 0, /* nic siê nie wydarzy³o */
41.474 - GG_EVENT_MSG, /* otrzymano wiadomo¶æ */
41.475 - GG_EVENT_NOTIFY, /* kto¶ siê pojawi³ */
41.476 - GG_EVENT_NOTIFY_DESCR, /* kto¶ siê pojawi³ z opisem */
41.477 - GG_EVENT_STATUS, /* kto¶ zmieni³ stan */
41.478 - GG_EVENT_ACK, /* potwierdzenie wys³ania wiadomo¶ci */
41.479 - GG_EVENT_PONG, /* pakiet pong */
41.480 - GG_EVENT_CONN_FAILED, /* po³±czenie siê nie uda³o */
41.481 - GG_EVENT_CONN_SUCCESS, /* po³±czenie siê powiod³o */
41.482 - GG_EVENT_DISCONNECT, /* serwer zrywa po³±czenie */
41.483 -
41.484 - GG_EVENT_DCC_NEW, /* nowe po³±czenie miêdzy klientami */
41.485 - GG_EVENT_DCC_ERROR, /* b³±d po³±czenia miêdzy klientami */
41.486 - GG_EVENT_DCC_DONE, /* zakoñczono po³±czenie */
41.487 - GG_EVENT_DCC_CLIENT_ACCEPT, /* moment akceptacji klienta */
41.488 - GG_EVENT_DCC_CALLBACK, /* klient siê po³±czy³ na ¿±danie */
41.489 - GG_EVENT_DCC_NEED_FILE_INFO, /* nale¿y wype³niæ file_info */
41.490 - GG_EVENT_DCC_NEED_FILE_ACK, /* czeka na potwierdzenie pliku */
41.491 - GG_EVENT_DCC_NEED_VOICE_ACK, /* czeka na potwierdzenie rozmowy */
41.492 - GG_EVENT_DCC_VOICE_DATA, /* ramka danych rozmowy g³osowej */
41.493 -
41.494 - GG_EVENT_PUBDIR50_SEARCH_REPLY, /* odpowiedz wyszukiwania */
41.495 - GG_EVENT_PUBDIR50_READ, /* odczytano w³asne dane z katalogu */
41.496 - GG_EVENT_PUBDIR50_WRITE, /* wpisano w³asne dane do katalogu */
41.497 -
41.498 - GG_EVENT_STATUS60, /* kto¶ zmieni³ stan w GG 6.0 */
41.499 - GG_EVENT_NOTIFY60, /* kto¶ siê pojawi³ w GG 6.0 */
41.500 - GG_EVENT_USERLIST, /* odpowied¼ listy kontaktów w GG 6.0 */
41.501 - GG_EVENT_IMAGE_REQUEST, /* pro¶ba o wys³anie obrazka GG 6.0 */
41.502 - GG_EVENT_IMAGE_REPLY, /* podes³any obrazek GG 6.0 */
41.503 - GG_EVENT_DCC_ACK /* potwierdzenie transmisji */
41.504 -};
41.505 -
41.506 -#define GG_EVENT_SEARCH50_REPLY GG_EVENT_PUBDIR50_SEARCH_REPLY
41.507 -
41.508 -/*
41.509 - * enum gg_failure_t
41.510 - *
41.511 - * okre¶la powód nieudanego po³±czenia.
41.512 - */
41.513 -enum gg_failure_t {
41.514 - GG_FAILURE_RESOLVING = 1, /* nie znaleziono serwera */
41.515 - GG_FAILURE_CONNECTING, /* nie mo¿na siê po³±czyæ */
41.516 - GG_FAILURE_INVALID, /* serwer zwróci³ nieprawid³owe dane */
41.517 - GG_FAILURE_READING, /* zerwano po³±czenie podczas odczytu */
41.518 - GG_FAILURE_WRITING, /* zerwano po³±czenie podczas zapisu */
41.519 - GG_FAILURE_PASSWORD, /* nieprawid³owe has³o */
41.520 - GG_FAILURE_404, /* XXX nieu¿ywane */
41.521 - GG_FAILURE_TLS, /* b³±d negocjacji TLS */
41.522 - GG_FAILURE_NEED_EMAIL, /* serwer roz³±czy³ nas z pro¶b± o zmianê emaila */
41.523 - GG_FAILURE_INTRUDER, /* za du¿o prób po³±czenia siê z nieprawid³owym has³em */
41.524 - GG_FAILURE_UNAVAILABLE /* serwery s± wy³±czone */
41.525 -};
41.526 -
41.527 -/*
41.528 - * enum gg_error_t
41.529 - *
41.530 - * okre¶la rodzaj b³êdu wywo³anego przez dan± operacjê. nie zawiera
41.531 - * przesadnie szczegó³owych informacji o powodzie b³êdu, by nie komplikowaæ
41.532 - * obs³ugi b³êdów. je¶li wymagana jest wiêksza dok³adno¶æ, nale¿y sprawdziæ
41.533 - * zawarto¶æ zmiennej errno.
41.534 - */
41.535 -enum gg_error_t {
41.536 - GG_ERROR_RESOLVING = 1, /* b³±d znajdowania hosta */
41.537 - GG_ERROR_CONNECTING, /* b³±d ³aczenia siê */
41.538 - GG_ERROR_READING, /* b³±d odczytu */
41.539 - GG_ERROR_WRITING, /* b³±d wysy³ania */
41.540 -
41.541 - GG_ERROR_DCC_HANDSHAKE, /* b³±d negocjacji */
41.542 - GG_ERROR_DCC_FILE, /* b³±d odczytu/zapisu pliku */
41.543 - GG_ERROR_DCC_EOF, /* plik siê skoñczy³? */
41.544 - GG_ERROR_DCC_NET, /* b³±d wysy³ania/odbierania */
41.545 - GG_ERROR_DCC_REFUSED /* po³±czenie odrzucone przez usera */
41.546 -};
41.547 -
41.548 -/*
41.549 - * struktury dotycz±ce wyszukiwania w GG 5.0. NIE NALE¯Y SIÊ DO NICH
41.550 - * ODWO£YWAÆ BEZPO¦REDNIO! do dostêpu do nich s³u¿± funkcje gg_pubdir50_*()
41.551 - */
41.552 -struct gg_pubdir50_entry {
41.553 - int num;
41.554 - char *field;
41.555 - char *value;
41.556 -};
41.557 -
41.558 -struct gg_pubdir50_s {
41.559 - int count;
41.560 - uin_t next;
41.561 - int type;
41.562 - uint32_t seq;
41.563 - struct gg_pubdir50_entry *entries;
41.564 - int entries_count;
41.565 -};
41.566 -
41.567 -/*
41.568 - * typedef gg_pubdir_50_t
41.569 - *
41.570 - * typ opisuj±cy zapytanie lub wynik zapytania katalogu publicznego
41.571 - * z protoko³u GG 5.0. nie nale¿y siê odwo³ywaæ bezpo¶rednio do jego
41.572 - * pól -- s³u¿± do tego funkcje gg_pubdir50_*()
41.573 - */
41.574 -typedef struct gg_pubdir50_s *gg_pubdir50_t;
41.575 -
41.576 -/*
41.577 - * struct gg_event
41.578 - *
41.579 - * struktura opisuj±ca rodzaj zdarzenia. wychodzi z gg_watch_fd() lub
41.580 - * z gg_dcc_watch_fd()
41.581 - */
41.582 -struct gg_event {
41.583 - int type; /* rodzaj zdarzenia -- gg_event_t */
41.584 - union { /* @event */
41.585 - struct gg_notify_reply *notify; /* informacje o li¶cie kontaktów -- GG_EVENT_NOTIFY */
41.586 -
41.587 - enum gg_failure_t failure; /* b³±d po³±czenia -- GG_EVENT_FAILURE */
41.588 -
41.589 - struct gg_dcc *dcc_new; /* nowe po³±czenie bezpo¶rednie -- GG_EVENT_DCC_NEW */
41.590 -
41.591 - int dcc_error; /* b³±d po³±czenia bezpo¶redniego -- GG_EVENT_DCC_ERROR */
41.592 -
41.593 - gg_pubdir50_t pubdir50; /* wynik operacji zwi±zanej z katalogiem publicznym -- GG_EVENT_PUBDIR50_* */
41.594 -
41.595 - struct { /* @msg odebrano wiadomo¶æ -- GG_EVENT_MSG */
41.596 - uin_t sender; /* numer nadawcy */
41.597 - int msgclass; /* klasa wiadomo¶ci */
41.598 - time_t time; /* czas nadania */
41.599 - unsigned char *message; /* tre¶æ wiadomo¶ci */
41.600 -
41.601 - int recipients_count; /* ilo¶æ odbiorców konferencji */
41.602 - uin_t *recipients; /* odbiorcy konferencji */
41.603 -
41.604 - int formats_length; /* d³ugo¶æ informacji o formatowaniu tekstu */
41.605 - void *formats; /* informacje o formatowaniu tekstu */
41.606 - } msg;
41.607 -
41.608 - struct { /* @notify_descr informacje o li¶cie kontaktów z opisami stanu -- GG_EVENT_NOTIFY_DESCR */
41.609 - struct gg_notify_reply *notify; /* informacje o li¶cie kontaktów */
41.610 - char *descr; /* opis stanu */
41.611 - } notify_descr;
41.612 -
41.613 - struct { /* @status zmiana stanu -- GG_EVENT_STATUS */
41.614 - uin_t uin; /* numer */
41.615 - uint32_t status; /* nowy stan */
41.616 - char *descr; /* opis stanu */
41.617 - } status;
41.618 -
41.619 - struct { /* @status60 zmiana stanu -- GG_EVENT_STATUS60 */
41.620 - uin_t uin; /* numer */
41.621 - int status; /* nowy stan */
41.622 - uint32_t remote_ip; /* adres ip */
41.623 - uint16_t remote_port; /* port */
41.624 - int version; /* wersja klienta */
41.625 - int image_size; /* maksymalny rozmiar grafiki w KiB */
41.626 - char *descr; /* opis stanu */
41.627 - time_t time; /* czas powrotu */
41.628 - } status60;
41.629 -
41.630 - struct { /* @notify60 informacja o li¶cie kontaktów -- GG_EVENT_NOTIFY60 */
41.631 - uin_t uin; /* numer */
41.632 - int status; /* stan */
41.633 - uint32_t remote_ip; /* adres ip */
41.634 - uint16_t remote_port; /* port */
41.635 - int version; /* wersja klienta */
41.636 - int image_size; /* maksymalny rozmiar grafiki w KiB */
41.637 - char *descr; /* opis stanu */
41.638 - time_t time; /* czas powrotu */
41.639 - } *notify60;
41.640 -
41.641 - struct { /* @ack potwierdzenie wiadomo¶ci -- GG_EVENT_ACK */
41.642 - uin_t recipient; /* numer odbiorcy */
41.643 - int status; /* stan dorêczenia wiadomo¶ci */
41.644 - int seq; /* numer sekwencyjny wiadomo¶ci */
41.645 - } ack;
41.646 -
41.647 - struct { /* @dcc_voice_data otrzymano dane d¼wiêkowe -- GG_EVENT_DCC_VOICE_DATA */
41.648 - uint8_t *data; /* dane d¼wiêkowe */
41.649 - int length; /* ilo¶æ danych d¼wiêkowych */
41.650 - } dcc_voice_data;
41.651 -
41.652 - struct { /* @userlist odpowied¼ listy kontaktów serwera */
41.653 - char type; /* rodzaj odpowiedzi */
41.654 - char *reply; /* tre¶æ odpowiedzi */
41.655 - } userlist;
41.656 -
41.657 - struct { /* @image_request pro¶ba o obrazek */
41.658 - uin_t sender; /* nadawca pro¶by */
41.659 - uint32_t size; /* rozmiar obrazka */
41.660 - uint32_t crc32; /* suma kontrolna */
41.661 - } image_request;
41.662 -
41.663 - struct { /* @image_reply odpowied¼ z obrazkiem */
41.664 - uin_t sender; /* nadawca odpowiedzi */
41.665 - uint32_t size; /* rozmiar obrazka */
41.666 - uint32_t crc32; /* suma kontrolna */
41.667 - char *filename; /* nazwa pliku */
41.668 - char *image; /* bufor z obrazkiem */
41.669 - } image_reply;
41.670 - } event;
41.671 -};
41.672 -
41.673 -struct gg_event *gg_watch_fd(struct gg_session *sess);
41.674 -void gg_event_free(struct gg_event *e);
41.675 -#define gg_free_event gg_event_free
41.676 -
41.677 -/*
41.678 - * funkcje obs³ugi listy kontaktów.
41.679 - */
41.680 -int gg_notify_ex(struct gg_session *sess, uin_t *userlist, char *types, int count);
41.681 -int gg_notify(struct gg_session *sess, uin_t *userlist, int count);
41.682 -int gg_add_notify_ex(struct gg_session *sess, uin_t uin, char type);
41.683 -int gg_add_notify(struct gg_session *sess, uin_t uin);
41.684 -int gg_remove_notify_ex(struct gg_session *sess, uin_t uin, char type);
41.685 -int gg_remove_notify(struct gg_session *sess, uin_t uin);
41.686 -
41.687 -/*
41.688 - * funkcje obs³ugi http.
41.689 - */
41.690 -struct gg_http *gg_http_connect(const char *hostname, int port, int async, const char *method, const char *path, const char *header);
41.691 -int gg_http_watch_fd(struct gg_http *h);
41.692 -void gg_http_stop(struct gg_http *h);
41.693 -void gg_http_free(struct gg_http *h);
41.694 -void gg_http_free_fields(struct gg_http *h);
41.695 -#define gg_free_http gg_http_free
41.696 -
41.697 -/*
41.698 - * struktury opisuj±ca kryteria wyszukiwania dla gg_search(). nieaktualne,
41.699 - * zast±pione przez gg_pubdir50_t. pozostawiono je dla zachowania ABI.
41.700 - */
41.701 -struct gg_search_request {
41.702 - int active;
41.703 - unsigned int start;
41.704 - char *nickname;
41.705 - char *first_name;
41.706 - char *last_name;
41.707 - char *city;
41.708 - int gender;
41.709 - int min_birth;
41.710 - int max_birth;
41.711 - char *email;
41.712 - char *phone;
41.713 - uin_t uin;
41.714 -};
41.715 -
41.716 -struct gg_search {
41.717 - int count;
41.718 - struct gg_search_result *results;
41.719 -};
41.720 -
41.721 -struct gg_search_result {
41.722 - uin_t uin;
41.723 - char *first_name;
41.724 - char *last_name;
41.725 - char *nickname;
41.726 - int born;
41.727 - int gender;
41.728 - char *city;
41.729 - int active;
41.730 -};
41.731 -
41.732 -#define GG_GENDER_NONE 0
41.733 -#define GG_GENDER_FEMALE 1
41.734 -#define GG_GENDER_MALE 2
41.735 -
41.736 -/*
41.737 - * funkcje wyszukiwania.
41.738 - */
41.739 -struct gg_http *gg_search(const struct gg_search_request *r, int async);
41.740 -int gg_search_watch_fd(struct gg_http *f);
41.741 -void gg_free_search(struct gg_http *f);
41.742 -#define gg_search_free gg_free_search
41.743 -
41.744 -const struct gg_search_request *gg_search_request_mode_0(char *nickname, char *first_name, char *last_name, char *city, int gender, int min_birth, int max_birth, int active, int start);
41.745 -const struct gg_search_request *gg_search_request_mode_1(char *email, int active, int start);
41.746 -const struct gg_search_request *gg_search_request_mode_2(char *phone, int active, int start);
41.747 -const struct gg_search_request *gg_search_request_mode_3(uin_t uin, int active, int start);
41.748 -void gg_search_request_free(struct gg_search_request *r);
41.749 -
41.750 -/*
41.751 - * funkcje obs³ugi katalogu publicznego zgodne z GG 5.0. tym razem funkcje
41.752 - * zachowuj± pewien poziom abstrakcji, ¿eby unikn±æ zmian ABI przy zmianach
41.753 - * w protokole.
41.754 - *
41.755 - * NIE NALE¯Y SIÊ ODWO£YWAÆ DO PÓL gg_pubdir50_t BEZPO¦REDNIO!
41.756 - */
41.757 -uint32_t gg_pubdir50(struct gg_session *sess, gg_pubdir50_t req);
41.758 -gg_pubdir50_t gg_pubdir50_new(int type);
41.759 -int gg_pubdir50_add(gg_pubdir50_t req, const char *field, const char *value);
41.760 -int gg_pubdir50_seq_set(gg_pubdir50_t req, uint32_t seq);
41.761 -const char *gg_pubdir50_get(gg_pubdir50_t res, int num, const char *field);
41.762 -int gg_pubdir50_type(gg_pubdir50_t res);
41.763 -int gg_pubdir50_count(gg_pubdir50_t res);
41.764 -uin_t gg_pubdir50_next(gg_pubdir50_t res);
41.765 -uint32_t gg_pubdir50_seq(gg_pubdir50_t res);
41.766 -void gg_pubdir50_free(gg_pubdir50_t res);
41.767 -
41.768 -#define GG_PUBDIR50_UIN "FmNumber"
41.769 -#define GG_PUBDIR50_STATUS "FmStatus"
41.770 -#define GG_PUBDIR50_FIRSTNAME "firstname"
41.771 -#define GG_PUBDIR50_LASTNAME "lastname"
41.772 -#define GG_PUBDIR50_NICKNAME "nickname"
41.773 -#define GG_PUBDIR50_BIRTHYEAR "birthyear"
41.774 -#define GG_PUBDIR50_CITY "city"
41.775 -#define GG_PUBDIR50_GENDER "gender"
41.776 -#define GG_PUBDIR50_GENDER_FEMALE "1"
41.777 -#define GG_PUBDIR50_GENDER_MALE "2"
41.778 -#define GG_PUBDIR50_GENDER_SET_FEMALE "2"
41.779 -#define GG_PUBDIR50_GENDER_SET_MALE "1"
41.780 -#define GG_PUBDIR50_ACTIVE "ActiveOnly"
41.781 -#define GG_PUBDIR50_ACTIVE_TRUE "1"
41.782 -#define GG_PUBDIR50_START "fmstart"
41.783 -#define GG_PUBDIR50_FAMILYNAME "familyname"
41.784 -#define GG_PUBDIR50_FAMILYCITY "familycity"
41.785 -
41.786 -int gg_pubdir50_handle_reply(struct gg_event *e, const char *packet, int length);
41.787 -
41.788 -/*
41.789 - * struct gg_pubdir
41.790 - *
41.791 - * operacje na katalogu publicznym.
41.792 - */
41.793 -struct gg_pubdir {
41.794 - int success; /* czy siê uda³o */
41.795 - uin_t uin; /* otrzymany numerek. 0 je¶li b³±d */
41.796 -};
41.797 -
41.798 -/* ogólne funkcje, nie powinny byæ u¿ywane */
41.799 -int gg_pubdir_watch_fd(struct gg_http *f);
41.800 -void gg_pubdir_free(struct gg_http *f);
41.801 -#define gg_free_pubdir gg_pubdir_free
41.802 -
41.803 -struct gg_token {
41.804 - int width; /* szeroko¶æ obrazka */
41.805 - int height; /* wysoko¶æ obrazka */
41.806 - int length; /* ilo¶æ znaków w tokenie */
41.807 - char *tokenid; /* id tokenu */
41.808 -};
41.809 -
41.810 -/* funkcje dotycz±ce tokenów */
41.811 -struct gg_http *gg_token(int async);
41.812 -int gg_token_watch_fd(struct gg_http *h);
41.813 -void gg_token_free(struct gg_http *h);
41.814 -
41.815 -/* rejestracja nowego numerka */
41.816 -struct gg_http *gg_register(const char *email, const char *password, int async);
41.817 -struct gg_http *gg_register2(const char *email, const char *password, const char *qa, int async);
41.818 -struct gg_http *gg_register3(const char *email, const char *password, const char *tokenid, const char *tokenval, int async);
41.819 -#define gg_register_watch_fd gg_pubdir_watch_fd
41.820 -#define gg_register_free gg_pubdir_free
41.821 -#define gg_free_register gg_pubdir_free
41.822 -
41.823 -struct gg_http *gg_unregister(uin_t uin, const char *password, const char *email, int async);
41.824 -struct gg_http *gg_unregister2(uin_t uin, const char *password, const char *qa, int async);
41.825 -struct gg_http *gg_unregister3(uin_t uin, const char *password, const char *tokenid, const char *tokenval, int async);
41.826 -#define gg_unregister_watch_fd gg_pubdir_watch_fd
41.827 -#define gg_unregister_free gg_pubdir_free
41.828 -
41.829 -/* przypomnienie has³a e-mailem */
41.830 -struct gg_http *gg_remind_passwd(uin_t uin, int async);
41.831 -struct gg_http *gg_remind_passwd2(uin_t uin, const char *tokenid, const char *tokenval, int async);
41.832 -struct gg_http *gg_remind_passwd3(uin_t uin, const char *email, const char *tokenid, const char *tokenval, int async);
41.833 -#define gg_remind_passwd_watch_fd gg_pubdir_watch_fd
41.834 -#define gg_remind_passwd_free gg_pubdir_free
41.835 -#define gg_free_remind_passwd gg_pubdir_free
41.836 -
41.837 -/* zmiana has³a */
41.838 -struct gg_http *gg_change_passwd(uin_t uin, const char *passwd, const char *newpasswd, const char *newemail, int async);
41.839 -struct gg_http *gg_change_passwd2(uin_t uin, const char *passwd, const char *newpasswd, const char *email, const char *newemail, int async);
41.840 -struct gg_http *gg_change_passwd3(uin_t uin, const char *passwd, const char *newpasswd, const char *qa, int async);
41.841 -struct gg_http *gg_change_passwd4(uin_t uin, const char *email, const char *passwd, const char *newpasswd, const char *tokenid, const char *tokenval, int async);
41.842 -#define gg_change_passwd_free gg_pubdir_free
41.843 -#define gg_free_change_passwd gg_pubdir_free
41.844 -
41.845 -/*
41.846 - * struct gg_change_info_request
41.847 - *
41.848 - * opis ¿±dania zmiany informacji w katalogu publicznym.
41.849 - */
41.850 -struct gg_change_info_request {
41.851 - char *first_name; /* imiê */
41.852 - char *last_name; /* nazwisko */
41.853 - char *nickname; /* pseudonim */
41.854 - char *email; /* email */
41.855 - int born; /* rok urodzenia */
41.856 - int gender; /* p³eæ */
41.857 - char *city; /* miasto */
41.858 -};
41.859 -
41.860 -struct gg_change_info_request *gg_change_info_request_new(const char *first_name, const char *last_name, const char *nickname, const char *email, int born, int gender, const char *city);
41.861 -void gg_change_info_request_free(struct gg_change_info_request *r);
41.862 -
41.863 -struct gg_http *gg_change_info(uin_t uin, const char *passwd, const struct gg_change_info_request *request, int async);
41.864 -#define gg_change_pubdir_watch_fd gg_pubdir_watch_fd
41.865 -#define gg_change_pubdir_free gg_pubdir_free
41.866 -#define gg_free_change_pubdir gg_pubdir_free
41.867 -
41.868 -/*
41.869 - * funkcje dotycz±ce listy kontaktów na serwerze.
41.870 - */
41.871 -struct gg_http *gg_userlist_get(uin_t uin, const char *password, int async);
41.872 -int gg_userlist_get_watch_fd(struct gg_http *f);
41.873 -void gg_userlist_get_free(struct gg_http *f);
41.874 -
41.875 -struct gg_http *gg_userlist_put(uin_t uin, const char *password, const char *contacts, int async);
41.876 -int gg_userlist_put_watch_fd(struct gg_http *f);
41.877 -void gg_userlist_put_free(struct gg_http *f);
41.878 -
41.879 -struct gg_http *gg_userlist_remove(uin_t uin, const char *password, int async);
41.880 -int gg_userlist_remove_watch_fd(struct gg_http *f);
41.881 -void gg_userlist_remove_free(struct gg_http *f);
41.882 -
41.883 -
41.884 -
41.885 -/*
41.886 - * funkcje dotycz±ce komunikacji miêdzy klientami.
41.887 - */
41.888 -extern int gg_dcc_port; /* port, na którym nas³uchuje klient */
41.889 -extern unsigned long gg_dcc_ip; /* adres, na którym nas³uchuje klient */
41.890 -
41.891 -int gg_dcc_request(struct gg_session *sess, uin_t uin);
41.892 -
41.893 -struct gg_dcc *gg_dcc_send_file(uint32_t ip, uint16_t port, uin_t my_uin, uin_t peer_uin);
41.894 -struct gg_dcc *gg_dcc_get_file(uint32_t ip, uint16_t port, uin_t my_uin, uin_t peer_uin);
41.895 -struct gg_dcc *gg_dcc_voice_chat(uint32_t ip, uint16_t port, uin_t my_uin, uin_t peer_uin);
41.896 -void gg_dcc_set_type(struct gg_dcc *d, int type);
41.897 -int gg_dcc_fill_file_info(struct gg_dcc *d, const char *filename);
41.898 -int gg_dcc_fill_file_info2(struct gg_dcc *d, const char *filename, const char *local_filename);
41.899 -int gg_dcc_voice_send(struct gg_dcc *d, char *buf, int length);
41.900 -
41.901 -#define GG_DCC_VOICE_FRAME_LENGTH 195
41.902 -#define GG_DCC_VOICE_FRAME_LENGTH_505 326
41.903 -
41.904 -struct gg_dcc *gg_dcc_socket_create(uin_t uin, uint16_t port);
41.905 -#define gg_dcc_socket_free gg_free_dcc
41.906 -#define gg_dcc_socket_watch_fd gg_dcc_watch_fd
41.907 -
41.908 -struct gg_event *gg_dcc_watch_fd(struct gg_dcc *d);
41.909 -
41.910 -void gg_dcc_free(struct gg_dcc *c);
41.911 -#define gg_free_dcc gg_dcc_free
41.912 -
41.913 -/*
41.914 - * je¶li chcemy sobie podebugowaæ, wystarczy ustawiæ `gg_debug_level'.
41.915 - * niestety w miarê przybywania wpisów `gg_debug(...)' nie chcia³o mi
41.916 - * siê ustawiaæ odpowiednich leveli, wiêc wiêkszo¶æ sz³a do _MISC.
41.917 - */
41.918 -extern int gg_debug_level; /* poziom debugowania. mapa bitowa sta³ych GG_DEBUG_* */
41.919 -
41.920 -/*
41.921 - * mo¿na podaæ wska¼nik do funkcji obs³uguj±cej wywo³ania gg_debug().
41.922 - * nieoficjalne, nieudokumentowane, mo¿e siê zmieniæ. je¶li kto¶ jest
41.923 - * zainteresowany, niech da znaæ na ekg-devel.
41.924 - */
41.925 -extern void (*gg_debug_handler)(int level, const char *format, va_list ap);
41.926 -extern void (*gg_debug_handler_session)(struct gg_session *sess, int level, const char *format, va_list ap);
41.927 -
41.928 -/*
41.929 - * mo¿na podaæ plik, do którego bêd± zapisywane teksty z gg_debug().
41.930 - */
41.931 -extern FILE *gg_debug_file;
41.932 -
41.933 -#define GG_DEBUG_NET 1
41.934 -#define GG_DEBUG_TRAFFIC 2
41.935 -#define GG_DEBUG_DUMP 4
41.936 -#define GG_DEBUG_FUNCTION 8
41.937 -#define GG_DEBUG_MISC 16
41.938 -
41.939 -#ifdef GG_DEBUG_DISABLE
41.940 -#define gg_debug(x, y...) do { } while(0)
41.941 -#define gg_debug_session(z, x, y...) do { } while(0)
41.942 -#else
41.943 -void gg_debug(int level, const char *format, ...);
41.944 -void gg_debug_session(struct gg_session *sess, int level, const char *format, ...);
41.945 -#endif
41.946 -
41.947 -const char *gg_libgadu_version(void);
41.948 -
41.949 -/*
41.950 - * konfiguracja http proxy.
41.951 - */
41.952 -extern int gg_proxy_enabled; /* w³±cza obs³ugê proxy */
41.953 -extern char *gg_proxy_host; /* okre¶la adres serwera proxy */
41.954 -extern int gg_proxy_port; /* okre¶la port serwera proxy */
41.955 -extern char *gg_proxy_username; /* okre¶la nazwê u¿ytkownika przy autoryzacji serwera proxy */
41.956 -extern char *gg_proxy_password; /* okre¶la has³o u¿ytkownika przy autoryzacji serwera proxy */
41.957 -extern int gg_proxy_http_only; /* w³±cza obs³ugê proxy wy³±cznie dla us³ug HTTP */
41.958 -
41.959 -
41.960 -/*
41.961 - * adres, z którego ¶lemy pakiety (np ³±czymy siê z serwerem)
41.962 - * u¿ywany przy gg_connect()
41.963 - */
41.964 -extern unsigned long gg_local_ip;
41.965 -/*
41.966 - * -------------------------------------------------------------------------
41.967 - * poni¿ej znajduj± siê wewnêtrzne sprawy biblioteki. zwyk³y klient nie
41.968 - * powinien ich w ogóle ruszaæ, bo i nie ma po co. wszystko mo¿na za³atwiæ
41.969 - * procedurami wy¿szego poziomu, których definicje znajduj± siê na pocz±tku
41.970 - * tego pliku.
41.971 - * -------------------------------------------------------------------------
41.972 - */
41.973 -
41.974 -#ifdef GG_CONFIG_HAVE_PTHREAD
41.975 -int gg_resolve_pthread(int *fd, void **resolver, const char *hostname);
41.976 -void gg_resolve_pthread_cleanup(void *resolver, int kill);
41.977 -#endif
41.978 -
41.979 -#ifdef _WIN32
41.980 -int gg_thread_socket(int thread_id, int socket);
41.981 -#endif
41.982 -
41.983 -int gg_resolve(int *fd, int *pid, const char *hostname);
41.984 -
41.985 -#ifdef __GNUC__
41.986 -char *gg_saprintf(const char *format, ...) __attribute__ ((format (printf, 1, 2)));
41.987 -#else
41.988 -char *gg_saprintf(const char *format, ...);
41.989 -#endif
41.990 -
41.991 -char *gg_vsaprintf(const char *format, va_list ap);
41.992 -
41.993 -#define gg_alloc_sprintf gg_saprintf
41.994 -
41.995 -char *gg_get_line(char **ptr);
41.996 -
41.997 -int gg_connect(void *addr, int port, int async);
41.998 -struct in_addr *gg_gethostbyname(const char *hostname);
41.999 -char *gg_read_line(int sock, char *buf, int length);
41.1000 -void gg_chomp(char *line);
41.1001 -char *gg_urlencode(const char *str);
41.1002 -int gg_http_hash(const char *format, ...);
41.1003 -int gg_read(struct gg_session *sess, char *buf, int length);
41.1004 -int gg_write(struct gg_session *sess, const char *buf, int length);
41.1005 -void *gg_recv_packet(struct gg_session *sess);
41.1006 -int gg_send_packet(struct gg_session *sess, int type, ...);
41.1007 -unsigned int gg_login_hash(const unsigned char *password, unsigned int seed);
41.1008 -uint32_t gg_fix32(uint32_t x);
41.1009 -uint16_t gg_fix16(uint16_t x);
41.1010 -#define fix16 gg_fix16
41.1011 -#define fix32 gg_fix32
41.1012 -char *gg_proxy_auth(void);
41.1013 -char *gg_base64_encode(const char *buf);
41.1014 -char *gg_base64_decode(const char *buf);
41.1015 -int gg_image_queue_remove(struct gg_session *s, struct gg_image_queue *q, int freeq);
41.1016 -
41.1017 -#define GG_APPMSG_HOST "appmsg.gadu-gadu.pl"
41.1018 -#define GG_APPMSG_PORT 80
41.1019 -#define GG_PUBDIR_HOST "pubdir.gadu-gadu.pl"
41.1020 -#define GG_PUBDIR_PORT 80
41.1021 -#define GG_REGISTER_HOST "register.gadu-gadu.pl"
41.1022 -#define GG_REGISTER_PORT 80
41.1023 -#define GG_REMIND_HOST "retr.gadu-gadu.pl"
41.1024 -#define GG_REMIND_PORT 80
41.1025 -
41.1026 -#define GG_DEFAULT_PORT 8074
41.1027 -#define GG_HTTPS_PORT 443
41.1028 -#define GG_HTTP_USERAGENT "Mozilla/4.7 [en] (Win98; I)"
41.1029 -
41.1030 -#define GG_DEFAULT_CLIENT_VERSION "6, 1, 0, 158"
41.1031 -#define GG_DEFAULT_PROTOCOL_VERSION 0x24
41.1032 -#define GG_DEFAULT_TIMEOUT 30
41.1033 -#define GG_HAS_AUDIO_MASK 0x40000000
41.1034 -#define GG_ERA_OMNIX_MASK 0x04000000
41.1035 -#define GG_LIBGADU_VERSION "CVS"
41.1036 -
41.1037 -#define GG_DEFAULT_DCC_PORT 1550
41.1038 -
41.1039 -struct gg_header {
41.1040 - uint32_t type; /* typ pakietu */
41.1041 - uint32_t length; /* d³ugo¶æ reszty pakietu */
41.1042 -} GG_PACKED;
41.1043 -
41.1044 -#define GG_WELCOME 0x0001
41.1045 -#define GG_NEED_EMAIL 0x0014
41.1046 -
41.1047 -struct gg_welcome {
41.1048 - uint32_t key; /* klucz szyfrowania has³a */
41.1049 -} GG_PACKED;
41.1050 -
41.1051 -#define GG_LOGIN 0x000c
41.1052 -
41.1053 -struct gg_login {
41.1054 - uint32_t uin; /* mój numerek */
41.1055 - uint32_t hash; /* hash has³a */
41.1056 - uint32_t status; /* status na dzieñ dobry */
41.1057 - uint32_t version; /* moja wersja klienta */
41.1058 - uint32_t local_ip; /* mój adres ip */
41.1059 - uint16_t local_port; /* port, na którym s³ucham */
41.1060 -} GG_PACKED;
41.1061 -
41.1062 -#define GG_LOGIN_EXT 0x0013
41.1063 -
41.1064 -struct gg_login_ext {
41.1065 - uint32_t uin; /* mój numerek */
41.1066 - uint32_t hash; /* hash has³a */
41.1067 - uint32_t status; /* status na dzieñ dobry */
41.1068 - uint32_t version; /* moja wersja klienta */
41.1069 - uint32_t local_ip; /* mój adres ip */
41.1070 - uint16_t local_port; /* port, na którym s³ucham */
41.1071 - uint32_t external_ip; /* zewnêtrzny adres ip */
41.1072 - uint16_t external_port; /* zewnêtrzny port */
41.1073 -} GG_PACKED;
41.1074 -
41.1075 -#define GG_LOGIN60 0x0015
41.1076 -
41.1077 -struct gg_login60 {
41.1078 - uint32_t uin; /* mój numerek */
41.1079 - uint32_t hash; /* hash has³a */
41.1080 - uint32_t status; /* status na dzieñ dobry */
41.1081 - uint32_t version; /* moja wersja klienta */
41.1082 - uint8_t dunno1; /* 0x00 */
41.1083 - uint32_t local_ip; /* mój adres ip */
41.1084 - uint16_t local_port; /* port, na którym s³ucham */
41.1085 - uint32_t external_ip; /* zewnêtrzny adres ip */
41.1086 - uint16_t external_port; /* zewnêtrzny port */
41.1087 - uint8_t image_size; /* maksymalny rozmiar grafiki w KiB */
41.1088 - uint8_t dunno2; /* 0xbe */
41.1089 -} GG_PACKED;
41.1090 -
41.1091 -#define GG_LOGIN_OK 0x0003
41.1092 -
41.1093 -#define GG_LOGIN_FAILED 0x0009
41.1094 -
41.1095 -#define GG_PUBDIR50_REQUEST 0x0014
41.1096 -
41.1097 -#define GG_PUBDIR50_WRITE 0x01
41.1098 -#define GG_PUBDIR50_READ 0x02
41.1099 -#define GG_PUBDIR50_SEARCH 0x03
41.1100 -#define GG_PUBDIR50_SEARCH_REQUEST GG_PUBDIR50_SEARCH
41.1101 -#define GG_PUBDIR50_SEARCH_REPLY 0x05
41.1102 -
41.1103 -struct gg_pubdir50_request {
41.1104 - uint8_t type; /* GG_PUBDIR50_* */
41.1105 - uint32_t seq; /* czas wys³ania zapytania */
41.1106 -} GG_PACKED;
41.1107 -
41.1108 -#define GG_PUBDIR50_REPLY 0x000e
41.1109 -
41.1110 -struct gg_pubdir50_reply {
41.1111 - uint8_t type; /* GG_PUBDIR50_* */
41.1112 - uint32_t seq; /* czas wys³ania zapytania */
41.1113 -} GG_PACKED;
41.1114 -
41.1115 -#define GG_NEW_STATUS 0x0002
41.1116 -
41.1117 -#define GG_STATUS_NOT_AVAIL 0x0001 /* niedostêpny */
41.1118 -#define GG_STATUS_NOT_AVAIL_DESCR 0x0015 /* niedostêpny z opisem (4.8) */
41.1119 -#define GG_STATUS_AVAIL 0x0002 /* dostêpny */
41.1120 -#define GG_STATUS_AVAIL_DESCR 0x0004 /* dostêpny z opisem (4.9) */
41.1121 -#define GG_STATUS_BUSY 0x0003 /* zajêty */
41.1122 -#define GG_STATUS_BUSY_DESCR 0x0005 /* zajêty z opisem (4.8) */
41.1123 -#define GG_STATUS_INVISIBLE 0x0014 /* niewidoczny (4.6) */
41.1124 -#define GG_STATUS_INVISIBLE_DESCR 0x0016 /* niewidoczny z opisem (4.9) */
41.1125 -#define GG_STATUS_BLOCKED 0x0006 /* zablokowany */
41.1126 -
41.1127 -#define GG_STATUS_FRIENDS_MASK 0x8000 /* tylko dla znajomych (4.6) */
41.1128 -
41.1129 -#define GG_STATUS_DESCR_MAXSIZE 70
41.1130 -
41.1131 -/*
41.1132 - * makra do ³atwego i szybkiego sprawdzania stanu.
41.1133 - */
41.1134 -
41.1135 -/* GG_S_F() tryb tylko dla znajomych */
41.1136 -#define GG_S_F(x) (((x) & GG_STATUS_FRIENDS_MASK) != 0)
41.1137 -
41.1138 -/* GG_S() stan bez uwzglêdnienia trybu tylko dla znajomych */
41.1139 -#define GG_S(x) ((x) & ~GG_STATUS_FRIENDS_MASK)
41.1140 -
41.1141 -/* GG_S_A() dostêpny */
41.1142 -#define GG_S_A(x) (GG_S(x) == GG_STATUS_AVAIL || GG_S(x) == GG_STATUS_AVAIL_DESCR)
41.1143 -
41.1144 -/* GG_S_NA() niedostêpny */
41.1145 -#define GG_S_NA(x) (GG_S(x) == GG_STATUS_NOT_AVAIL || GG_S(x) == GG_STATUS_NOT_AVAIL_DESCR)
41.1146 -
41.1147 -/* GG_S_B() zajêty */
41.1148 -#define GG_S_B(x) (GG_S(x) == GG_STATUS_BUSY || GG_S(x) == GG_STATUS_BUSY_DESCR)
41.1149 -
41.1150 -/* GG_S_I() niewidoczny */
41.1151 -#define GG_S_I(x) (GG_S(x) == GG_STATUS_INVISIBLE || GG_S(x) == GG_STATUS_INVISIBLE_DESCR)
41.1152 -
41.1153 -/* GG_S_D() stan opisowy */
41.1154 -#define GG_S_D(x) (GG_S(x) == GG_STATUS_NOT_AVAIL_DESCR || GG_S(x) == GG_STATUS_AVAIL_DESCR || GG_S(x) == GG_STATUS_BUSY_DESCR || GG_S(x) == GG_STATUS_INVISIBLE_DESCR)
41.1155 -
41.1156 -/* GG_S_BL() blokowany lub blokuj±cy */
41.1157 -#define GG_S_BL(x) (GG_S(x) == GG_STATUS_BLOCKED)
41.1158 -
41.1159 -struct gg_new_status {
41.1160 - uint32_t status; /* na jaki zmieniæ? */
41.1161 -} GG_PACKED;
41.1162 -
41.1163 -#define GG_NOTIFY_FIRST 0x000f
41.1164 -#define GG_NOTIFY_LAST 0x0010
41.1165 -
41.1166 -#define GG_NOTIFY 0x0010
41.1167 -
41.1168 -struct gg_notify {
41.1169 - uint32_t uin; /* numerek danej osoby */
41.1170 - uint8_t dunno1; /* rodzaj wpisu w li¶cie */
41.1171 -} GG_PACKED;
41.1172 -
41.1173 -#define GG_USER_OFFLINE 0x01 /* bêdziemy niewidoczni dla u¿ytkownika */
41.1174 -#define GG_USER_NORMAL 0x03 /* zwyk³y u¿ytkownik */
41.1175 -#define GG_USER_BLOCKED 0x04 /* zablokowany u¿ytkownik */
41.1176 -
41.1177 -#define GG_LIST_EMPTY 0x0012
41.1178 -
41.1179 -#define GG_NOTIFY_REPLY 0x000c /* tak, to samo co GG_LOGIN */
41.1180 -
41.1181 -struct gg_notify_reply {
41.1182 - uint32_t uin; /* numerek */
41.1183 - uint32_t status; /* status danej osoby */
41.1184 - uint32_t remote_ip; /* adres ip delikwenta */
41.1185 - uint16_t remote_port; /* port, na którym s³ucha klient */
41.1186 - uint32_t version; /* wersja klienta */
41.1187 - uint16_t dunno2; /* znowu port? */
41.1188 -} GG_PACKED;
41.1189 -
41.1190 -#define GG_NOTIFY_REPLY60 0x0011
41.1191 -
41.1192 -struct gg_notify_reply60 {
41.1193 - uint32_t uin; /* numerek plus flagi w MSB */
41.1194 - uint8_t status; /* status danej osoby */
41.1195 - uint32_t remote_ip; /* adres ip delikwenta */
41.1196 - uint16_t remote_port; /* port, na którym s³ucha klient */
41.1197 - uint8_t version; /* wersja klienta */
41.1198 - uint8_t image_size; /* maksymalny rozmiar grafiki w KiB */
41.1199 - uint8_t dunno1; /* 0x00 */
41.1200 -} GG_PACKED;
41.1201 -
41.1202 -#define GG_STATUS60 0x000f
41.1203 -
41.1204 -struct gg_status60 {
41.1205 - uint32_t uin; /* numerek plus flagi w MSB */
41.1206 - uint8_t status; /* status danej osoby */
41.1207 - uint32_t remote_ip; /* adres ip delikwenta */
41.1208 - uint16_t remote_port; /* port, na którym s³ucha klient */
41.1209 - uint8_t version; /* wersja klienta */
41.1210 - uint8_t image_size; /* maksymalny rozmiar grafiki w KiB */
41.1211 - uint8_t dunno1; /* 0x00 */
41.1212 -} GG_PACKED;
41.1213 -
41.1214 -#define GG_ADD_NOTIFY 0x000d
41.1215 -#define GG_REMOVE_NOTIFY 0x000e
41.1216 -
41.1217 -struct gg_add_remove {
41.1218 - uint32_t uin; /* numerek */
41.1219 - uint8_t dunno1; /* bitmapa */
41.1220 -} GG_PACKED;
41.1221 -
41.1222 -#define GG_STATUS 0x0002
41.1223 -
41.1224 -struct gg_status {
41.1225 - uint32_t uin; /* numerek */
41.1226 - uint32_t status; /* nowy stan */
41.1227 -} GG_PACKED;
41.1228 -
41.1229 -#define GG_SEND_MSG 0x000b
41.1230 -
41.1231 -#define GG_CLASS_QUEUED 0x0001
41.1232 -#define GG_CLASS_OFFLINE GG_CLASS_QUEUED
41.1233 -#define GG_CLASS_MSG 0x0004
41.1234 -#define GG_CLASS_CHAT 0x0008
41.1235 -#define GG_CLASS_CTCP 0x0010
41.1236 -#define GG_CLASS_ACK 0x0020
41.1237 -#define GG_CLASS_EXT GG_CLASS_ACK /* kompatybilno¶æ wstecz */
41.1238 -
41.1239 -#define GG_MSG_MAXSIZE 2000
41.1240 -
41.1241 -struct gg_send_msg {
41.1242 - uint32_t recipient;
41.1243 - uint32_t seq;
41.1244 - uint32_t msgclass;
41.1245 -} GG_PACKED;
41.1246 -
41.1247 -struct gg_msg_richtext {
41.1248 - uint8_t flag;
41.1249 - uint16_t length;
41.1250 -} GG_PACKED;
41.1251 -
41.1252 -struct gg_msg_richtext_format {
41.1253 - uint16_t position;
41.1254 - uint8_t font;
41.1255 -} GG_PACKED;
41.1256 -
41.1257 -struct gg_msg_richtext_image {
41.1258 - uint16_t unknown1;
41.1259 - uint32_t size;
41.1260 - uint32_t crc32;
41.1261 -} GG_PACKED;
41.1262 -
41.1263 -#define GG_FONT_BOLD 0x01
41.1264 -#define GG_FONT_ITALIC 0x02
41.1265 -#define GG_FONT_UNDERLINE 0x04
41.1266 -#define GG_FONT_COLOR 0x08
41.1267 -#define GG_FONT_IMAGE 0x80
41.1268 -
41.1269 -struct gg_msg_richtext_color {
41.1270 - uint8_t red;
41.1271 - uint8_t green;
41.1272 - uint8_t blue;
41.1273 -} GG_PACKED;
41.1274 -
41.1275 -struct gg_msg_recipients {
41.1276 - uint8_t flag;
41.1277 - uint32_t count;
41.1278 -} GG_PACKED;
41.1279 -
41.1280 -struct gg_msg_image_request {
41.1281 - uint8_t flag;
41.1282 - uint32_t size;
41.1283 - uint32_t crc32;
41.1284 -} GG_PACKED;
41.1285 -
41.1286 -struct gg_msg_image_reply {
41.1287 - uint8_t flag;
41.1288 - uint32_t size;
41.1289 - uint32_t crc32;
41.1290 - /* char filename[]; */
41.1291 - /* char image[]; */
41.1292 -} GG_PACKED;
41.1293 -
41.1294 -#define GG_SEND_MSG_ACK 0x0005
41.1295 -
41.1296 -#define GG_ACK_BLOCKED 0x0001
41.1297 -#define GG_ACK_DELIVERED 0x0002
41.1298 -#define GG_ACK_QUEUED 0x0003
41.1299 -#define GG_ACK_MBOXFULL 0x0004
41.1300 -#define GG_ACK_NOT_DELIVERED 0x0006
41.1301 -
41.1302 -struct gg_send_msg_ack {
41.1303 - uint32_t status;
41.1304 - uint32_t recipient;
41.1305 - uint32_t seq;
41.1306 -} GG_PACKED;
41.1307 -
41.1308 -#define GG_RECV_MSG 0x000a
41.1309 -
41.1310 -struct gg_recv_msg {
41.1311 - uint32_t sender;
41.1312 - uint32_t seq;
41.1313 - uint32_t time;
41.1314 - uint32_t msgclass;
41.1315 -} GG_PACKED;
41.1316 -
41.1317 -#define GG_PING 0x0008
41.1318 -
41.1319 -#define GG_PONG 0x0007
41.1320 -
41.1321 -#define GG_DISCONNECTING 0x000b
41.1322 -
41.1323 -#define GG_USERLIST_REQUEST 0x0016
41.1324 -
41.1325 -#define GG_USERLIST_PUT 0x00
41.1326 -#define GG_USERLIST_PUT_MORE 0x01
41.1327 -#define GG_USERLIST_GET 0x02
41.1328 -
41.1329 -struct gg_userlist_request {
41.1330 - uint8_t type;
41.1331 -} GG_PACKED;
41.1332 -
41.1333 -#define GG_USERLIST_REPLY 0x0010
41.1334 -
41.1335 -#define GG_USERLIST_PUT_REPLY 0x00
41.1336 -#define GG_USERLIST_PUT_MORE_REPLY 0x02
41.1337 -#define GG_USERLIST_GET_REPLY 0x06
41.1338 -#define GG_USERLIST_GET_MORE_REPLY 0x04
41.1339 -
41.1340 -struct gg_userlist_reply {
41.1341 - uint8_t type;
41.1342 -} GG_PACKED;
41.1343 -
41.1344 -/*
41.1345 - * pakiety, sta³e, struktury dla DCC
41.1346 - */
41.1347 -
41.1348 -struct gg_dcc_tiny_packet {
41.1349 - uint8_t type; /* rodzaj pakietu */
41.1350 -} GG_PACKED;
41.1351 -
41.1352 -struct gg_dcc_small_packet {
41.1353 - uint32_t type; /* rodzaj pakietu */
41.1354 -} GG_PACKED;
41.1355 -
41.1356 -struct gg_dcc_big_packet {
41.1357 - uint32_t type; /* rodzaj pakietu */
41.1358 - uint32_t dunno1; /* niewiadoma */
41.1359 - uint32_t dunno2; /* niewiadoma */
41.1360 -} GG_PACKED;
41.1361 -
41.1362 -/*
41.1363 - * póki co, nie znamy dok³adnie protoko³u. nie wiemy, co czemu odpowiada.
41.1364 - * nazwy s± niepowa¿ne i tymczasowe.
41.1365 - */
41.1366 -#define GG_DCC_WANT_FILE 0x0003 /* peer chce plik */
41.1367 -#define GG_DCC_HAVE_FILE 0x0001 /* wiêc mu damy */
41.1368 -#define GG_DCC_HAVE_FILEINFO 0x0003 /* niech ma informacje o pliku */
41.1369 -#define GG_DCC_GIMME_FILE 0x0006 /* peer jest pewny */
41.1370 -#define GG_DCC_CATCH_FILE 0x0002 /* wysy³amy plik */
41.1371 -
41.1372 -#define GG_DCC_FILEATTR_READONLY 0x0020
41.1373 -
41.1374 -#define GG_DCC_TIMEOUT_SEND 1800 /* 30 minut */
41.1375 -#define GG_DCC_TIMEOUT_GET 1800 /* 30 minut */
41.1376 -#define GG_DCC_TIMEOUT_FILE_ACK 300 /* 5 minut */
41.1377 -#define GG_DCC_TIMEOUT_VOICE_ACK 300 /* 5 minut */
41.1378 -
41.1379 -#ifdef __cplusplus
41.1380 -}
41.1381 -#ifdef _WIN32
41.1382 -#pragma pack(pop)
41.1383 -#endif
41.1384 -#endif
41.1385 -
41.1386 -#endif /* __GG_LIBGADU_H */
41.1387 -
41.1388 -/*
41.1389 - * Local variables:
41.1390 - * c-indentation-style: k&r
41.1391 - * c-basic-offset: 8
41.1392 - * indent-tabs-mode: notnil
41.1393 - * End:
41.1394 - *
41.1395 - * vim: shiftwidth=8:
41.1396 - */
42.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/libgadu.h Sun Jun 21 22:04:11 2009 -0400
42.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
42.3 @@ -1,7 +0,0 @@
42.4 -#ifdef __ppc__
42.5 -#include "libgadu-ppc.h"
42.6 -#elif defined(__i386__)
42.7 -#include "libgadu-i386.h"
42.8 -#else
42.9 -#error This isn't a recognized platform.
42.10 -#endif
43.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/libpurple.h Sun Jun 21 22:04:11 2009 -0400
43.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
43.3 @@ -1,22 +0,0 @@
43.4 -#include <libpurple/gaim-compat.h>
43.5 -#include <libpurple/connection.h>
43.6 -#include <libpurple/conversation.h>
43.7 -#include <libpurple/core.h>
43.8 -#include <libpurple/debug.h>
43.9 -#include <libpurple/dnsquery.h>
43.10 -#include <libpurple/ft.h>
43.11 -#include <libpurple/imgstore.h>
43.12 -#include <libpurple/network.h>
43.13 -#include <libpurple/notify.h>
43.14 -#include <libpurple/plugin.h>
43.15 -#include <libpurple/pounce.h>
43.16 -#include <libpurple/prefs.h>
43.17 -#include <libpurple/privacy.h>
43.18 -#include <libpurple/proxy.h>
43.19 -#include <libpurple/request.h>
43.20 -#include <libpurple/roomlist.h>
43.21 -#include <libpurple/signals.h>
43.22 -#include <libpurple/sslconn.h>
43.23 -#include <libpurple/sound.h>
43.24 -#include <libpurple/util.h>
43.25 -#include <libpurple/whiteboard.h>
44.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/log.h Sun Jun 21 22:04:11 2009 -0400
44.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
44.3 @@ -1,570 +0,0 @@
44.4 -/**
44.5 - * @file log.h Logging API
44.6 - * @ingroup core
44.7 - * @see @ref log-signals
44.8 - */
44.9 -
44.10 -/* purple
44.11 - *
44.12 - * Purple is the legal property of its developers, whose names are too numerous
44.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
44.14 - * source distribution.
44.15 - *
44.16 - * This program is free software; you can redistribute it and/or modify
44.17 - * it under the terms of the GNU General Public License as published by
44.18 - * the Free Software Foundation; either version 2 of the License, or
44.19 - * (at your option) any later version.
44.20 - *
44.21 - * This program is distributed in the hope that it will be useful,
44.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
44.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
44.24 - * GNU General Public License for more details.
44.25 - *
44.26 - * You should have received a copy of the GNU General Public License
44.27 - * along with this program; if not, write to the Free Software
44.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
44.29 - */
44.30 -#ifndef _PURPLE_LOG_H_
44.31 -#define _PURPLE_LOG_H_
44.32 -
44.33 -#include <stdio.h>
44.34 -
44.35 -
44.36 -/********************************************************
44.37 - * DATA STRUCTURES **************************************
44.38 - ********************************************************/
44.39 -
44.40 -typedef struct _PurpleLog PurpleLog;
44.41 -typedef struct _PurpleLogLogger PurpleLogLogger;
44.42 -typedef struct _PurpleLogCommonLoggerData PurpleLogCommonLoggerData;
44.43 -typedef struct _PurpleLogSet PurpleLogSet;
44.44 -
44.45 -typedef enum {
44.46 - PURPLE_LOG_IM,
44.47 - PURPLE_LOG_CHAT,
44.48 - PURPLE_LOG_SYSTEM
44.49 -} PurpleLogType;
44.50 -
44.51 -typedef enum {
44.52 - PURPLE_LOG_READ_NO_NEWLINE = 1
44.53 -} PurpleLogReadFlags;
44.54 -
44.55 -#include "account.h"
44.56 -#include "conversation.h"
44.57 -
44.58 -typedef void (*PurpleLogSetCallback) (GHashTable *sets, PurpleLogSet *set);
44.59 -
44.60 -/**
44.61 - * A log logger.
44.62 - *
44.63 - * This struct gets filled out and is included in the PurpleLog. It contains everything
44.64 - * needed to write and read from logs.
44.65 - */
44.66 -struct _PurpleLogLogger {
44.67 - char *name; /**< The logger's name */
44.68 - char *id; /**< an identifier to refer to this logger */
44.69 -
44.70 - /** This gets called when the log is first created.
44.71 - I don't think this is actually needed. */
44.72 - void (*create)(PurpleLog *log);
44.73 -
44.74 - /** This is used to write to the log file */
44.75 - gsize (*write)(PurpleLog *log,
44.76 - PurpleMessageFlags type,
44.77 - const char *from,
44.78 - time_t time,
44.79 - const char *message);
44.80 -
44.81 - /** Called when the log is destroyed */
44.82 - void (*finalize)(PurpleLog *log);
44.83 -
44.84 - /** This function returns a sorted GList of available PurpleLogs */
44.85 - GList *(*list)(PurpleLogType type, const char *name, PurpleAccount *account);
44.86 -
44.87 - /** Given one of the logs returned by the logger's list function,
44.88 - * this returns the contents of the log in GtkIMHtml markup */
44.89 - char *(*read)(PurpleLog *log, PurpleLogReadFlags *flags);
44.90 -
44.91 - /** Given one of the logs returned by the logger's list function,
44.92 - * this returns the size of the log in bytes */
44.93 - int (*size)(PurpleLog *log);
44.94 -
44.95 - /** Returns the total size of all the logs. If this is undefined a default
44.96 - * implementation is used */
44.97 - int (*total_size)(PurpleLogType type, const char *name, PurpleAccount *account);
44.98 -
44.99 - /** This function returns a sorted GList of available system PurpleLogs */
44.100 - GList *(*list_syslog)(PurpleAccount *account);
44.101 -
44.102 - /** Adds PurpleLogSets to a GHashTable. By passing the data in the PurpleLogSets
44.103 - * to list, the caller can get every available PurpleLog from the logger.
44.104 - * Loggers using purple_log_common_writer() (or otherwise storing their
44.105 - * logs in the same directory structure as the stock loggers) do not
44.106 - * need to implement this function.
44.107 - *
44.108 - * Loggers which implement this function must create a PurpleLogSet,
44.109 - * then call @a cb with @a sets and the newly created PurpleLogSet. */
44.110 - void (*get_log_sets)(PurpleLogSetCallback cb, GHashTable *sets);
44.111 -
44.112 - /* Attempts to delete the specified log, indicating success or failure */
44.113 - gboolean (*remove)(PurpleLog *log);
44.114 -
44.115 - /* Tests whether a log is deletable */
44.116 - gboolean (*is_deletable)(PurpleLog *log);
44.117 -
44.118 - void (*_purple_reserved1)(void);
44.119 - void (*_purple_reserved2)(void);
44.120 - void (*_purple_reserved3)(void);
44.121 - void (*_purple_reserved4)(void);
44.122 -};
44.123 -
44.124 -/**
44.125 - * A log. Not the wooden type.
44.126 - */
44.127 -struct _PurpleLog {
44.128 - PurpleLogType type; /**< The type of log this is */
44.129 - char *name; /**< The name of this log */
44.130 - PurpleAccount *account; /**< The account this log is taking
44.131 - place on */
44.132 - PurpleConversation *conv; /**< The conversation being logged */
44.133 - time_t time; /**< The time this conversation
44.134 - started, converted to the local timezone */
44.135 -
44.136 - PurpleLogLogger *logger; /**< The logging mechanism this log
44.137 - is to use */
44.138 - void *logger_data; /**< Data used by the log logger */
44.139 - struct tm *tm; /**< The time this conversation
44.140 - started, saved with original
44.141 - timezone data, if available and
44.142 - if struct tm has the BSD
44.143 - timezone fields, else @c NULL.
44.144 - Do NOT modify anything in this struct.*/
44.145 -
44.146 - /* IMPORTANT: Some code in log.c allocates these without zeroing them.
44.147 - * IMPORTANT: Update that code if you add members here. */
44.148 -};
44.149 -
44.150 -/**
44.151 - * A common logger_data struct containing a file handle and path, as well
44.152 - * as a pointer to something else for additional data.
44.153 - */
44.154 -struct _PurpleLogCommonLoggerData {
44.155 - char *path;
44.156 - FILE *file;
44.157 - void *extra_data;
44.158 -};
44.159 -
44.160 -/**
44.161 - * Describes available logs.
44.162 - *
44.163 - * By passing the elements of this struct to purple_log_get_logs(), the caller
44.164 - * can get all available PurpleLogs.
44.165 - */
44.166 -struct _PurpleLogSet {
44.167 - PurpleLogType type; /**< The type of logs available */
44.168 - char *name; /**< The name of the logs available */
44.169 - PurpleAccount *account; /**< The account the available logs
44.170 - took place on. This will be
44.171 - @c NULL if the account no longer
44.172 - exists. (Depending on a
44.173 - logger's implementation of
44.174 - list, it may not be possible
44.175 - to load such logs.) */
44.176 - gboolean buddy; /**< Is this (account, name) a buddy
44.177 - on the buddy list? */
44.178 - char *normalized_name; /**< The normalized version of
44.179 - @a name. It must be set, and
44.180 - may be set to the same pointer
44.181 - value as @a name. */
44.182 -
44.183 - /* IMPORTANT: Some code in log.c allocates these without zeroing them.
44.184 - * IMPORTANT: Update that code if you add members here. */
44.185 -};
44.186 -
44.187 -#ifdef __cplusplus
44.188 -extern "C" {
44.189 -#endif
44.190 -
44.191 -/***************************************/
44.192 -/** @name Log Functions */
44.193 -/***************************************/
44.194 -/*@{*/
44.195 -
44.196 -/**
44.197 - * Creates a new log
44.198 - *
44.199 - * @param type The type of log this is.
44.200 - * @param name The name of this conversation (screenname, chat name,
44.201 - * etc.)
44.202 - * @param account The account the conversation is occurring on
44.203 - * @param conv The conversation being logged
44.204 - * @param time The time this conversation started
44.205 - * @param tm The time this conversation started, with timezone data,
44.206 - * if available and if struct tm has the BSD timezone fields.
44.207 - * @return The new log
44.208 - */
44.209 -PurpleLog *purple_log_new(PurpleLogType type, const char *name, PurpleAccount *account,
44.210 - PurpleConversation *conv, time_t time, const struct tm *tm);
44.211 -
44.212 -/**
44.213 - * Frees a log
44.214 - *
44.215 - * @param log The log to destroy
44.216 - */
44.217 -void purple_log_free(PurpleLog *log);
44.218 -
44.219 -/**
44.220 - * Writes to a log file. Assumes you have checked preferences already.
44.221 - *
44.222 - * @param log The log to write to
44.223 - * @param type The type of message being logged
44.224 - * @param from Whom this message is coming from, or @c NULL for
44.225 - * system messages
44.226 - * @param time A timestamp in UNIX time
44.227 - * @param message The message to log
44.228 - */
44.229 -void purple_log_write(PurpleLog *log,
44.230 - PurpleMessageFlags type,
44.231 - const char *from,
44.232 - time_t time,
44.233 - const char *message);
44.234 -
44.235 -/**
44.236 - * Reads from a log
44.237 - *
44.238 - * @param log The log to read from
44.239 - * @param flags The returned logging flags.
44.240 - *
44.241 - * @return The contents of this log in Purple Markup.
44.242 - */
44.243 -char *purple_log_read(PurpleLog *log, PurpleLogReadFlags *flags);
44.244 -
44.245 -/**
44.246 - * Returns a list of all available logs
44.247 - *
44.248 - * @param type The type of the log
44.249 - * @param name The name of the log
44.250 - * @param account The account
44.251 - * @return A sorted list of PurpleLogs
44.252 - */
44.253 -GList *purple_log_get_logs(PurpleLogType type, const char *name, PurpleAccount *account);
44.254 -
44.255 -/**
44.256 - * Returns a GHashTable of PurpleLogSets.
44.257 - *
44.258 - * A "log set" here means the information necessary to gather the
44.259 - * PurpleLogs for a given buddy/chat. This information would be passed
44.260 - * to purple_log_list to get a list of PurpleLogs.
44.261 - *
44.262 - * The primary use of this function is to get a list of everyone the
44.263 - * user has ever talked to (assuming he or she uses logging).
44.264 - *
44.265 - * The GHashTable that's returned will free all log sets in it when
44.266 - * destroyed. If a PurpleLogSet is removed from the GHashTable, it
44.267 - * must be freed with purple_log_set_free().
44.268 - *
44.269 - * @return A GHashTable of all available unique PurpleLogSets
44.270 - */
44.271 -GHashTable *purple_log_get_log_sets(void);
44.272 -
44.273 -/**
44.274 - * Returns a list of all available system logs
44.275 - *
44.276 - * @param account The account
44.277 - * @return A sorted list of PurpleLogs
44.278 - */
44.279 -GList *purple_log_get_system_logs(PurpleAccount *account);
44.280 -
44.281 -/**
44.282 - * Returns the size of a log
44.283 - *
44.284 - * @param log The log
44.285 - * @return The size of the log, in bytes
44.286 - */
44.287 -int purple_log_get_size(PurpleLog *log);
44.288 -
44.289 -/**
44.290 - * Returns the size, in bytes, of all available logs in this conversation
44.291 - *
44.292 - * @param type The type of the log
44.293 - * @param name The name of the log
44.294 - * @param account The account
44.295 - * @return The size in bytes
44.296 - */
44.297 -int purple_log_get_total_size(PurpleLogType type, const char *name, PurpleAccount *account);
44.298 -
44.299 -/**
44.300 - * Tests whether a log is deletable
44.301 - *
44.302 - * A return value of @c FALSE indicates that purple_log_delete() will fail on this
44.303 - * log, unless something changes between the two calls. A return value of @c TRUE,
44.304 - * however, does not guarantee the log can be deleted.
44.305 - *
44.306 - * @param log The log
44.307 - * @return A boolean indicating if the log is deletable
44.308 - */
44.309 -gboolean purple_log_is_deletable(PurpleLog *log);
44.310 -
44.311 -/**
44.312 - * Deletes a log
44.313 - *
44.314 - * @param log The log
44.315 - * @return A boolean indicating success or failure
44.316 - */
44.317 -gboolean purple_log_delete(PurpleLog *log);
44.318 -
44.319 -/**
44.320 - * Returns the default logger directory Purple uses for a given account
44.321 - * and username. This would be where Purple stores logs created by
44.322 - * the built-in text or HTML loggers.
44.323 - *
44.324 - * @param type The type of the log.
44.325 - * @param name The name of the log.
44.326 - * @param account The account.
44.327 - * @return The default logger directory for Purple.
44.328 - */
44.329 -char *purple_log_get_log_dir(PurpleLogType type, const char *name, PurpleAccount *account);
44.330 -
44.331 -/**
44.332 - * Implements GCompareFunc for PurpleLogs
44.333 - *
44.334 - * @param y A PurpleLog
44.335 - * @param z Another PurpleLog
44.336 - * @return A value as specified by GCompareFunc
44.337 - */
44.338 -gint purple_log_compare(gconstpointer y, gconstpointer z);
44.339 -
44.340 -/**
44.341 - * Implements GCompareFunc for PurpleLogSets
44.342 - *
44.343 - * @param y A PurpleLogSet
44.344 - * @param z Another PurpleLogSet
44.345 - * @return A value as specified by GCompareFunc
44.346 - */
44.347 -gint purple_log_set_compare(gconstpointer y, gconstpointer z);
44.348 -
44.349 -/**
44.350 - * Frees a log set
44.351 - *
44.352 - * @param set The log set to destroy
44.353 - */
44.354 -void purple_log_set_free(PurpleLogSet *set);
44.355 -
44.356 -/*@}*/
44.357 -
44.358 -/******************************************/
44.359 -/** @name Common Logger Functions */
44.360 -/******************************************/
44.361 -/*@{*/
44.362 -
44.363 -/**
44.364 - * Opens a new log file in the standard Purple log location
44.365 - * with the given file extension, named for the current time,
44.366 - * for writing. If a log file is already open, the existing
44.367 - * file handle is retained. The log's logger_data value is
44.368 - * set to a PurpleLogCommonLoggerData struct containing the log
44.369 - * file handle and log path.
44.370 - *
44.371 - * This function is intended to be used as a "common"
44.372 - * implementation of a logger's @c write function.
44.373 - * It should only be passed to purple_log_logger_new() and never
44.374 - * called directly.
44.375 - *
44.376 - * @param log The log to write to.
44.377 - * @param ext The file extension to give to this log file.
44.378 - */
44.379 -void purple_log_common_writer(PurpleLog *log, const char *ext);
44.380 -
44.381 -/**
44.382 - * Returns a sorted GList of PurpleLogs of the requested type.
44.383 - *
44.384 - * This function should only be used with logs that are written
44.385 - * with purple_log_common_writer(). It's intended to be used as
44.386 - * a "common" implementation of a logger's @c list function.
44.387 - * It should only be passed to purple_log_logger_new() and never
44.388 - * called directly.
44.389 - *
44.390 - * @param type The type of the logs being listed.
44.391 - * @param name The name of the log.
44.392 - * @param account The account of the log.
44.393 - * @param ext The file extension this log format uses.
44.394 - * @param logger A reference to the logger struct for this log.
44.395 - *
44.396 - * @return A sorted GList of PurpleLogs matching the parameters.
44.397 - */
44.398 -GList *purple_log_common_lister(PurpleLogType type, const char *name,
44.399 - PurpleAccount *account, const char *ext,
44.400 - PurpleLogLogger *logger);
44.401 -
44.402 -/**
44.403 - * Returns the total size of all the logs for a given user, with
44.404 - * a given extension.
44.405 - *
44.406 - * This function should only be used with logs that are written
44.407 - * with purple_log_common_writer(). It's intended to be used as
44.408 - * a "common" implementation of a logger's @c total_size function.
44.409 - * It should only be passed to purple_log_logger_new() and never
44.410 - * called directly.
44.411 - *
44.412 - * @param type The type of the logs being sized.
44.413 - * @param name The name of the logs to size
44.414 - * (e.g. the username or chat name).
44.415 - * @param account The account of the log.
44.416 - * @param ext The file extension this log format uses.
44.417 - *
44.418 - * @return The size of all the logs with the specified extension
44.419 - * for the specified user.
44.420 - */
44.421 -int purple_log_common_total_sizer(PurpleLogType type, const char *name,
44.422 - PurpleAccount *account, const char *ext);
44.423 -
44.424 -/**
44.425 - * Returns the size of a given PurpleLog.
44.426 - *
44.427 - * This function should only be used with logs that are written
44.428 - * with purple_log_common_writer(). It's intended to be used as
44.429 - * a "common" implementation of a logger's @c size function.
44.430 - * It should only be passed to purple_log_logger_new() and never
44.431 - * called directly.
44.432 - *
44.433 - * @param log The PurpleLog to size.
44.434 - *
44.435 - * @return An integer indicating the size of the log in bytes.
44.436 - */
44.437 -int purple_log_common_sizer(PurpleLog *log);
44.438 -
44.439 -/**
44.440 - * Deletes a log
44.441 - *
44.442 - * This function should only be used with logs that are written
44.443 - * with purple_log_common_writer(). It's intended to be used as
44.444 - * a "common" implementation of a logger's @c delete function.
44.445 - * It should only be passed to purple_log_logger_new() and never
44.446 - * called directly.
44.447 - *
44.448 - * @param log The PurpleLog to delete.
44.449 - *
44.450 - * @return A boolean indicating success or failure.
44.451 - */
44.452 -gboolean purple_log_common_deleter(PurpleLog *log);
44.453 -
44.454 -/**
44.455 - * Checks to see if a log is deletable
44.456 - *
44.457 - * This function should only be used with logs that are written
44.458 - * with purple_log_common_writer(). It's intended to be used as
44.459 - * a "common" implementation of a logger's @c is_deletable function.
44.460 - * It should only be passed to purple_log_logger_new() and never
44.461 - * called directly.
44.462 - *
44.463 - * @param log The PurpleLog to check.
44.464 - *
44.465 - * @return A boolean indicating if the log is deletable.
44.466 - */
44.467 -gboolean purple_log_common_is_deletable(PurpleLog *log);
44.468 -
44.469 -/*@}*/
44.470 -
44.471 -/******************************************/
44.472 -/** @name Logger Functions */
44.473 -/******************************************/
44.474 -/*@{*/
44.475 -
44.476 -/**
44.477 - * Creates a new logger
44.478 - *
44.479 - * @param id The logger's id.
44.480 - * @param name The logger's name.
44.481 - * @param functions The number of functions being passed. The following
44.482 - * functions are currently available (in order): @c create,
44.483 - * @c write, @c finalize, @c list, @c read, @c size,
44.484 - * @c total_size, @c list_syslog, @c get_log_sets,
44.485 - * @c remove, @c is_deletable.
44.486 - * For details on these functions, see PurpleLogLogger.
44.487 - * Functions may not be skipped. For example, passing
44.488 - * @c create and @c write is acceptable (for a total of
44.489 - * two functions). Passing @c create and @c finalize,
44.490 - * however, is not. To accomplish that, the caller must
44.491 - * pass @c create, @c NULL (a placeholder for @c write),
44.492 - * and @c finalize (for a total of 3 functions).
44.493 - *
44.494 - * @return The new logger
44.495 - */
44.496 -PurpleLogLogger *purple_log_logger_new(const char *id, const char *name, int functions, ...);
44.497 -
44.498 -/**
44.499 - * Frees a logger
44.500 - *
44.501 - * @param logger The logger to free
44.502 - */
44.503 -void purple_log_logger_free(PurpleLogLogger *logger);
44.504 -
44.505 -/**
44.506 - * Adds a new logger
44.507 - *
44.508 - * @param logger The new logger to add
44.509 - */
44.510 -void purple_log_logger_add (PurpleLogLogger *logger);
44.511 -
44.512 -/**
44.513 - *
44.514 - * Removes a logger
44.515 - *
44.516 - * @param logger The logger to remove
44.517 - */
44.518 -void purple_log_logger_remove (PurpleLogLogger *logger);
44.519 -
44.520 -/**
44.521 - *
44.522 - * Sets the current logger
44.523 - *
44.524 - * @param logger The logger to set
44.525 - */
44.526 -void purple_log_logger_set (PurpleLogLogger *logger);
44.527 -
44.528 -/**
44.529 - *
44.530 - * Returns the current logger
44.531 - *
44.532 - * @return logger The current logger
44.533 - */
44.534 -PurpleLogLogger *purple_log_logger_get (void);
44.535 -
44.536 -/**
44.537 - * Returns a GList containing the IDs and names of the registered
44.538 - * loggers.
44.539 - *
44.540 - * @return The list of IDs and names.
44.541 - */
44.542 -GList *purple_log_logger_get_options(void);
44.543 -
44.544 -/**************************************************************************/
44.545 -/** @name Log Subsystem */
44.546 -/**************************************************************************/
44.547 -/*@{*/
44.548 -
44.549 -/**
44.550 - * Initializes the log subsystem.
44.551 - */
44.552 -void purple_log_init(void);
44.553 -
44.554 -/**
44.555 - * Returns the log subsystem handle.
44.556 - *
44.557 - * @return The log subsystem handle.
44.558 - */
44.559 -void *purple_log_get_handle(void);
44.560 -
44.561 -/**
44.562 - * Uninitializes the log subsystem.
44.563 - */
44.564 -void purple_log_uninit(void);
44.565 -
44.566 -/*@}*/
44.567 -
44.568 -
44.569 -#ifdef __cplusplus
44.570 -}
44.571 -#endif
44.572 -
44.573 -#endif /* _PURPLE_LOG_H_ */
45.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/mime.h Sun Jun 21 22:04:11 2009 -0400
45.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
45.3 @@ -1,219 +0,0 @@
45.4 -/*
45.5 - * Purple
45.6 - *
45.7 - * Purple is the legal property of its developers, whose names are too
45.8 - * numerous to list here. Please refer to the COPYRIGHT file distributed
45.9 - * with this source distribution
45.10 - *
45.11 - * This program is free software; you can redistribute it and/or modify
45.12 - * it under the terms of the GNU General Public License as published by
45.13 - * the Free Software Foundation; either version 2 of the License, or (at
45.14 - * your option) any later version.
45.15 - *
45.16 - * This program is distributed in the hope that it will be useful, but
45.17 - * WITHOUT ANY WARRANTY; without even the implied warranty of
45.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
45.19 - * General Public License for more details.
45.20 - *
45.21 - * You should have received a copy of the GNU General Public License
45.22 - * along with this program; if not, write to the Free Software
45.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301,
45.24 - * USA.
45.25 - */
45.26 -
45.27 -#ifndef _PURPLE_MIME_H
45.28 -#define _PURPLE_MIME_H
45.29 -
45.30 -#include <glib.h>
45.31 -#include <glib/glist.h>
45.32 -
45.33 -#ifdef __cplusplus
45.34 -extern "C" {
45.35 -#endif
45.36 -
45.37 -/**
45.38 - * @file mime.h
45.39 - * @ingroup core
45.40 - *
45.41 - * Rudimentary parsing of multi-part MIME messages into more
45.42 - * accessible structures.
45.43 - */
45.44 -
45.45 -/**
45.46 - * A MIME document.
45.47 - */
45.48 -typedef struct _PurpleMimeDocument PurpleMimeDocument;
45.49 -
45.50 -/**
45.51 - * A part of a multipart MIME document.
45.52 - */
45.53 -typedef struct _PurpleMimePart PurpleMimePart;
45.54 -
45.55 -/**
45.56 - * Allocate an empty MIME document.
45.57 - */
45.58 -PurpleMimeDocument *purple_mime_document_new(void);
45.59 -
45.60 -/**
45.61 - * Frees memory used in a MIME document and all of its parts and fields
45.62 - *
45.63 - * @param doc The MIME document to free.
45.64 - */
45.65 -void purple_mime_document_free(PurpleMimeDocument *doc);
45.66 -
45.67 -/**
45.68 - * Parse a MIME document from a NUL-terminated string.
45.69 - *
45.70 - * @param buf The NULL-terminated string containing the MIME-encoded data.
45.71 - *
45.72 - * @returns A MIME document.
45.73 - */
45.74 -PurpleMimeDocument *purple_mime_document_parse(const char *buf);
45.75 -
45.76 -/**
45.77 - * Parse a MIME document from a string
45.78 - *
45.79 - * @param buf The string containing the MIME-encoded data.
45.80 - * @param len Length of buf.
45.81 - *
45.82 - * @returns A MIME document.
45.83 - */
45.84 -PurpleMimeDocument *purple_mime_document_parsen(const char *buf, gsize len);
45.85 -
45.86 -/**
45.87 - * Write (append) a MIME document onto a GString.
45.88 - */
45.89 -void purple_mime_document_write(PurpleMimeDocument *doc, GString *str);
45.90 -
45.91 -/**
45.92 - * The list of fields in the header of a document
45.93 - *
45.94 - * @param doc The MIME document.
45.95 - *
45.96 - * @constreturn A list of strings indicating the fields (but not the values
45.97 - * of the fields) in the header of doc.
45.98 - */
45.99 -GList *purple_mime_document_get_fields(PurpleMimeDocument *doc);
45.100 -
45.101 -/**
45.102 - * Get the value of a specific field in the header of a document.
45.103 - *
45.104 - * @param doc The MIME document.
45.105 - * @param field Case-insensitive field name.
45.106 - *
45.107 - * @returns Value associated with the indicated header field, or
45.108 - * NULL if the field doesn't exist.
45.109 - */
45.110 -const char *purple_mime_document_get_field(PurpleMimeDocument *doc,
45.111 - const char *field);
45.112 -
45.113 -/**
45.114 - * Set or replace the value of a specific field in the header of a
45.115 - * document.
45.116 - *
45.117 - * @param doc The MIME document.
45.118 - * @param field Case-insensitive field name.
45.119 - * @param value Value to associate with the indicated header field,
45.120 - * of NULL to remove the field.
45.121 - */
45.122 -void purple_mime_document_set_field(PurpleMimeDocument *doc,
45.123 - const char *field,
45.124 - const char *value);
45.125 -
45.126 -/**
45.127 - * The list of parts in a multipart document.
45.128 - *
45.129 - * @param doc The MIME document.
45.130 - *
45.131 - * @constreturn List of PurpleMimePart contained within doc.
45.132 - */
45.133 -GList *purple_mime_document_get_parts(PurpleMimeDocument *doc);
45.134 -
45.135 -/**
45.136 - * Create and insert a new part into a MIME document.
45.137 - *
45.138 - * @param doc The new part's parent MIME document.
45.139 - */
45.140 -PurpleMimePart *purple_mime_part_new(PurpleMimeDocument *doc);
45.141 -
45.142 -
45.143 -/**
45.144 - * The list of fields in the header of a document part.
45.145 - *
45.146 - * @param part The MIME document part.
45.147 - *
45.148 - * @constreturn List of strings indicating the fields (but not the values
45.149 - * of the fields) in the header of part.
45.150 - */
45.151 -GList *purple_mime_part_get_fields(PurpleMimePart *part);
45.152 -
45.153 -
45.154 -/**
45.155 - * Get the value of a specific field in the header of a document part.
45.156 - *
45.157 - * @param part The MIME document part.
45.158 - * @param field Case-insensitive name of the header field.
45.159 - *
45.160 - * @returns Value of the specified header field, or NULL if the
45.161 - * field doesn't exist.
45.162 - */
45.163 -const char *purple_mime_part_get_field(PurpleMimePart *part,
45.164 - const char *field);
45.165 -
45.166 -/**
45.167 - * Get the decoded value of a specific field in the header of a
45.168 - * document part.
45.169 - */
45.170 -char *purple_mime_part_get_field_decoded(PurpleMimePart *part,
45.171 - const char *field);
45.172 -
45.173 -/**
45.174 - * Set or replace the value of a specific field in the header of a
45.175 - * document.
45.176 - *
45.177 - * @param part The part of the MIME document.
45.178 - * @param field Case-insensitive field name
45.179 - * @param value Value to associate with the indicated header field,
45.180 - * of NULL to remove the field.
45.181 - */
45.182 -void purple_mime_part_set_field(PurpleMimePart *part,
45.183 - const char *field,
45.184 - const char *value);
45.185 -
45.186 -/**
45.187 - * Get the (possibly encoded) data portion of a MIME document part.
45.188 - *
45.189 - * @param part The MIME document part.
45.190 - *
45.191 - * @returns NULL-terminated data found in the document part
45.192 - */
45.193 -const char *purple_mime_part_get_data(PurpleMimePart *part);
45.194 -
45.195 -/**
45.196 - * Get the data portion of a MIME document part, after attempting to
45.197 - * decode it according to the content-transfer-encoding field. If the
45.198 - * specified encoding method is not supported, this function will
45.199 - * return NULL.
45.200 - *
45.201 - * @param part The MIME documemt part.
45.202 - * @param data Buffer for the data.
45.203 - * @param len The length of the buffer.
45.204 - */
45.205 -void purple_mime_part_get_data_decoded(PurpleMimePart *part,
45.206 - guchar **data, gsize *len);
45.207 -
45.208 -/**
45.209 - * Get the length of the data portion of a MIME document part.
45.210 - *
45.211 - * @param part The MIME document part.
45.212 - * @returns Length of the data in the document part.
45.213 - */
45.214 -gsize purple_mime_part_get_length(PurpleMimePart *part);
45.215 -
45.216 -void purple_mime_part_set_data(PurpleMimePart *part, const char *data);
45.217 -
45.218 -#ifdef __cplusplus
45.219 -}
45.220 -#endif
45.221 -
45.222 -#endif
46.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/msg.h Sun Jun 21 22:04:11 2009 -0400
46.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
46.3 @@ -1,348 +0,0 @@
46.4 -/**
46.5 - * @file msg.h Message functions
46.6 - *
46.7 - * purple
46.8 - *
46.9 - * Purple is the legal property of its developers, whose names are too numerous
46.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
46.11 - * source distribution.
46.12 - *
46.13 - * This program is free software; you can redistribute it and/or modify
46.14 - * it under the terms of the GNU General Public License as published by
46.15 - * the Free Software Foundation; either version 2 of the License, or
46.16 - * (at your option) any later version.
46.17 - *
46.18 - * This program is distributed in the hope that it will be useful,
46.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
46.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
46.21 - * GNU General Public License for more details.
46.22 - *
46.23 - * You should have received a copy of the GNU General Public License
46.24 - * along with this program; if not, write to the Free Software
46.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
46.26 - */
46.27 -#ifndef _MSN_MSG_H_
46.28 -#define _MSN_MSG_H_
46.29 -
46.30 -typedef struct _MsnMessage MsnMessage;
46.31 -
46.32 -#include "session.h"
46.33 -#include "user.h"
46.34 -
46.35 -#include "command.h"
46.36 -#include "transaction.h"
46.37 -
46.38 -typedef void (*MsnMsgCb)(MsnMessage *, void *data);
46.39 -
46.40 -#define MSG_BODY_DEM "\r\n\r\n"
46.41 -#define MSG_LINE_DEM "\r\n"
46.42 -
46.43 -#define MSG_OIM_BODY_DEM "\n\n"
46.44 -#define MSG_OIM_LINE_DEM "\n"
46.45 -
46.46 -/*
46.47 -typedef enum
46.48 -{
46.49 - MSN_MSG_NORMAL,
46.50 - MSN_MSG_SLP_SB,
46.51 - MSN_MSG_SLP_DC
46.52 -
46.53 -} MsnMsgType;
46.54 -*/
46.55 -
46.56 -typedef enum
46.57 -{
46.58 - MSN_MSG_UNKNOWN,
46.59 - MSN_MSG_TEXT,
46.60 - MSN_MSG_TYPING,
46.61 - MSN_MSG_CAPS,
46.62 - MSN_MSG_SLP,
46.63 - MSN_MSG_NUDGE
46.64 -
46.65 -} MsnMsgType;
46.66 -
46.67 -typedef enum
46.68 -{
46.69 - MSN_MSG_ERROR_NONE, /**< No error. */
46.70 - MSN_MSG_ERROR_TIMEOUT, /**< The message timedout. */
46.71 - MSN_MSG_ERROR_NAK, /**< The message could not be sent. */
46.72 - MSN_MSG_ERROR_SB, /**< The error comes from the switchboard. */
46.73 - MSN_MSG_ERROR_UNKNOWN /**< An unknown error occurred. */
46.74 -
46.75 -} MsnMsgErrorType;
46.76 -
46.77 -typedef struct
46.78 -{
46.79 - guint32 session_id;
46.80 - guint32 id;
46.81 - guint64 offset;
46.82 - guint64 total_size;
46.83 - guint32 length;
46.84 - guint32 flags;
46.85 - guint32 ack_id;
46.86 - guint32 ack_sub_id;
46.87 - guint64 ack_size;
46.88 -
46.89 -} MsnSlpHeader;
46.90 -
46.91 -typedef struct
46.92 -{
46.93 - guint32 value;
46.94 -
46.95 -} MsnSlpFooter;
46.96 -
46.97 -/**
46.98 - * A message.
46.99 - */
46.100 -struct _MsnMessage
46.101 -{
46.102 - size_t ref_count; /**< The reference count. */
46.103 -
46.104 - MsnMsgType type;
46.105 -
46.106 - gboolean msnslp_message;
46.107 -
46.108 - char *remote_user;
46.109 - char flag;
46.110 -
46.111 - char *content_type;
46.112 - char *charset;
46.113 - char *body;
46.114 - gsize body_len;
46.115 - guint total_chunks; /**< How many chunks in this multi-part message */
46.116 - guint received_chunks; /**< How many chunks we've received so far */
46.117 -
46.118 - MsnSlpHeader msnslp_header;
46.119 - MsnSlpFooter msnslp_footer;
46.120 -
46.121 - GHashTable *attr_table;
46.122 - GList *attr_list;
46.123 -
46.124 - gboolean ack_ref; /**< A flag that states if this message has
46.125 - been ref'ed for using it in a callback. */
46.126 -
46.127 - MsnCommand *cmd;
46.128 - MsnTransaction *trans;
46.129 -
46.130 - MsnMsgCb ack_cb; /**< The callback to call when we receive an ACK of this
46.131 - message. */
46.132 - MsnMsgCb nak_cb; /**< The callback to call when we receive a NAK of this
46.133 - message. */
46.134 - void *ack_data; /**< The data used by callbacks. */
46.135 -
46.136 - MsnMsgErrorType error; /**< The error of the message. */
46.137 -
46.138 - guint32 retries;
46.139 -};
46.140 -
46.141 -/**
46.142 - * Creates a new, empty message.
46.143 - *
46.144 - * @return A new message.
46.145 - */
46.146 -MsnMessage *msn_message_new(MsnMsgType type);
46.147 -
46.148 -/**
46.149 - * Creates a new, empty MSNSLP message.
46.150 - *
46.151 - * @return A new MSNSLP message.
46.152 - */
46.153 -MsnMessage *msn_message_new_msnslp(void);
46.154 -
46.155 -/**
46.156 - * Creates a new nudge message.
46.157 - *
46.158 - * @return A new nudge message.
46.159 - */
46.160 -MsnMessage *msn_message_new_nudge(void);
46.161 -
46.162 -/**
46.163 - * Creates a new plain message.
46.164 - *
46.165 - * @return A new plain message.
46.166 - */
46.167 -MsnMessage *msn_message_new_plain(const char *message);
46.168 -
46.169 -/**
46.170 - * Creates a MSNSLP ack message.
46.171 - *
46.172 - * @param acked_msg The message to acknowledge.
46.173 - *
46.174 - * @return A new MSNSLP ack message.
46.175 - */
46.176 -MsnMessage *msn_message_new_msnslp_ack(MsnMessage *acked_msg);
46.177 -
46.178 -/**
46.179 - * Creates a new message based off a command.
46.180 - *
46.181 - * @param session The MSN session.
46.182 - * @param cmd The command.
46.183 - *
46.184 - * @return The new message.
46.185 - */
46.186 -MsnMessage *msn_message_new_from_cmd(MsnSession *session, MsnCommand *cmd);
46.187 -
46.188 -/**
46.189 - * Parses the payload of a message.
46.190 - *
46.191 - * @param msg The message.
46.192 - * @param payload The payload.
46.193 - * @param payload_len The length of the payload.
46.194 - */
46.195 -void msn_message_parse_payload(MsnMessage *msg, const char *payload,
46.196 - size_t payload_len,
46.197 - const char *line_dem,const char *body_dem);
46.198 -
46.199 -/**
46.200 - * Destroys a message.
46.201 - *
46.202 - * @param msg The message to destroy.
46.203 - */
46.204 -void msn_message_destroy(MsnMessage *msg);
46.205 -
46.206 -/**
46.207 - * Increments the reference count on a message.
46.208 - *
46.209 - * @param msg The message.
46.210 - *
46.211 - * @return @a msg
46.212 - */
46.213 -MsnMessage *msn_message_ref(MsnMessage *msg);
46.214 -
46.215 -/**
46.216 - * Decrements the reference count on a message.
46.217 - *
46.218 - * This will destroy the structure if the count hits 0.
46.219 - *
46.220 - * @param msg The message.
46.221 - *
46.222 - * @return @a msg, or @c NULL if the new count is 0.
46.223 - */
46.224 -MsnMessage *msn_message_unref(MsnMessage *msg);
46.225 -
46.226 -/**
46.227 - * Generates the payload data of a message.
46.228 - *
46.229 - * @param msg The message.
46.230 - * @param ret_size The returned size of the payload.
46.231 - *
46.232 - * @return The payload data of the message.
46.233 - */
46.234 -char *msn_message_gen_payload(MsnMessage *msg, size_t *ret_size);
46.235 -
46.236 -/**
46.237 - * Sets the flag for an outgoing message.
46.238 - *
46.239 - * @param msg The message.
46.240 - * @param flag The flag.
46.241 - */
46.242 -void msn_message_set_flag(MsnMessage *msg, char flag);
46.243 -
46.244 -/**
46.245 - * Returns the flag for an outgoing message.
46.246 - *
46.247 - * @param msg The message.
46.248 - *
46.249 - * @return The flag.
46.250 - */
46.251 -char msn_message_get_flag(const MsnMessage *msg);
46.252 -
46.253 -/**
46.254 - * Sets the binary content of the message.
46.255 - *
46.256 - * @param msg The message.
46.257 - * @param data The binary data.
46.258 - * @param len The length of the data.
46.259 - */
46.260 -void msn_message_set_bin_data(MsnMessage *msg, const void *data, size_t len);
46.261 -
46.262 -/**
46.263 - * Returns the binary content of the message.
46.264 - *
46.265 - * @param msg The message.
46.266 - * @param len The returned length of the data.
46.267 - *
46.268 - * @return The binary data.
46.269 - */
46.270 -const void *msn_message_get_bin_data(const MsnMessage *msg, size_t *len);
46.271 -
46.272 -/**
46.273 - * Sets the content type in a message.
46.274 - *
46.275 - * @param msg The message.
46.276 - * @param type The content-type.
46.277 - */
46.278 -void msn_message_set_content_type(MsnMessage *msg, const char *type);
46.279 -
46.280 -/**
46.281 - * Returns the content type in a message.
46.282 - *
46.283 - * @param msg The message.
46.284 - *
46.285 - * @return The content-type.
46.286 - */
46.287 -const char *msn_message_get_content_type(const MsnMessage *msg);
46.288 -
46.289 -/**
46.290 - * Sets the charset in a message.
46.291 - *
46.292 - * @param msg The message.
46.293 - * @param charset The charset.
46.294 - */
46.295 -void msn_message_set_charset(MsnMessage *msg, const char *charset);
46.296 -
46.297 -/**
46.298 - * Returns the charset in a message.
46.299 - *
46.300 - * @param msg The message.
46.301 - *
46.302 - * @return The charset.
46.303 - */
46.304 -const char *msn_message_get_charset(const MsnMessage *msg);
46.305 -
46.306 -/**
46.307 - * Sets an attribute in a message.
46.308 - *
46.309 - * @param msg The message.
46.310 - * @param attr The attribute name.
46.311 - * @param value The attribute value.
46.312 - */
46.313 -void msn_message_set_attr(MsnMessage *msg, const char *attr,
46.314 - const char *value);
46.315 -
46.316 -/**
46.317 - * Returns an attribute from a message.
46.318 - *
46.319 - * @param msg The message.
46.320 - * @param attr The attribute.
46.321 - *
46.322 - * @return The value, or @c NULL if not found.
46.323 - */
46.324 -const char *msn_message_get_attr(const MsnMessage *msg, const char *attr);
46.325 -
46.326 -/**
46.327 - * Parses the body and returns it in the form of a hashtable.
46.328 - *
46.329 - * @param msg The message.
46.330 - *
46.331 - * @return The resulting hashtable.
46.332 - */
46.333 -GHashTable *msn_message_get_hashtable_from_body(const MsnMessage *msg);
46.334 -
46.335 -void msn_message_show_readable(MsnMessage *msg, const char *info,
46.336 - gboolean text_body);
46.337 -
46.338 -void msn_message_parse_slp_body(MsnMessage *msg, const char *body,
46.339 - size_t len);
46.340 -
46.341 -char *msn_message_gen_slp_body(MsnMessage *msg, size_t *ret_size);
46.342 -
46.343 -char *msn_message_to_string(MsnMessage *msg);
46.344 -
46.345 -void msn_plain_msg(MsnCmdProc *cmdproc, MsnMessage *msg);
46.346 -
46.347 -void msn_control_msg(MsnCmdProc *cmdproc, MsnMessage *msg);
46.348 -
46.349 -void msn_datacast_msg(MsnCmdProc *cmdproc, MsnMessage *msg);
46.350 -
46.351 -#endif /* _MSN_MSG_H_ */
47.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/msn.h Sun Jun 21 22:04:11 2009 -0400
47.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
47.3 @@ -1,149 +0,0 @@
47.4 -/**
47.5 - * @file msn.h The MSN protocol plugin
47.6 - *
47.7 - * purple
47.8 - *
47.9 - * Purple is the legal property of its developers, whose names are too numerous
47.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
47.11 - * source distribution.
47.12 - *
47.13 - * This program is free software; you can redistribute it and/or modify
47.14 - * it under the terms of the GNU General Public License as published by
47.15 - * the Free Software Foundation; either version 2 of the License, or
47.16 - * (at your option) any later version.
47.17 - *
47.18 - * This program is distributed in the hope that it will be useful,
47.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
47.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
47.21 - * GNU General Public License for more details.
47.22 - *
47.23 - * You should have received a copy of the GNU General Public License
47.24 - * along with this program; if not, write to the Free Software
47.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
47.26 - */
47.27 -#ifndef _MSN_H_
47.28 -#define _MSN_H_
47.29 -
47.30 -/* #define MSN_DEBUG_MSG 1 */
47.31 -/* #define MSN_DEBUG_SLPMSG 1 */
47.32 -/* #define MSN_DEBUG_HTTP 1 */
47.33 -
47.34 -/* #define MSN_DEBUG_SLP 1 */
47.35 -/* #define MSN_DEBUG_SLP_VERBOSE 1 */
47.36 -/* #define MSN_DEBUG_SLP_FILES 1 */
47.37 -
47.38 -/* #define MSN_DEBUG_NS 1 */
47.39 -/* #define MSN_DEBUG_SB 1 */
47.40 -
47.41 -#include "internal.h"
47.42 -
47.43 -#include "account.h"
47.44 -#include "accountopt.h"
47.45 -#include "blist.h"
47.46 -#include "connection.h"
47.47 -#include "conversation.h"
47.48 -#include "debug.h"
47.49 -#include "cipher.h"
47.50 -#include "notify.h"
47.51 -#include "privacy.h"
47.52 -#include "proxy.h"
47.53 -#include "prpl.h"
47.54 -#include "request.h"
47.55 -#include "servconn.h"
47.56 -#include "sslconn.h"
47.57 -#include "util.h"
47.58 -
47.59 -#include "ft.h"
47.60 -
47.61 -#include "msg.h"
47.62 -
47.63 -#define MSN_BUF_LEN 8192
47.64 -
47.65 -/* Windows Live Messenger Server*/
47.66 -#define MSN_SERVER "messenger.hotmail.com"
47.67 -#define MSN_HTTPCONN_SERVER "gateway.messenger.hotmail.com"
47.68 -#define MSN_PORT 1863
47.69 -#define WLM_PROT_VER 15
47.70 -
47.71 -#define WLM_MAX_PROTOCOL 15
47.72 -#define WLM_MIN_PROTOCOL 15
47.73 -
47.74 -#define MSN_TYPING_RECV_TIMEOUT 6
47.75 -#define MSN_TYPING_SEND_TIMEOUT 4
47.76 -
47.77 -#define PROFILE_URL "http://spaces.live.com/profile.aspx?mem="
47.78 -#define PHOTO_URL " contactparams:photopreauthurl=\""
47.79 -
47.80 -#define BUDDY_ALIAS_MAXLEN 387
47.81 -
47.82 -#define MSN_FT_GUID "5D3E02AB-6190-11D3-BBBB-00C04F795683"
47.83 -#define MSN_OBJ_GUID "A4268EEC-FEC5-49E5-95C3-F126696BDBF6"
47.84 -
47.85 -#define MSN_CLIENTINFO \
47.86 - "Client-Name: Purple/" VERSION "\r\n" \
47.87 - "Chat-Logging: Y\r\n"
47.88 -
47.89 -/* Index into attention_types */
47.90 -#define MSN_NUDGE 0
47.91 -
47.92 -typedef enum
47.93 -{
47.94 - MSN_LIST_FL_OP = 0x01,
47.95 - MSN_LIST_AL_OP = 0x02,
47.96 - MSN_LIST_BL_OP = 0x04,
47.97 - MSN_LIST_RL_OP = 0x08,
47.98 - MSN_LIST_PL_OP = 0x10
47.99 -
47.100 -} MsnListOp;
47.101 -#define MSN_LIST_OP_MASK 0x07
47.102 -
47.103 -typedef enum
47.104 -{
47.105 - MSN_CLIENT_CAP_WIN_MOBILE = 0x000001,
47.106 - MSN_CLIENT_CAP_INK_GIF = 0x000004,
47.107 - MSN_CLIENT_CAP_INK_ISF = 0x000008,
47.108 - MSN_CLIENT_CAP_VIDEO_CHAT = 0x000010,
47.109 - MSN_CLIENT_CAP_PACKET = 0x000020,
47.110 - MSN_CLIENT_CAP_MSNMOBILE = 0x000040,
47.111 - MSN_CLIENT_CAP_MSNDIRECT = 0x000080,
47.112 - MSN_CLIENT_CAP_WEBMSGR = 0x000200,
47.113 - MSN_CLIENT_CAP_TGW = 0x000800,
47.114 - MSN_CLIENT_CAP_SPACE = 0x001000,
47.115 - MSN_CLIENT_CAP_MCE = 0x002000,
47.116 - MSN_CLIENT_CAP_DIRECTIM = 0x004000,
47.117 - MSN_CLIENT_CAP_WINKS = 0x008000,
47.118 - MSN_CLIENT_CAP_SEARCH = 0x010000,
47.119 - MSN_CLIENT_CAP_BOT = 0x020000,
47.120 - MSN_CLIENT_CAP_VOICEIM = 0x040000,
47.121 - MSN_CLIENT_CAP_SCHANNEL = 0x080000,
47.122 - MSN_CLIENT_CAP_SIP_INVITE = 0x100000,
47.123 - MSN_CLIENT_CAP_SDRIVE = 0x400000
47.124 -
47.125 -} MsnClientCaps;
47.126 -
47.127 -typedef enum
47.128 -{
47.129 - MSN_CLIENT_VER_5_0 = 0x00,
47.130 - MSN_CLIENT_VER_6_0 = 0x10, /* MSNC1 */
47.131 - MSN_CLIENT_VER_6_1 = 0x20, /* MSNC2 */
47.132 - MSN_CLIENT_VER_6_2 = 0x30, /* MSNC3 */
47.133 - MSN_CLIENT_VER_7_0 = 0x40, /* MSNC4 */
47.134 - MSN_CLIENT_VER_7_5 = 0x50, /* MSNC5 */
47.135 - MSN_CLIENT_VER_8_0 = 0x60, /* MSNC6 */
47.136 - MSN_CLIENT_VER_8_1 = 0x70, /* MSNC7 */
47.137 - MSN_CLIENT_VER_8_5 = 0x80 /* MSNC8 */
47.138 -
47.139 -} MsnClientVerId;
47.140 -
47.141 -#define MSN_CLIENT_ID_VERSION MSN_CLIENT_VER_7_0
47.142 -#define MSN_CLIENT_ID_CAPABILITIES MSN_CLIENT_CAP_PACKET
47.143 -
47.144 -#define MSN_CLIENT_ID \
47.145 - ((MSN_CLIENT_ID_VERSION << 24) | \
47.146 - (MSN_CLIENT_ID_CAPABILITIES))
47.147 -
47.148 -void msn_act_id(PurpleConnection *gc, const char *entry);
47.149 -void msn_send_privacy(PurpleConnection *gc);
47.150 -void msn_send_im_message(MsnSession *session, MsnMessage *msg);
47.151 -
47.152 -#endif /* _MSN_H_ */
48.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/msn_intl.h Sun Jun 21 22:04:11 2009 -0400
48.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
48.3 @@ -1,45 +0,0 @@
48.4 -/**
48.5 - * Copyright (C) 2008 Felipe Contreras
48.6 - *
48.7 - * Purple is the legal property of its developers, whose names are too numerous
48.8 - * to list here. Please refer to the COPYRIGHT file distributed with this
48.9 - * source distribution.
48.10 - *
48.11 - * This program is free software; you can redistribute it and/or modify
48.12 - * it under the terms of the GNU General Public License as published by
48.13 - * the Free Software Foundation; either version 2 of the License, or
48.14 - * (at your option) any later version.
48.15 - *
48.16 - * This program is distributed in the hope that it will be useful,
48.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
48.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
48.19 - * GNU General Public License for more details.
48.20 - *
48.21 - * You should have received a copy of the GNU General Public License
48.22 - * along with this program; if not, write to the Free Software
48.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
48.24 - */
48.25 -
48.26 -#ifndef MSN_INTL_H
48.27 -#define MSN_INTL_H
48.28 -
48.29 -#ifdef ENABLE_NLS
48.30 -# include <locale.h>
48.31 -# include <libintl.h>
48.32 -# define _(String) ((const char *)dgettext(PACKAGE, String))
48.33 -# ifdef gettext_noop
48.34 -# define N_(String) gettext_noop (String)
48.35 -# else
48.36 -# define N_(String) (String)
48.37 -# endif
48.38 -#else
48.39 -# include <locale.h>
48.40 -# define N_(String) (String)
48.41 -# ifndef _
48.42 -# define _(String) ((const char *)String)
48.43 -# endif
48.44 -# define ngettext(Singular, Plural, Number) ((Number == 1) ? ((const char *)Singular) : ((const char *)Plural))
48.45 -# define dngettext(Domain, Singular, Plural, Number) ((Number == 1) ? ((const char *)Singular) : ((const char *)Plural))
48.46 -#endif
48.47 -
48.48 -#endif /* MSN_INTL_H */
49.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/msnutils.h Sun Jun 21 22:04:11 2009 -0400
49.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
49.3 @@ -1,60 +0,0 @@
49.4 -/**
49.5 - * @file msnutils.h Utility functions
49.6 - *
49.7 - * purple
49.8 - *
49.9 - * Purple is the legal property of its developers, whose names are too numerous
49.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
49.11 - * source distribution.
49.12 - *
49.13 - * This program is free software; you can redistribute it and/or modify
49.14 - * it under the terms of the GNU General Public License as published by
49.15 - * the Free Software Foundation; either version 2 of the License, or
49.16 - * (at your option) any later version.
49.17 - *
49.18 - * This program is distributed in the hope that it will be useful,
49.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
49.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
49.21 - * GNU General Public License for more details.
49.22 - *
49.23 - * You should have received a copy of the GNU General Public License
49.24 - * along with this program; if not, write to the Free Software
49.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
49.26 - */
49.27 -#ifndef _MSN_UTILS_H_
49.28 -#define _MSN_UTILS_H_
49.29 -
49.30 -/*encode the str to RFC2047 style*/
49.31 -char * msn_encode_mime(const char *str);
49.32 -
49.33 -/**
49.34 - * Generate the Random GUID
49.35 - */
49.36 -char * rand_guid(void);
49.37 -
49.38 -/**
49.39 - * Parses the MSN message formatting into a format compatible with Purple.
49.40 - *
49.41 - * @param mime The mime header with the formatting.
49.42 - * @param pre_ret The returned prefix string.
49.43 - * @param post_ret The returned postfix string.
49.44 - *
49.45 - * @return The new message.
49.46 - */
49.47 -void msn_parse_format(const char *mime, char **pre_ret, char **post_ret);
49.48 -
49.49 -/**
49.50 - * Parses the Purple message formatting (html) into the MSN format.
49.51 - *
49.52 - * @param html The html message to format.
49.53 - * @param attributes The returned attributes string.
49.54 - * @param message The returned message string.
49.55 - *
49.56 - * @return The new message.
49.57 - */
49.58 -void msn_import_html(const char *html, char **attributes, char **message);
49.59 -
49.60 -void msn_parse_socket(const char *str, char **ret_host, int *ret_port);
49.61 -void msn_handle_chl(char *input, char *output);
49.62 -
49.63 -#endif /* _MSN_UTILS_H_ */
50.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/nat-pmp.h Sun Jun 21 22:04:11 2009 -0400
50.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
50.3 @@ -1,77 +0,0 @@
50.4 -/**
50.5 - * @file nat-pmp.h NAT-PMP Implementation
50.6 - * @ingroup core
50.7 - */
50.8 -
50.9 -/* purple
50.10 - *
50.11 - * Purple is the legal property of its developers, whose names are too numerous
50.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
50.13 - * source distribution.
50.14 - *
50.15 - * Most code in nat-pmp.h copyright (C) 2007, R. Tyler Ballance, bleep, LLC.
50.16 - * This file is distributed under the 3-clause (modified) BSD license:
50.17 - * Redistribution and use in source and binary forms, with or without modification, are permitted
50.18 - * provided that the following conditions are met:
50.19 - *
50.20 - * Redistributions of source code must retain the above copyright notice, this list of conditions and
50.21 - * the following disclaimer.
50.22 - * Neither the name of the bleep. LLC nor the names of its contributors may be used to endorse or promote
50.23 - * products derived from this software without specific prior written permission.
50.24 - *
50.25 - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
50.26 - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
50.27 - * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
50.28 - * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
50.29 - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
50.30 - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
50.31 - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
50.32 - * OF SUCH DAMAGE.
50.33 - */
50.34 -
50.35 -#ifndef _PURPLE_NAT_PMP_H
50.36 -#define _PURPLE_NAT_PMP_H
50.37 -
50.38 -#include <glib.h>
50.39 -
50.40 -#define PURPLE_PMP_LIFETIME 3600 /* 3600 seconds */
50.41 -
50.42 -typedef enum {
50.43 - PURPLE_PMP_TYPE_UDP,
50.44 - PURPLE_PMP_TYPE_TCP
50.45 -} PurplePmpType;
50.46 -
50.47 -/**
50.48 - * Initialize nat-pmp
50.49 - */
50.50 -void purple_pmp_init(void);
50.51 -
50.52 -/**
50.53 - *
50.54 - */
50.55 -char *purple_pmp_get_public_ip(void);
50.56 -
50.57 -/**
50.58 - * Remove the NAT-PMP mapping for a specified type on a specified port
50.59 - *
50.60 - * @param type The PurplePmpType
50.61 - * @param privateport The private port on which we are listening locally
50.62 - * @param publicport The public port on which we are expecting a response
50.63 - * @param lifetime The lifetime of the mapping. It is recommended that this be PURPLE_PMP_LIFETIME.
50.64 - *
50.65 - * @returns TRUE if succesful; FALSE if unsuccessful
50.66 - */
50.67 -gboolean purple_pmp_create_map(PurplePmpType type, unsigned short privateport, unsigned short publicport, int lifetime);
50.68 -
50.69 -/**
50.70 - * Remove the NAT-PMP mapping for a specified type on a specified port
50.71 - *
50.72 - * @param type The PurplePmpType
50.73 - * @param privateport The private port on which the mapping was previously made
50.74 - *
50.75 - * @returns TRUE if succesful; FALSE if unsuccessful
50.76 - */
50.77 -gboolean purple_pmp_destroy_map(PurplePmpType type, unsigned short privateport);
50.78 -
50.79 -#endif
50.80 -
51.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/network.h Sun Jun 21 22:04:11 2009 -0400
51.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
51.3 @@ -1,233 +0,0 @@
51.4 -/**
51.5 - * @file network.h Network API
51.6 - * @ingroup core
51.7 - */
51.8 -
51.9 -/* purple
51.10 - *
51.11 - * Purple is the legal property of its developers, whose names are too numerous
51.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
51.13 - * source distribution.
51.14 - *
51.15 - * This program is free software; you can redistribute it and/or modify
51.16 - * it under the terms of the GNU General Public License as published by
51.17 - * the Free Software Foundation; either version 2 of the License, or
51.18 - * (at your option) any later version.
51.19 - *
51.20 - * This program is distributed in the hope that it will be useful,
51.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
51.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
51.23 - * GNU General Public License for more details.
51.24 - *
51.25 - * You should have received a copy of the GNU General Public License
51.26 - * along with this program; if not, write to the Free Software
51.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
51.28 - */
51.29 -#ifndef _PURPLE_NETWORK_H_
51.30 -#define _PURPLE_NETWORK_H_
51.31 -
51.32 -#ifdef __cplusplus
51.33 -extern "C" {
51.34 -#endif
51.35 -
51.36 -/**************************************************************************/
51.37 -/** @name Network API */
51.38 -/**************************************************************************/
51.39 -/*@{*/
51.40 -
51.41 -typedef struct _PurpleNetworkListenData PurpleNetworkListenData;
51.42 -
51.43 -typedef void (*PurpleNetworkListenCallback) (int listenfd, gpointer data);
51.44 -
51.45 -/**
51.46 - * Converts a dot-decimal IP address to an array of unsigned
51.47 - * chars. For example, converts 192.168.0.1 to a 4 byte
51.48 - * array containing 192, 168, 0 and 1.
51.49 - *
51.50 - * @param ip An IP address in dot-decimal notiation.
51.51 - * @return An array of 4 bytes containing an IP addresses
51.52 - * equivalent to the given parameter, or NULL if
51.53 - * the given IP address is invalid. This value
51.54 - * is statically allocated and should not be
51.55 - * freed.
51.56 - */
51.57 -const unsigned char *purple_network_ip_atoi(const char *ip);
51.58 -
51.59 -/**
51.60 - * Sets the IP address of the local system in preferences. This
51.61 - * is the IP address that should be used for incoming connections
51.62 - * (file transfer, direct IM, etc.) and should therefore be
51.63 - * publicly accessible.
51.64 - *
51.65 - * @param ip The local IP address.
51.66 - */
51.67 -void purple_network_set_public_ip(const char *ip);
51.68 -
51.69 -/**
51.70 - * Returns the IP address of the local system set in preferences.
51.71 - *
51.72 - * This returns the value set via purple_network_set_public_ip().
51.73 - * You probably want to use purple_network_get_my_ip() instead.
51.74 - *
51.75 - * @return The local IP address set in preferences.
51.76 - */
51.77 -const char *purple_network_get_public_ip(void);
51.78 -
51.79 -/**
51.80 - * Returns the IP address of the local system.
51.81 - *
51.82 - * You probably want to use purple_network_get_my_ip() instead.
51.83 - *
51.84 - * @note The returned string is a pointer to a static buffer. If this
51.85 - * function is called twice, it may be important to make a copy
51.86 - * of the returned string.
51.87 - *
51.88 - * @param fd The fd to use to help figure out the IP, or else -1.
51.89 - * @return The local IP address.
51.90 - */
51.91 -const char *purple_network_get_local_system_ip(int fd);
51.92 -
51.93 -/**
51.94 - * Returns the IP address that should be used anywhere a
51.95 - * public IP addresses is needed (listening for an incoming
51.96 - * file transfer, etc).
51.97 - *
51.98 - * If the user has manually specified an IP address via
51.99 - * preferences, then this IP is returned. Otherwise the
51.100 - * IP address returned by purple_network_get_local_system_ip()
51.101 - * is returned.
51.102 - *
51.103 - * @note The returned string is a pointer to a static buffer. If this
51.104 - * function is called twice, it may be important to make a copy
51.105 - * of the returned string.
51.106 - *
51.107 - * @param fd The fd to use to help figure out the IP, or -1.
51.108 - * @return The local IP address to be used.
51.109 - */
51.110 -const char *purple_network_get_my_ip(int fd);
51.111 -
51.112 -/**
51.113 - * Should calls to purple_network_listen() and purple_network_listen_range()
51.114 - * map the port externally using NAT-PMP or UPnP?
51.115 - * The default value is TRUE
51.116 - *
51.117 - * @param map_external Should the open port be mapped externally?
51.118 - * @deprecated In 3.0.0 a boolean will be added to the above functions to
51.119 - * perform the same function.
51.120 - * @since 2.3.0
51.121 - */
51.122 -void purple_network_listen_map_external(gboolean map_external);
51.123 -
51.124 -/**
51.125 - * Attempts to open a listening port ONLY on the specified port number.
51.126 - * You probably want to use purple_network_listen_range() instead of this.
51.127 - * This function is useful, for example, if you wanted to write a telnet
51.128 - * server as a Purple plugin, and you HAD to listen on port 23. Why anyone
51.129 - * would want to do that is beyond me.
51.130 - *
51.131 - * This opens a listening port. The caller will want to set up a watcher
51.132 - * of type PURPLE_INPUT_READ on the fd returned in cb. It will probably call
51.133 - * accept in the watcher callback, and then possibly remove the watcher and close
51.134 - * the listening socket, and add a new watcher on the new socket accept
51.135 - * returned.
51.136 - *
51.137 - * @param port The port number to bind to. Must be greater than 0.
51.138 - * @param socket_type The type of socket to open for listening.
51.139 - * This will be either SOCK_STREAM for TCP or SOCK_DGRAM for UDP.
51.140 - * @param cb The callback to be invoked when the port to listen on is available.
51.141 - * The file descriptor of the listening socket will be specified in
51.142 - * this callback, or -1 if no socket could be established.
51.143 - * @param cb_data extra data to be returned when cb is called
51.144 - *
51.145 - * @return A pointer to a data structure that can be used to cancel
51.146 - * the pending listener, or NULL if unable to obtain a local
51.147 - * socket to listen on.
51.148 - */
51.149 -PurpleNetworkListenData *purple_network_listen(unsigned short port,
51.150 - int socket_type, PurpleNetworkListenCallback cb, gpointer cb_data);
51.151 -
51.152 -/**
51.153 - * Opens a listening port selected from a range of ports. The range of
51.154 - * ports used is chosen in the following manner:
51.155 - * If a range is specified in preferences, these values are used.
51.156 - * If a non-0 values are passed to the function as parameters, these
51.157 - * values are used.
51.158 - * Otherwise a port is chosen at random by the operating system.
51.159 - *
51.160 - * This opens a listening port. The caller will want to set up a watcher
51.161 - * of type PURPLE_INPUT_READ on the fd returned in cb. It will probably call
51.162 - * accept in the watcher callback, and then possibly remove the watcher and close
51.163 - * the listening socket, and add a new watcher on the new socket accept
51.164 - * returned.
51.165 - *
51.166 - * @param start The port number to bind to, or 0 to pick a random port.
51.167 - * Users are allowed to override this arg in prefs.
51.168 - * @param end The highest possible port in the range of ports to listen on,
51.169 - * or 0 to pick a random port. Users are allowed to override this
51.170 - * arg in prefs.
51.171 - * @param socket_type The type of socket to open for listening.
51.172 - * This will be either SOCK_STREAM for TCP or SOCK_DGRAM for UDP.
51.173 - * @param cb The callback to be invoked when the port to listen on is available.
51.174 - * The file descriptor of the listening socket will be specified in
51.175 - * this callback, or -1 if no socket could be established.
51.176 - * @param cb_data extra data to be returned when cb is called
51.177 - *
51.178 - * @return A pointer to a data structure that can be used to cancel
51.179 - * the pending listener, or NULL if unable to obtain a local
51.180 - * socket to listen on.
51.181 - */
51.182 -PurpleNetworkListenData *purple_network_listen_range(unsigned short start,
51.183 - unsigned short end, int socket_type,
51.184 - PurpleNetworkListenCallback cb, gpointer cb_data);
51.185 -
51.186 -/**
51.187 - * This can be used to cancel any in-progress listener connection
51.188 - * by passing in the return value from either purple_network_listen()
51.189 - * or purple_network_listen_range().
51.190 - *
51.191 - * @param listen_data This listener attempt will be canceled and
51.192 - * the struct will be freed.
51.193 - */
51.194 -void purple_network_listen_cancel(PurpleNetworkListenData *listen_data);
51.195 -
51.196 -/**
51.197 - * Gets a port number from a file descriptor.
51.198 - *
51.199 - * @param fd The file descriptor. This should be a tcp socket. The current
51.200 - * implementation probably dies on anything but IPv4. Perhaps this
51.201 - * possible bug will inspire new and valuable contributors to Purple.
51.202 - * @return The port number, in host byte order.
51.203 - */
51.204 -unsigned short purple_network_get_port_from_fd(int fd);
51.205 -
51.206 -/**
51.207 - * Detects if there is an available network connection.
51.208 - *
51.209 - * @return TRUE if the network is available
51.210 - */
51.211 -gboolean purple_network_is_available(void);
51.212 -
51.213 -/**
51.214 - * Get the handle for the network system
51.215 - *
51.216 - * @return the handle to the network system
51.217 - */
51.218 -void *purple_network_get_handle(void);
51.219 -
51.220 -/**
51.221 - * Initializes the network subsystem.
51.222 - */
51.223 -void purple_network_init(void);
51.224 -
51.225 -/**
51.226 - * Shuts down the network subsystem.
51.227 - */
51.228 -void purple_network_uninit(void);
51.229 -
51.230 -/*@}*/
51.231 -
51.232 -#ifdef __cplusplus
51.233 -}
51.234 -#endif
51.235 -
51.236 -#endif /* _PURPLE_NETWORK_H_ */
52.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/nexus.h Sun Jun 21 22:04:11 2009 -0400
52.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
52.3 @@ -1,234 +0,0 @@
52.4 -/**
52.5 - * @file nexus.h MSN Nexus functions
52.6 - *
52.7 - * purple
52.8 - *
52.9 - * Purple is the legal property of its developers, whose names are too numerous
52.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
52.11 - * source distribution.
52.12 - *
52.13 - * This program is free software; you can redistribute it and/or modify
52.14 - * it under the terms of the GNU General Public License as published by
52.15 - * the Free Software Foundation; either version 2 of the License, or
52.16 - * (at your option) any later version.
52.17 - *
52.18 - * This program is distributed in the hope that it will be useful,
52.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
52.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
52.21 - * GNU General Public License for more details.
52.22 - *
52.23 - * You should have received a copy of the GNU General Public License
52.24 - * along with this program; if not, write to the Free Software
52.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
52.26 - */
52.27 -#ifndef _MSN_NEXUS_H_
52.28 -#define _MSN_NEXUS_H_
52.29 -
52.30 -/* Index into ticket_tokens in nexus.c Keep updated! */
52.31 -typedef enum
52.32 -{
52.33 - MSN_AUTH_MESSENGER = 0,
52.34 - MSN_AUTH_MESSENGER_WEB = 1,
52.35 - MSN_AUTH_CONTACTS = 2,
52.36 - MSN_AUTH_LIVE_SECURE = 3,
52.37 - MSN_AUTH_SPACES = 4,
52.38 - MSN_AUTH_LIVE_CONTACTS = 5,
52.39 - MSN_AUTH_STORAGE = 6
52.40 -} MsnAuthDomains;
52.41 -
52.42 -#define MSN_SSO_SERVER "login.live.com"
52.43 -#define SSO_POST_URL "/RST.srf"
52.44 -
52.45 -#define MSN_SSO_RST_TEMPLATE \
52.46 -"<wst:RequestSecurityToken xmlns=\"http://schemas.xmlsoap.org/ws/2004/04/trust\" Id=\"RST%d\">"\
52.47 - "<wst:RequestType>http://schemas.xmlsoap.org/ws/2004/04/security/trust/Issue</wst:RequestType>"\
52.48 - "<wsp:AppliesTo xmlns=\"http://schemas.xmlsoap.org/ws/2002/12/policy\">"\
52.49 - "<wsa:EndpointReference xmlns=\"http://schemas.xmlsoap.org/ws/2004/03/addressing\">"\
52.50 - "<wsa:Address>%s</wsa:Address>"\
52.51 - "</wsa:EndpointReference>"\
52.52 - "</wsp:AppliesTo>"\
52.53 - "<wsse:PolicyReference xmlns=\"http://schemas.xmlsoap.org/ws/2003/06/secext\" URI=\"%s\"></wsse:PolicyReference>"\
52.54 -"</wst:RequestSecurityToken>"
52.55 -
52.56 -#define MSN_SSO_TEMPLATE "<?xml version='1.0' encoding='utf-8'?>"\
52.57 -"<Envelope xmlns=\"http://schemas.xmlsoap.org/soap/envelope/\""\
52.58 - " xmlns:wsse=\"http://schemas.xmlsoap.org/ws/2003/06/secext\""\
52.59 - " xmlns:saml=\"urn:oasis:names:tc:SAML:1.0:assertion\""\
52.60 - " xmlns:wsp=\"http://schemas.xmlsoap.org/ws/2002/12/policy\""\
52.61 - " xmlns:wsu=\"http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd\""\
52.62 - " xmlns:wsa=\"http://schemas.xmlsoap.org/ws/2004/03/addressing\""\
52.63 - " xmlns:wssc=\"http://schemas.xmlsoap.org/ws/2004/04/sc\""\
52.64 - " xmlns:wst=\"http://schemas.xmlsoap.org/ws/2004/04/trust\">"\
52.65 - "<Header>"\
52.66 - "<ps:AuthInfo"\
52.67 - " xmlns:ps=\"http://schemas.microsoft.com/Passport/SoapServices/PPCRL\""\
52.68 - " Id=\"PPAuthInfo\">"\
52.69 - "<ps:HostingApp>{7108E71A-9926-4FCB-BCC9-9A9D3F32E423}</ps:HostingApp>"\
52.70 - "<ps:BinaryVersion>4</ps:BinaryVersion>"\
52.71 - "<ps:UIVersion>1</ps:UIVersion>"\
52.72 - "<ps:Cookies></ps:Cookies>"\
52.73 - "<ps:RequestParams>AQAAAAIAAABsYwQAAAAxMDMz</ps:RequestParams>"\
52.74 - "</ps:AuthInfo>"\
52.75 - "<wsse:Security>"\
52.76 - "<wsse:UsernameToken Id=\"user\">"\
52.77 - "<wsse:Username>%s</wsse:Username>"\
52.78 - "<wsse:Password>%s</wsse:Password>"\
52.79 - "</wsse:UsernameToken>"\
52.80 - "</wsse:Security>"\
52.81 - "</Header>"\
52.82 - "<Body>"\
52.83 - "<ps:RequestMultipleSecurityTokens"\
52.84 - " xmlns:ps=\"http://schemas.microsoft.com/Passport/SoapServices/PPCRL\""\
52.85 - " Id=\"RSTS\">"\
52.86 - "<wst:RequestSecurityToken Id=\"RST0\">"\
52.87 - "<wst:RequestType>http://schemas.xmlsoap.org/ws/2004/04/security/trust/Issue</wst:RequestType>"\
52.88 - "<wsp:AppliesTo>"\
52.89 - "<wsa:EndpointReference>"\
52.90 - "<wsa:Address>http://Passport.NET/tb</wsa:Address>"\
52.91 - "</wsa:EndpointReference>"\
52.92 - "</wsp:AppliesTo>"\
52.93 - "</wst:RequestSecurityToken>"\
52.94 - "%s" /* Other RSTn tokens */\
52.95 - "</ps:RequestMultipleSecurityTokens>"\
52.96 - "</Body>"\
52.97 -"</Envelope>"
52.98 -
52.99 -#define MSN_SSO_AUTHINFO_TEMPLATE \
52.100 -"<ps:AuthInfo xmlns:ps=\"http://schemas.microsoft.com/Passport/SoapServices/PPCRL\" Id=\"PPAuthInfo\">"\
52.101 - "<ps:HostingApp>{7108E71A-9926-4FCB-BCC9-9A9D3F32E423}</ps:HostingApp>"\
52.102 - "<ps:BinaryVersion>4</ps:BinaryVersion>"\
52.103 - "<ps:UIVersion>1</ps:UIVersion>"\
52.104 - "<ps:Cookies></ps:Cookies>"\
52.105 - "<ps:RequestParams>AQAAAAIAAABsYwQAAAA0MTA1</ps:RequestParams>"\
52.106 -"</ps:AuthInfo>"
52.107 -/* Not sure what's editable here, so I'll just hard-code the SHA1 hash */
52.108 -#define MSN_SSO_AUTHINFO_SHA1_BASE64 "d2IeTF4DAkPEa/tVETHznsivEpc="
52.109 -
52.110 -#define MSN_SSO_TIMESTAMP_TEMPLATE \
52.111 -"<wsu:Timestamp xmlns=\"http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd\" Id=\"Timestamp\">"\
52.112 - "<wsu:Created>%s</wsu:Created>"\
52.113 - "<wsu:Expires>%s</wsu:Expires>"\
52.114 -"</wsu:Timestamp>"
52.115 -
52.116 -#define MSN_SSO_SIGNEDINFO_TEMPLATE \
52.117 -"<SignedInfo xmlns=\"http://www.w3.org/2000/09/xmldsig#\">"\
52.118 - "<CanonicalizationMethod Algorithm=\"http://www.w3.org/2001/10/xml-exc-c14n#\"></CanonicalizationMethod>"\
52.119 - "<SignatureMethod Algorithm=\"http://www.w3.org/2000/09/xmldsig#hmac-sha1\"></SignatureMethod>"\
52.120 - "<Reference URI=\"#RST%d\">"\
52.121 - "<Transforms>"\
52.122 - "<Transform Algorithm=\"http://www.w3.org/2001/10/xml-exc-c14n#\"></Transform>"\
52.123 - "</Transforms>"\
52.124 - "<DigestMethod Algorithm=\"http://www.w3.org/2000/09/xmldsig#sha1\"></DigestMethod>"\
52.125 - "<DigestValue>%s</DigestValue>"\
52.126 - "</Reference>"\
52.127 - "<Reference URI=\"#Timestamp\">"\
52.128 - "<Transforms>"\
52.129 - "<Transform Algorithm=\"http://www.w3.org/2001/10/xml-exc-c14n#\"></Transform>"\
52.130 - "</Transforms>"\
52.131 - "<DigestMethod Algorithm=\"http://www.w3.org/2000/09/xmldsig#sha1\"></DigestMethod>"\
52.132 - "<DigestValue>%s</DigestValue>"\
52.133 - "</Reference>"\
52.134 - "<Reference URI=\"#PPAuthInfo\">"\
52.135 - "<Transforms>"\
52.136 - "<Transform Algorithm=\"http://www.w3.org/2001/10/xml-exc-c14n#\"></Transform>"\
52.137 - "</Transforms>"\
52.138 - "<DigestMethod Algorithm=\"http://www.w3.org/2000/09/xmldsig#sha1\"></DigestMethod>"\
52.139 - "<DigestValue>" MSN_SSO_AUTHINFO_SHA1_BASE64 "</DigestValue>"\
52.140 - "</Reference>"\
52.141 -"</SignedInfo>"
52.142 -
52.143 -#define MSN_SSO_TOKEN_UPDATE_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
52.144 -"<Envelope"\
52.145 - " xmlns=\"http://schemas.xmlsoap.org/soap/envelope/\""\
52.146 - " xmlns:wsse=\"http://schemas.xmlsoap.org/ws/2003/06/secext\""\
52.147 - " xmlns:saml=\"urn:oasis:names:tc:SAML:1.0:assertion\""\
52.148 - " xmlns:wsp=\"http://schemas.xmlsoap.org/ws/2002/12/policy\""\
52.149 - " xmlns:wsu=\"http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd\""\
52.150 - " xmlns:wsa=\"http://schemas.xmlsoap.org/ws/2004/03/addressing\""\
52.151 - " xmlns:wssc=\"http://schemas.xmlsoap.org/ws/2004/04/sc\""\
52.152 - " xmlns:wst=\"http://schemas.xmlsoap.org/ws/2004/04/trust\">"\
52.153 - "<Header>"\
52.154 - MSN_SSO_AUTHINFO_TEMPLATE /* ps:AuthInfo */ \
52.155 - "<wsse:Security>"\
52.156 - "<EncryptedData xmlns=\"http://www.w3.org/2001/04/xmlenc#\" Id=\"BinaryDAToken0\" Type=\"http://www.w3.org/2001/04/xmlenc#Element\">"\
52.157 - "<EncryptionMethod Algorithm=\"http://www.w3.org/2001/04/xmlenc#tripledes-cbc\"></EncryptionMethod>"\
52.158 - "<ds:KeyInfo xmlns:ds=\"http://www.w3.org/2000/09/xmldsig#\">"\
52.159 - "<ds:KeyName>http://Passport.NET/STS</ds:KeyName>"\
52.160 - "</ds:KeyInfo>"\
52.161 - "<CipherData>"\
52.162 - "<CipherValue>%s</CipherValue>"\
52.163 - "</CipherData>"\
52.164 - "</EncryptedData>"\
52.165 - "<wssc:DerivedKeyToken Id=\"SignKey\">"\
52.166 - "<wsse:RequestedTokenReference>"\
52.167 - "<wsse:KeyIdentifier ValueType=\"http://docs.oasis-open.org/wss/2004/XX/oasis-2004XX-wss-saml-token-profile-1.0#SAMLAssertionID\" />"\
52.168 - "<wsse:Reference URI=\"#BinaryDAToken0\" />"\
52.169 - "</wsse:RequestedTokenReference>"\
52.170 - "<wssc:Nonce>%s</wssc:Nonce>"\
52.171 - "</wssc:DerivedKeyToken>"\
52.172 - "%s" /* wsu:Timestamp */\
52.173 - "<Signature xmlns=\"http://www.w3.org/2000/09/xmldsig#\">"\
52.174 - "%s" /* SignedInfo */\
52.175 - "<SignatureValue>%s</SignatureValue>"\
52.176 - "<KeyInfo>"\
52.177 - "<wsse:SecurityTokenReference>"\
52.178 - "<wsse:Reference URI=\"#SignKey\" />"\
52.179 - "</wsse:SecurityTokenReference>"\
52.180 - "</KeyInfo>"\
52.181 - "</Signature>"\
52.182 - "</wsse:Security>"\
52.183 - "</Header>"\
52.184 - "<Body>"\
52.185 - "%s" /* wst:RequestSecurityToken */ \
52.186 - "</Body>"\
52.187 -"</Envelope>"
52.188 -
52.189 -typedef struct _MsnUsrKey MsnUsrKey;
52.190 -struct _MsnUsrKey
52.191 -{
52.192 - int size; /* 28. Does not count data */
52.193 - int crypt_mode; /* CRYPT_MODE_CBC (1) */
52.194 - int cipher_type; /* TripleDES (0x6603) */
52.195 - int hash_type; /* SHA1 (0x8004) */
52.196 - int iv_len; /* 8 */
52.197 - int hash_len; /* 20 */
52.198 - int cipher_len; /* 72 */
52.199 - /* Data */
52.200 - char iv[8];
52.201 - char hash[20];
52.202 - char cipher[72];
52.203 -};
52.204 -
52.205 -typedef struct _MsnTicketToken MsnTicketToken;
52.206 -struct _MsnTicketToken {
52.207 - GHashTable *token;
52.208 - char *secret;
52.209 - time_t expiry;
52.210 - GSList *updates;
52.211 -};
52.212 -
52.213 -typedef struct _MsnNexus MsnNexus;
52.214 -
52.215 -struct _MsnNexus
52.216 -{
52.217 - MsnSession *session;
52.218 -
52.219 - /* From server via USR command */
52.220 - char *policy;
52.221 - char *nonce;
52.222 -
52.223 - /* From server via SOAP stuff */
52.224 - char *cipher;
52.225 - char *secret;
52.226 - MsnTicketToken *tokens;
52.227 - int token_len;
52.228 -};
52.229 -
52.230 -void msn_nexus_connect(MsnNexus *nexus);
52.231 -MsnNexus *msn_nexus_new(MsnSession *session);
52.232 -void msn_nexus_destroy(MsnNexus *nexus);
52.233 -GHashTable *msn_nexus_get_token(MsnNexus *nexus, MsnAuthDomains id);
52.234 -const char *msn_nexus_get_token_str(MsnNexus *nexus, MsnAuthDomains id);
52.235 -void msn_nexus_update_token(MsnNexus *nexus, int id, GSourceFunc cb, gpointer data);
52.236 -#endif /* _MSN_NEXUS_H_ */
52.237 -
53.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/notification.h Sun Jun 21 22:04:11 2009 -0400
53.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
53.3 @@ -1,96 +0,0 @@
53.4 -/**
53.5 - * @file notification.h Notification server functions
53.6 - *
53.7 - * purple
53.8 - *
53.9 - * Purple is the legal property of its developers, whose names are too numerous
53.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
53.11 - * source distribution.
53.12 - *
53.13 - * This program is free software; you can redistribute it and/or modify
53.14 - * it under the terms of the GNU General Public License as published by
53.15 - * the Free Software Foundation; either version 2 of the License, or
53.16 - * (at your option) any later version.
53.17 - *
53.18 - * This program is distributed in the hope that it will be useful,
53.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
53.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
53.21 - * GNU General Public License for more details.
53.22 - *
53.23 - * You should have received a copy of the GNU General Public License
53.24 - * along with this program; if not, write to the Free Software
53.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
53.26 - */
53.27 -#ifndef _MSN_NOTIFICATION_H_
53.28 -#define _MSN_NOTIFICATION_H_
53.29 -
53.30 -/*MSN protocol challenge info*/
53.31 -
53.32 -/*MSNP15 challenge: WLM 8.5.1288.816*/
53.33 -#define MSNP15_WLM_PRODUCT_KEY "ILTXC!4IXB5FB*PX"
53.34 -#define MSNP15_WLM_PRODUCT_ID "PROD0119GSJUC$18"
53.35 -
53.36 -/*MSNP13 challenge*/
53.37 -#define MSNP13_WLM_PRODUCT_KEY "O4BG@C7BWLYQX?5G"
53.38 -#define MSNP13_WLM_PRODUCT_ID "PROD01065C%ZFN6F"
53.39 -
53.40 -#define MSNP10_PRODUCT_KEY "VT6PX?UQTM4WM%YR"
53.41 -#define MSNP10_PRODUCT_ID "PROD0038W!61ZTF9"
53.42 -
53.43 -typedef struct _MsnNotification MsnNotification;
53.44 -
53.45 -#include "session.h"
53.46 -#include "servconn.h"
53.47 -#include "cmdproc.h"
53.48 -#include "user.h"
53.49 -
53.50 -struct _MsnNotification
53.51 -{
53.52 - MsnSession *session;
53.53 -
53.54 - /**
53.55 - * This is a convenience pointer that always points to
53.56 - * servconn->cmdproc
53.57 - */
53.58 - MsnCmdProc *cmdproc;
53.59 - MsnServConn *servconn;
53.60 -
53.61 - gboolean in_use;
53.62 -};
53.63 -
53.64 -typedef void (*MsnFqyCb)(MsnSession *session, const char *passport, MsnNetwork network);
53.65 -
53.66 -#include "state.h"
53.67 -void uum_send_msg(MsnSession *session,MsnMessage *msg);
53.68 -
53.69 -void msn_notification_end(void);
53.70 -void msn_notification_init(void);
53.71 -
53.72 -void msn_notification_add_buddy_to_list(MsnNotification *notification,
53.73 - MsnListId list_id, MsnUser *user);
53.74 -void msn_notification_rem_buddy_from_list(MsnNotification *notification,
53.75 - MsnListId list_id, MsnUser *user);
53.76 -
53.77 -void msn_notification_send_fqy(MsnSession *session,
53.78 - const char *payload, int payload_len,
53.79 - MsnFqyCb cb);
53.80 -
53.81 -MsnNotification *msn_notification_new(MsnSession *session);
53.82 -void msn_notification_destroy(MsnNotification *notification);
53.83 -gboolean msn_notification_connect(MsnNotification *notification,
53.84 - const char *host, int port);
53.85 -void msn_notification_disconnect(MsnNotification *notification);
53.86 -void msn_notification_dump_contact(MsnSession *session);
53.87 -
53.88 -/**
53.89 - * Closes a notification.
53.90 - *
53.91 - * It's first closed, and then disconnected.
53.92 - *
53.93 - * @param notification The notification object to close.
53.94 - */
53.95 -void msn_notification_close(MsnNotification *notification);
53.96 -
53.97 -void msn_got_login_params(MsnSession *session, const char *ticket, const char *response);
53.98 -
53.99 -#endif /* _MSN_NOTIFICATION_H_ */
54.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/notify.h Sun Jun 21 22:04:11 2009 -0400
54.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
54.3 @@ -1,789 +0,0 @@
54.4 -/**
54.5 - * @file notify.h Notification API
54.6 - * @ingroup core
54.7 - * @see @ref notify-signals
54.8 - */
54.9 -
54.10 -/* purple
54.11 - *
54.12 - * Purple is the legal property of its developers, whose names are too numerous
54.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
54.14 - * source distribution.
54.15 - *
54.16 - * This program is free software; you can redistribute it and/or modify
54.17 - * it under the terms of the GNU General Public License as published by
54.18 - * the Free Software Foundation; either version 2 of the License, or
54.19 - * (at your option) any later version.
54.20 - *
54.21 - * This program is distributed in the hope that it will be useful,
54.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
54.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
54.24 - * GNU General Public License for more details.
54.25 - *
54.26 - * You should have received a copy of the GNU General Public License
54.27 - * along with this program; if not, write to the Free Software
54.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
54.29 - */
54.30 -#ifndef _PURPLE_NOTIFY_H_
54.31 -#define _PURPLE_NOTIFY_H_
54.32 -
54.33 -#include <stdlib.h>
54.34 -#include <glib-object.h>
54.35 -#include <glib.h>
54.36 -
54.37 -typedef struct _PurpleNotifyUserInfoEntry PurpleNotifyUserInfoEntry;
54.38 -typedef struct _PurpleNotifyUserInfo PurpleNotifyUserInfo;
54.39 -
54.40 -#include "connection.h"
54.41 -
54.42 -/**
54.43 - * Notification close callbacks.
54.44 - */
54.45 -typedef void (*PurpleNotifyCloseCallback) (gpointer user_data);
54.46 -
54.47 -
54.48 -/**
54.49 - * Notification types.
54.50 - */
54.51 -typedef enum
54.52 -{
54.53 - PURPLE_NOTIFY_MESSAGE = 0, /**< Message notification. */
54.54 - PURPLE_NOTIFY_EMAIL, /**< Single email notification. */
54.55 - PURPLE_NOTIFY_EMAILS, /**< Multiple email notification. */
54.56 - PURPLE_NOTIFY_FORMATTED, /**< Formatted text. */
54.57 - PURPLE_NOTIFY_SEARCHRESULTS, /**< Buddy search results. */
54.58 - PURPLE_NOTIFY_USERINFO, /**< Formatted userinfo text. */
54.59 - PURPLE_NOTIFY_URI /**< URI notification or display. */
54.60 -
54.61 -} PurpleNotifyType;
54.62 -
54.63 -
54.64 -/**
54.65 - * Notification message types.
54.66 - */
54.67 -typedef enum
54.68 -{
54.69 - PURPLE_NOTIFY_MSG_ERROR = 0, /**< Error notification. */
54.70 - PURPLE_NOTIFY_MSG_WARNING, /**< Warning notification. */
54.71 - PURPLE_NOTIFY_MSG_INFO /**< Information notification. */
54.72 -
54.73 -} PurpleNotifyMsgType;
54.74 -
54.75 -
54.76 -/**
54.77 - * The types of buttons
54.78 - */
54.79 -typedef enum
54.80 -{
54.81 - PURPLE_NOTIFY_BUTTON_LABELED = 0, /**< special use, see _button_add_labeled */
54.82 - PURPLE_NOTIFY_BUTTON_CONTINUE = 1,
54.83 - PURPLE_NOTIFY_BUTTON_ADD,
54.84 - PURPLE_NOTIFY_BUTTON_INFO,
54.85 - PURPLE_NOTIFY_BUTTON_IM,
54.86 - PURPLE_NOTIFY_BUTTON_JOIN,
54.87 - PURPLE_NOTIFY_BUTTON_INVITE
54.88 -} PurpleNotifySearchButtonType;
54.89 -
54.90 -
54.91 -/**
54.92 - * Search results object.
54.93 - */
54.94 -typedef struct
54.95 -{
54.96 - GList *columns; /**< List of the search column objects. */
54.97 - GList *rows; /**< List of rows in the result. */
54.98 - GList *buttons; /**< List of buttons to display. */
54.99 -
54.100 -} PurpleNotifySearchResults;
54.101 -
54.102 -/**
54.103 - * Types of PurpleNotifyUserInfoEntry objects
54.104 - */
54.105 -typedef enum
54.106 -{
54.107 - PURPLE_NOTIFY_USER_INFO_ENTRY_PAIR = 0,
54.108 - PURPLE_NOTIFY_USER_INFO_ENTRY_SECTION_BREAK,
54.109 - PURPLE_NOTIFY_USER_INFO_ENTRY_SECTION_HEADER
54.110 -} PurpleNotifyUserInfoEntryType;
54.111 -
54.112 -/**
54.113 - * Single column of a search result.
54.114 - */
54.115 -typedef struct
54.116 -{
54.117 - char *title; /**< Title of the column. */
54.118 -
54.119 -} PurpleNotifySearchColumn;
54.120 -
54.121 -
54.122 -/**
54.123 - * Callback for a button in a search result.
54.124 - *
54.125 - * @param c the PurpleConnection passed to purple_notify_searchresults
54.126 - * @param row the contents of the selected row
54.127 - * @param user_data User defined data.
54.128 - */
54.129 -typedef void (*PurpleNotifySearchResultsCallback)(PurpleConnection *c, GList *row,
54.130 - gpointer user_data);
54.131 -
54.132 -
54.133 -/**
54.134 - * Definition of a button.
54.135 - */
54.136 -typedef struct
54.137 -{
54.138 - PurpleNotifySearchButtonType type;
54.139 - PurpleNotifySearchResultsCallback callback; /**< Function to be called when clicked. */
54.140 - char *label; /**< only for PURPLE_NOTIFY_BUTTON_LABELED */
54.141 -} PurpleNotifySearchButton;
54.142 -
54.143 -
54.144 -/**
54.145 - * Notification UI operations.
54.146 - */
54.147 -typedef struct
54.148 -{
54.149 - void *(*notify_message)(PurpleNotifyMsgType type, const char *title,
54.150 - const char *primary, const char *secondary);
54.151 -
54.152 - void *(*notify_email)(PurpleConnection *gc,
54.153 - const char *subject, const char *from,
54.154 - const char *to, const char *url);
54.155 -
54.156 - void *(*notify_emails)(PurpleConnection *gc,
54.157 - size_t count, gboolean detailed,
54.158 - const char **subjects, const char **froms,
54.159 - const char **tos, const char **urls);
54.160 -
54.161 - void *(*notify_formatted)(const char *title, const char *primary,
54.162 - const char *secondary, const char *text);
54.163 -
54.164 - void *(*notify_searchresults)(PurpleConnection *gc, const char *title,
54.165 - const char *primary, const char *secondary,
54.166 - PurpleNotifySearchResults *results, gpointer user_data);
54.167 -
54.168 - void (*notify_searchresults_new_rows)(PurpleConnection *gc,
54.169 - PurpleNotifySearchResults *results,
54.170 - void *data);
54.171 -
54.172 - void *(*notify_userinfo)(PurpleConnection *gc, const char *who,
54.173 - PurpleNotifyUserInfo *user_info);
54.174 -
54.175 - void *(*notify_uri)(const char *uri);
54.176 -
54.177 - void (*close_notify)(PurpleNotifyType type, void *ui_handle);
54.178 -
54.179 - void (*_purple_reserved1)(void);
54.180 - void (*_purple_reserved2)(void);
54.181 - void (*_purple_reserved3)(void);
54.182 - void (*_purple_reserved4)(void);
54.183 -} PurpleNotifyUiOps;
54.184 -
54.185 -
54.186 -#ifdef __cplusplus
54.187 -extern "C" {
54.188 -#endif
54.189 -
54.190 -
54.191 -/**************************************************************************/
54.192 -/** Search results notification API */
54.193 -/**************************************************************************/
54.194 -/*@{*/
54.195 -
54.196 -/**
54.197 - * Displays results from a buddy search. This can be, for example,
54.198 - * a window with a list of all found buddies, where you are given the
54.199 - * option of adding buddies to your buddy list.
54.200 - *
54.201 - * @param gc The PurpleConnection handle associated with the information.
54.202 - * @param title The title of the message. If this is NULL, the title
54.203 - * will be "Search Results."
54.204 - * @param primary The main point of the message.
54.205 - * @param secondary The secondary information.
54.206 - * @param results The PurpleNotifySearchResults instance.
54.207 - * @param cb The callback to call when the user closes
54.208 - * the notification.
54.209 - * @param user_data The data to pass to the close callback and any other
54.210 - * callback associated with a button.
54.211 - *
54.212 - * @return A UI-specific handle.
54.213 - */
54.214 -void *purple_notify_searchresults(PurpleConnection *gc, const char *title,
54.215 - const char *primary, const char *secondary,
54.216 - PurpleNotifySearchResults *results, PurpleNotifyCloseCallback cb,
54.217 - gpointer user_data);
54.218 -
54.219 -/**
54.220 - * Frees a PurpleNotifySearchResults object.
54.221 - *
54.222 - * @param results The PurpleNotifySearchResults to free.
54.223 - */
54.224 -void purple_notify_searchresults_free(PurpleNotifySearchResults *results);
54.225 -
54.226 -/**
54.227 - * Replace old rows with the new. Reuse an existing window.
54.228 - *
54.229 - * @param gc The PurpleConnection structure.
54.230 - * @param results The PurpleNotifySearchResults structure.
54.231 - * @param data Data returned by the purple_notify_searchresults().
54.232 - */
54.233 -void purple_notify_searchresults_new_rows(PurpleConnection *gc,
54.234 - PurpleNotifySearchResults *results,
54.235 - void *data);
54.236 -
54.237 -
54.238 -/**
54.239 - * Adds a stock button that will be displayed in the search results dialog.
54.240 - *
54.241 - * @param results The search results object.
54.242 - * @param type Type of the button. (TODO: Only one button of a given type
54.243 - * can be displayed.)
54.244 - * @param cb Function that will be called on the click event.
54.245 - */
54.246 -void purple_notify_searchresults_button_add(PurpleNotifySearchResults *results,
54.247 - PurpleNotifySearchButtonType type,
54.248 - PurpleNotifySearchResultsCallback cb);
54.249 -
54.250 -
54.251 -/**
54.252 - * Adds a plain labelled button that will be displayed in the search results
54.253 - * dialog.
54.254 - *
54.255 - * @param results The search results object
54.256 - * @param label The label to display
54.257 - * @param cb Function that will be called on the click event
54.258 - */
54.259 -void purple_notify_searchresults_button_add_labeled(PurpleNotifySearchResults *results,
54.260 - const char *label,
54.261 - PurpleNotifySearchResultsCallback cb);
54.262 -
54.263 -
54.264 -/**
54.265 - * Returns a newly created search results object.
54.266 - *
54.267 - * @return The new search results object.
54.268 - */
54.269 -PurpleNotifySearchResults *purple_notify_searchresults_new(void);
54.270 -
54.271 -/**
54.272 - * Returns a newly created search result column object.
54.273 - *
54.274 - * @param title Title of the column. NOTE: Title will get g_strdup()ed.
54.275 - *
54.276 - * @return The new search column object.
54.277 - */
54.278 -PurpleNotifySearchColumn *purple_notify_searchresults_column_new(const char *title);
54.279 -
54.280 -/**
54.281 - * Adds a new column to the search result object.
54.282 - *
54.283 - * @param results The result object to which the column will be added.
54.284 - * @param column The column that will be added to the result object.
54.285 - */
54.286 -void purple_notify_searchresults_column_add(PurpleNotifySearchResults *results,
54.287 - PurpleNotifySearchColumn *column);
54.288 -
54.289 -/**
54.290 - * Adds a new row of the results to the search results object.
54.291 - *
54.292 - * @param results The search results object.
54.293 - * @param row The row of the results.
54.294 - */
54.295 -void purple_notify_searchresults_row_add(PurpleNotifySearchResults *results,
54.296 - GList *row);
54.297 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_NOTIFY_C_)
54.298 -/**
54.299 - * Returns a number of the rows in the search results object.
54.300 - *
54.301 - * @deprecated This function will be removed in Pidgin 3.0.0 unless
54.302 - * there is sufficient demand to keep it. Using this
54.303 - * function encourages looping through the results
54.304 - * inefficiently. Instead of using this function you
54.305 - * should iterate through the results using a loop
54.306 - * similar to this:
54.307 - * for (l = results->rows; l != NULL; l = l->next)
54.308 - * If you really need to get the number of rows you
54.309 - * can use g_list_length(results->rows).
54.310 - *
54.311 - * @param results The search results object.
54.312 - *
54.313 - * @return Number of the result rows.
54.314 - */
54.315 -guint purple_notify_searchresults_get_rows_count(PurpleNotifySearchResults *results);
54.316 -#endif
54.317 -
54.318 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_NOTIFY_C_)
54.319 -/**
54.320 - * Returns a number of the columns in the search results object.
54.321 - *
54.322 - * @deprecated This function will be removed in Pidgin 3.0.0 unless
54.323 - * there is sufficient demand to keep it. Using this
54.324 - * function encourages looping through the columns
54.325 - * inefficiently. Instead of using this function you
54.326 - * should iterate through the columns using a loop
54.327 - * similar to this:
54.328 - * for (l = results->columns; l != NULL; l = l->next)
54.329 - * If you really need to get the number of columns you
54.330 - * can use g_list_length(results->columns).
54.331 - *
54.332 - * @param results The search results object.
54.333 - *
54.334 - * @return Number of the columns.
54.335 - */
54.336 -guint purple_notify_searchresults_get_columns_count(PurpleNotifySearchResults *results);
54.337 -#endif
54.338 -
54.339 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_NOTIFY_C_)
54.340 -/**
54.341 - * Returns a row of the results from the search results object.
54.342 - *
54.343 - * @deprecated This function will be removed in Pidgin 3.0.0 unless
54.344 - * there is sufficient demand to keep it. Using this
54.345 - * function encourages looping through the results
54.346 - * inefficiently. Instead of using this function you
54.347 - * should iterate through the results using a loop
54.348 - * similar to this:
54.349 - * for (l = results->rows; l != NULL; l = l->next)
54.350 - * If you really need to get the data for a particular
54.351 - * row you can use g_list_nth_data(results->rows, row_id).
54.352 - *
54.353 - * @param results The search results object.
54.354 - * @param row_id Index of the row to be returned.
54.355 - *
54.356 - * @return Row of the results.
54.357 - */
54.358 -GList *purple_notify_searchresults_row_get(PurpleNotifySearchResults *results,
54.359 - unsigned int row_id);
54.360 -#endif
54.361 -
54.362 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_NOTIFY_C_)
54.363 -/**
54.364 - * Returns a title of the search results object's column.
54.365 - *
54.366 - * @deprecated This function will be removed in Pidgin 3.0.0 unless
54.367 - * there is sufficient demand to keep it. Using this
54.368 - * function encourages looping through the columns
54.369 - * inefficiently. Instead of using this function you
54.370 - * should iterate through the name of a particular
54.371 - * column you can use
54.372 - * g_list_nth_data(results->columns, row_id).
54.373 - *
54.374 - * @param results The search results object.
54.375 - * @param column_id Index of the column.
54.376 - *
54.377 - * @return Title of the column.
54.378 - */
54.379 -char *purple_notify_searchresults_column_get_title(PurpleNotifySearchResults *results,
54.380 - unsigned int column_id);
54.381 -#endif
54.382 -
54.383 -/*@}*/
54.384 -
54.385 -/**************************************************************************/
54.386 -/** @name Notification API */
54.387 -/**************************************************************************/
54.388 -/*@{*/
54.389 -
54.390 -/**
54.391 - * Displays a notification message to the user.
54.392 - *
54.393 - * @param handle The plugin or connection handle.
54.394 - * @param type The notification type.
54.395 - * @param title The title of the message.
54.396 - * @param primary The main point of the message.
54.397 - * @param secondary The secondary information.
54.398 - * @param cb The callback to call when the user closes
54.399 - * the notification.
54.400 - * @param user_data The data to pass to the callback.
54.401 - *
54.402 - * @return A UI-specific handle.
54.403 - */
54.404 -void *purple_notify_message(void *handle, PurpleNotifyMsgType type,
54.405 - const char *title, const char *primary,
54.406 - const char *secondary, PurpleNotifyCloseCallback cb,
54.407 - gpointer user_data);
54.408 -
54.409 -/**
54.410 - * Displays a single email notification to the user.
54.411 - *
54.412 - * @param handle The plugin or connection handle.
54.413 - * @param subject The subject of the email.
54.414 - * @param from The from address.
54.415 - * @param to The destination address.
54.416 - * @param url The URL where the message can be read.
54.417 - * @param cb The callback to call when the user closes
54.418 - * the notification.
54.419 - * @param user_data The data to pass to the callback.
54.420 - *
54.421 - * @return A UI-specific handle.
54.422 - */
54.423 -void *purple_notify_email(void *handle, const char *subject,
54.424 - const char *from, const char *to,
54.425 - const char *url, PurpleNotifyCloseCallback cb,
54.426 - gpointer user_data);
54.427 -
54.428 -/**
54.429 - * Displays a notification for multiple emails to the user.
54.430 - *
54.431 - * @param handle The plugin or connection handle.
54.432 - * @param count The number of emails.
54.433 - * @param detailed @c TRUE if there is information for each email in the
54.434 - * arrays.
54.435 - * @param subjects The array of subjects.
54.436 - * @param froms The array of from addresses.
54.437 - * @param tos The array of destination addresses.
54.438 - * @param urls The URLs where the messages can be read.
54.439 - * @param cb The callback to call when the user closes
54.440 - * the notification.
54.441 - * @param user_data The data to pass to the callback.
54.442 - *
54.443 - * @return A UI-specific handle.
54.444 - */
54.445 -void *purple_notify_emails(void *handle, size_t count, gboolean detailed,
54.446 - const char **subjects, const char **froms,
54.447 - const char **tos, const char **urls,
54.448 - PurpleNotifyCloseCallback cb, gpointer user_data);
54.449 -
54.450 -/**
54.451 - * Displays a notification with formatted text.
54.452 - *
54.453 - * The text is essentially a stripped-down format of HTML, the same that
54.454 - * IMs may send.
54.455 - *
54.456 - * @param handle The plugin or connection handle.
54.457 - * @param title The title of the message.
54.458 - * @param primary The main point of the message.
54.459 - * @param secondary The secondary information.
54.460 - * @param text The formatted text.
54.461 - * @param cb The callback to call when the user closes
54.462 - * the notification.
54.463 - * @param user_data The data to pass to the callback.
54.464 - *
54.465 - * @return A UI-specific handle.
54.466 - */
54.467 -void *purple_notify_formatted(void *handle, const char *title,
54.468 - const char *primary, const char *secondary,
54.469 - const char *text, PurpleNotifyCloseCallback cb, gpointer user_data);
54.470 -
54.471 -/**
54.472 - * Displays user information with formatted text, passing information giving
54.473 - * the connection and username from which the user information came.
54.474 - *
54.475 - * The text is essentially a stripped-down format of HTML, the same that
54.476 - * IMs may send.
54.477 - *
54.478 - * @param gc The PurpleConnection handle associated with the information.
54.479 - * @param who The username associated with the information.
54.480 - * @param user_info The PurpleNotifyUserInfo which contains the information
54.481 - * @param cb The callback to call when the user closes the notification.
54.482 - * @param user_data The data to pass to the callback.
54.483 - *
54.484 - * @return A UI-specific handle.
54.485 - */
54.486 -void *purple_notify_userinfo(PurpleConnection *gc, const char *who,
54.487 - PurpleNotifyUserInfo *user_info, PurpleNotifyCloseCallback cb,
54.488 - gpointer user_data);
54.489 -
54.490 -/**
54.491 - * Create a new PurpleNotifyUserInfo which is suitable for passing to
54.492 - * purple_notify_userinfo()
54.493 - *
54.494 - * @return A new PurpleNotifyUserInfo, which the caller must destroy when done
54.495 - */
54.496 -PurpleNotifyUserInfo *purple_notify_user_info_new(void);
54.497 -
54.498 -/**
54.499 - * Destroy a PurpleNotifyUserInfo
54.500 - *
54.501 - * @param user_info The PurpleNotifyUserInfo
54.502 - */
54.503 -void purple_notify_user_info_destroy(PurpleNotifyUserInfo *user_info);
54.504 -
54.505 -/**
54.506 - * Retrieve the array of PurpleNotifyUserInfoEntry objects from a
54.507 - * PurpleNotifyUserInfo
54.508 - *
54.509 - * This GList may be manipulated directly with normal GList functions such
54.510 - * as g_list_insert(). Only PurpleNotifyUserInfoEntry are allowed in the
54.511 - * list. If a PurpleNotifyUserInfoEntry item is added to the list, it
54.512 - * should not be g_free()'d by the caller; PurpleNotifyUserInfo will g_free
54.513 - * it when destroyed.
54.514 - *
54.515 - * To remove a PurpleNotifyUserInfoEntry, use
54.516 - * purple_notify_user_info_remove_entry(). Do not use the GList directly.
54.517 - *
54.518 - * @param user_info The PurpleNotifyUserInfo
54.519 - *
54.520 - * @constreturn A GList of PurpleNotifyUserInfoEntry objects
54.521 - */
54.522 -GList *purple_notify_user_info_get_entries(PurpleNotifyUserInfo *user_info);
54.523 -
54.524 -/**
54.525 - * Create a textual representation of a PurpleNotifyUserInfo, separating
54.526 - * entries with newline
54.527 - *
54.528 - * @param user_info The PurpleNotifyUserInfo
54.529 - * @param newline The separation character
54.530 - */
54.531 -char *purple_notify_user_info_get_text_with_newline(PurpleNotifyUserInfo *user_info, const char *newline);
54.532 -
54.533 -/**
54.534 - * Add a label/value pair to a PurpleNotifyUserInfo object.
54.535 - * PurpleNotifyUserInfo keeps track of the order in which pairs are added.
54.536 - *
54.537 - * @param user_info The PurpleNotifyUserInfo
54.538 - * @param label A label, which for example might be displayed by a
54.539 - * UI with a colon after it ("Status:"). Do not include
54.540 - * a colon. If NULL, value will be displayed without a
54.541 - * label.
54.542 - * @param value The value, which might be displayed by a UI after
54.543 - * the label. If NULL, label will still be displayed;
54.544 - * the UI should then treat label as independent and not
54.545 - * include a colon if it would otherwise.
54.546 - */
54.547 -void purple_notify_user_info_add_pair(PurpleNotifyUserInfo *user_info, const char *label, const char *value);
54.548 -
54.549 -/**
54.550 - * Prepend a label/value pair to a PurpleNotifyUserInfo object
54.551 - *
54.552 - * @param user_info The PurpleNotifyUserInfo
54.553 - * @param label A label, which for example might be displayed by a
54.554 - * UI with a colon after it ("Status:"). Do not include
54.555 - * a colon. If NULL, value will be displayed without a
54.556 - * label.
54.557 - * @param value The value, which might be displayed by a UI after
54.558 - * the label. If NULL, label will still be displayed;
54.559 - * the UI should then treat label as independent and not
54.560 - * include a colon if it would otherwise.
54.561 - */
54.562 -void purple_notify_user_info_prepend_pair(PurpleNotifyUserInfo *user_info, const char *label, const char *value);
54.563 -
54.564 -/**
54.565 - * Remove a PurpleNotifyUserInfoEntry from a PurpleNotifyUserInfo object
54.566 - * without freeing the entry.
54.567 - *
54.568 - * @param user_info The PurpleNotifyUserInfo
54.569 - * @param user_info_entry The PurpleNotifyUserInfoEntry
54.570 - */
54.571 -void purple_notify_user_info_remove_entry(PurpleNotifyUserInfo *user_info, PurpleNotifyUserInfoEntry *user_info_entry);
54.572 -
54.573 -/**
54.574 - * Create a new PurpleNotifyUserInfoEntry
54.575 - *
54.576 - * If added to a PurpleNotifyUserInfo object, this should not be free()'d,
54.577 - * as PurpleNotifyUserInfo will do so when destroyed.
54.578 - * purple_notify_user_info_add_pair() and
54.579 - * purple_notify_user_info_prepend_pair() are convenience methods for
54.580 - * creating entries and adding them to a PurpleNotifyUserInfo.
54.581 - *
54.582 - * @param label A label, which for example might be displayed by a UI
54.583 - * with a colon after it ("Status:"). Do not include a
54.584 - * colon. If NULL, value will be displayed without a label.
54.585 - * @param value The value, which might be displayed by a UI after the
54.586 - * label. If NULL, label will still be displayed; the UI
54.587 - * should then treat label as independent and not include a
54.588 - * colon if it would otherwise.
54.589 - *
54.590 - * @result A new PurpleNotifyUserInfoEntry
54.591 - */
54.592 -PurpleNotifyUserInfoEntry *purple_notify_user_info_entry_new(const char *label, const char *value);
54.593 -
54.594 -/**
54.595 - * Add a section break. A UI might display this as a horizontal line.
54.596 - *
54.597 - * @param user_info The PurpleNotifyUserInfo
54.598 - */
54.599 -void purple_notify_user_info_add_section_break(PurpleNotifyUserInfo *user_info);
54.600 -
54.601 -/**
54.602 - * Prepend a section break. A UI might display this as a horizontal line.
54.603 - *
54.604 - * @param user_info The PurpleNotifyUserInfo
54.605 - * @since 2.5.0
54.606 - */
54.607 -void purple_notify_user_info_prepend_section_break(PurpleNotifyUserInfo *user_info);
54.608 -
54.609 -/**
54.610 - * Add a section header. A UI might display this in a different font
54.611 - * from other text.
54.612 - *
54.613 - * @param user_info The PurpleNotifyUserInfo
54.614 - * @param label The name of the section
54.615 - */
54.616 -void purple_notify_user_info_add_section_header(PurpleNotifyUserInfo *user_info, const char *label);
54.617 -
54.618 -/**
54.619 - * Prepend a section header. A UI might display this in a different font
54.620 - * from other text.
54.621 - *
54.622 - * @param user_info The PurpleNotifyUserInfo
54.623 - * @param label The name of the section
54.624 - * @since 2.5.0
54.625 - */
54.626 -void purple_notify_user_info_prepend_section_header(PurpleNotifyUserInfo *user_info, const char *label);
54.627 -
54.628 -/**
54.629 - * Remove the last item which was added to a PurpleNotifyUserInfo. This
54.630 - * could be used to remove a section header which is not needed.
54.631 - */
54.632 -void purple_notify_user_info_remove_last_item(PurpleNotifyUserInfo *user_info);
54.633 -
54.634 -/**
54.635 - * Get the label for a PurpleNotifyUserInfoEntry
54.636 - *
54.637 - * @param user_info_entry The PurpleNotifyUserInfoEntry
54.638 - *
54.639 - * @return The label
54.640 - */
54.641 -const gchar *purple_notify_user_info_entry_get_label(PurpleNotifyUserInfoEntry *user_info_entry);
54.642 -
54.643 -/**
54.644 - * Set the label for a PurpleNotifyUserInfoEntry
54.645 - *
54.646 - * @param user_info_entry The PurpleNotifyUserInfoEntry
54.647 - * @param label The label
54.648 - */
54.649 -void purple_notify_user_info_entry_set_label(PurpleNotifyUserInfoEntry *user_info_entry, const char *label);
54.650 -
54.651 -/**
54.652 - * Get the value for a PurpleNotifyUserInfoEntry
54.653 - *
54.654 - * @param user_info_entry The PurpleNotifyUserInfoEntry
54.655 - *
54.656 - * @result The value
54.657 - */
54.658 -const gchar *purple_notify_user_info_entry_get_value(PurpleNotifyUserInfoEntry *user_info_entry);
54.659 -
54.660 -/**
54.661 - * Set the value for a PurpleNotifyUserInfoEntry
54.662 - *
54.663 - * @param user_info_entry The PurpleNotifyUserInfoEntry
54.664 - * @param value The value
54.665 - */
54.666 -void purple_notify_user_info_entry_set_value(PurpleNotifyUserInfoEntry *user_info_entry, const char *value);
54.667 -
54.668 -
54.669 -/**
54.670 - * Get the type of a PurpleNotifyUserInfoEntry
54.671 - *
54.672 - * @param user_info_entry The PurpleNotifyUserInfoEntry
54.673 - *
54.674 - * @return The PurpleNotifyUserInfoEntryType
54.675 - */
54.676 -PurpleNotifyUserInfoEntryType purple_notify_user_info_entry_get_type(PurpleNotifyUserInfoEntry *user_info_entry);
54.677 -
54.678 -/**
54.679 - * Set the type of a PurpleNotifyUserInfoEntry
54.680 - *
54.681 - * @param user_info_entry The PurpleNotifyUserInfoEntry
54.682 - * @param type The PurpleNotifyUserInfoEntryType
54.683 - */
54.684 -void purple_notify_user_info_entry_set_type(PurpleNotifyUserInfoEntry *user_info_entry,
54.685 - PurpleNotifyUserInfoEntryType type);
54.686 -
54.687 -/**
54.688 - * Opens a URI or somehow presents it to the user.
54.689 - *
54.690 - * @param handle The plugin or connection handle.
54.691 - * @param uri The URI to display or go to.
54.692 - *
54.693 - * @return A UI-specific handle, if any. This may only be presented if
54.694 - * the UI code displays a dialog instead of a webpage, or something
54.695 - * similar.
54.696 - */
54.697 -void *purple_notify_uri(void *handle, const char *uri);
54.698 -
54.699 -/**
54.700 - * Closes a notification.
54.701 - *
54.702 - * This should be used only by the UI operation functions and part of the
54.703 - * core.
54.704 - *
54.705 - * @param type The notification type.
54.706 - * @param ui_handle The notification UI handle.
54.707 - */
54.708 -void purple_notify_close(PurpleNotifyType type, void *ui_handle);
54.709 -
54.710 -/**
54.711 - * Closes all notifications registered with the specified handle.
54.712 - *
54.713 - * @param handle The handle.
54.714 - */
54.715 -void purple_notify_close_with_handle(void *handle);
54.716 -
54.717 -/**
54.718 - * A wrapper for purple_notify_message that displays an information message.
54.719 - */
54.720 -#define purple_notify_info(handle, title, primary, secondary) \
54.721 - purple_notify_message((handle), PURPLE_NOTIFY_MSG_INFO, (title), \
54.722 - (primary), (secondary), NULL, NULL)
54.723 -
54.724 -/**
54.725 - * A wrapper for purple_notify_message that displays a warning message.
54.726 - */
54.727 -#define purple_notify_warning(handle, title, primary, secondary) \
54.728 - purple_notify_message((handle), PURPLE_NOTIFY_MSG_WARNING, (title), \
54.729 - (primary), (secondary), NULL, NULL)
54.730 -
54.731 -/**
54.732 - * A wrapper for purple_notify_message that displays an error message.
54.733 - */
54.734 -#define purple_notify_error(handle, title, primary, secondary) \
54.735 - purple_notify_message((handle), PURPLE_NOTIFY_MSG_ERROR, (title), \
54.736 - (primary), (secondary), NULL, NULL)
54.737 -
54.738 -/*@}*/
54.739 -
54.740 -/**************************************************************************/
54.741 -/** @name UI Registration Functions */
54.742 -/**************************************************************************/
54.743 -/*@{*/
54.744 -
54.745 -/**
54.746 - * Sets the UI operations structure to be used when displaying a
54.747 - * notification.
54.748 - *
54.749 - * @param ops The UI operations structure.
54.750 - */
54.751 -void purple_notify_set_ui_ops(PurpleNotifyUiOps *ops);
54.752 -
54.753 -/**
54.754 - * Returns the UI operations structure to be used when displaying a
54.755 - * notification.
54.756 - *
54.757 - * @return The UI operations structure.
54.758 - */
54.759 -PurpleNotifyUiOps *purple_notify_get_ui_ops(void);
54.760 -
54.761 -/*@}*/
54.762 -
54.763 -/**************************************************************************/
54.764 -/** @name Notify Subsystem */
54.765 -/**************************************************************************/
54.766 -/*@{*/
54.767 -
54.768 -/**
54.769 - * Returns the notify subsystem handle.
54.770 - *
54.771 - * @return The notify subsystem handle.
54.772 - */
54.773 -void *purple_notify_get_handle(void);
54.774 -
54.775 -/**
54.776 - * Initializes the notify subsystem.
54.777 - */
54.778 -void purple_notify_init(void);
54.779 -
54.780 -/**
54.781 - * Uninitializes the notify subsystem.
54.782 - */
54.783 -void purple_notify_uninit(void);
54.784 -
54.785 -/*@}*/
54.786 -
54.787 -
54.788 -#ifdef __cplusplus
54.789 -}
54.790 -#endif
54.791 -
54.792 -#endif /* _PURPLE_NOTIFY_H_ */
55.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/ntlm.h Sun Jun 21 22:04:11 2009 -0400
55.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
55.3 @@ -1,73 +0,0 @@
55.4 -/**
55.5 - * @file ntlm.h
55.6 - */
55.7 -
55.8 -/* purple
55.9 - *
55.10 - * Copyright (C) 2005, Thomas Butter <butter@uni-mannheim.de>
55.11 - *
55.12 - * ntlm structs are taken from NTLM description on
55.13 - * http://www.innovation.ch/java/ntlm.html
55.14 - *
55.15 - * This program is free software; you can redistribute it and/or modify
55.16 - * it under the terms of the GNU General Public License as published by
55.17 - * the Free Software Foundation; either version 2 of the License, or
55.18 - * (at your option) any later version.
55.19 - *
55.20 - * This program is distributed in the hope that it will be useful,
55.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
55.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
55.23 - * GNU General Public License for more details.
55.24 - *
55.25 - * You should have received a copy of the GNU General Public License
55.26 - * along with this program; if not, write to the Free Software
55.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
55.28 - */
55.29 -
55.30 -#ifndef _PURPLE_NTLM_H
55.31 -#define _PURPLE_NTLM_H
55.32 -
55.33 -#ifdef __cplusplus
55.34 -extern "C" {
55.35 -#endif
55.36 -
55.37 -/**
55.38 - * Generates the base64 encoded type 1 message needed for NTLM authentication
55.39 - *
55.40 - * @param hostname Your hostname
55.41 - * @param domain The domain to authenticate to
55.42 - * @return base64 encoded string to send to the server. This should
55.43 - * be g_free'd by the caller.
55.44 - */
55.45 -gchar *purple_ntlm_gen_type1(const gchar *hostname, const gchar *domain);
55.46 -
55.47 -/**
55.48 - * Parses the ntlm type 2 message
55.49 - *
55.50 - * @param type2 String containing the base64 encoded type2 message
55.51 - * @param flags If not @c NULL, this will store the flags for the message
55.52 - *
55.53 - * @return The nonce for use in message type3. This is a statically
55.54 - * allocated 8 byte binary string.
55.55 - */
55.56 -guint8 *purple_ntlm_parse_type2(const gchar *type2, guint32 *flags);
55.57 -
55.58 -/**
55.59 - * Generates a type3 message
55.60 - *
55.61 - * @param username The username
55.62 - * @param passw The password
55.63 - * @param hostname The hostname
55.64 - * @param domain The domain to authenticate against
55.65 - * @param nonce The nonce returned by purple_ntlm_parse_type2
55.66 - * @param flags Pointer to the flags returned by purple_ntlm_parse_type2
55.67 - * @return A base64 encoded type3 message. This should be g_free'd by
55.68 - * the caller.
55.69 - */
55.70 -gchar *purple_ntlm_gen_type3(const gchar *username, const gchar *passw, const gchar *hostname, const gchar *domain, const guint8 *nonce, guint32 *flags);
55.71 -
55.72 -#ifdef __cplusplus
55.73 -}
55.74 -#endif
55.75 -
55.76 -#endif /* _PURPLE_NTLM_H */
56.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/object.h Sun Jun 21 22:04:11 2009 -0400
56.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
56.3 @@ -1,242 +0,0 @@
56.4 -/**
56.5 - * @file object.h MSNObject API
56.6 - *
56.7 - * purple
56.8 - *
56.9 - * Purple is the legal property of its developers, whose names are too numerous
56.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
56.11 - * source distribution.
56.12 - *
56.13 - * This program is free software; you can redistribute it and/or modify
56.14 - * it under the terms of the GNU General Public License as published by
56.15 - * the Free Software Foundation; either version 2 of the License, or
56.16 - * (at your option) any later version.
56.17 - *
56.18 - * This program is distributed in the hope that it will be useful,
56.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
56.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
56.21 - * GNU General Public License for more details.
56.22 - *
56.23 - * You should have received a copy of the GNU General Public License
56.24 - * along with this program; if not, write to the Free Software
56.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
56.26 - */
56.27 -#ifndef _MSN_OBJECT_H_
56.28 -#define _MSN_OBJECT_H_
56.29 -
56.30 -#include "imgstore.h"
56.31 -
56.32 -#include "internal.h"
56.33 -
56.34 -typedef enum
56.35 -{
56.36 - MSN_OBJECT_UNKNOWN = -1, /**< Unknown object */
56.37 - MSN_OBJECT_RESERVED1 = 1, /**< Reserved */
56.38 - MSN_OBJECT_EMOTICON = 2, /**< Custom Emoticon */
56.39 - MSN_OBJECT_USERTILE = 3, /**< UserTile (buddy icon) */
56.40 - MSN_OBJECT_RESERVED2 = 4, /**< Reserved */
56.41 - MSN_OBJECT_BACKGROUND = 5 /**< Background */
56.42 -
56.43 -} MsnObjectType;
56.44 -
56.45 -typedef struct
56.46 -{
56.47 - gboolean local;
56.48 -
56.49 - char *creator;
56.50 - int size;
56.51 - MsnObjectType type;
56.52 - PurpleStoredImage *img;
56.53 - char *location;
56.54 - char *friendly;
56.55 - char *sha1d;
56.56 - char *sha1c;
56.57 -
56.58 -} MsnObject;
56.59 -
56.60 -/**
56.61 - * Creates a MsnObject structure.
56.62 - *
56.63 - * @return A new MsnObject structure.
56.64 - */
56.65 -MsnObject *msn_object_new(void);
56.66 -
56.67 -/**
56.68 - * Creates a MsnObject structure from a string.
56.69 - *
56.70 - * @param str The string.
56.71 - *
56.72 - * @return The new MsnObject structure.
56.73 - */
56.74 -MsnObject *msn_object_new_from_string(const char *str);
56.75 -
56.76 -/**
56.77 - * Creates a MsnObject structure from a stored image
56.78 - *
56.79 - * @param img The image associated to object
56.80 - * @param location The object location as stored in MsnObject
56.81 - * @param creator The creator of the object
56.82 - * @param type The type of the object
56.83 - *
56.84 - * @return A new MsnObject structure
56.85 - */
56.86 -MsnObject *msn_object_new_from_image(PurpleStoredImage *img,
56.87 - const char *location, const char *creator, MsnObjectType type);
56.88 -
56.89 -/**
56.90 - * Destroys an MsnObject structure.
56.91 - *
56.92 - * @param obj The object structure.
56.93 - */
56.94 -void msn_object_destroy(MsnObject *obj);
56.95 -
56.96 -/**
56.97 - * Outputs a string representation of an MsnObject.
56.98 - *
56.99 - * @param obj The object.
56.100 - *
56.101 - * @return The string representation. This must be freed.
56.102 - */
56.103 -char *msn_object_to_string(const MsnObject *obj);
56.104 -
56.105 -/**
56.106 - * Sets the creator field in a MsnObject.
56.107 - *
56.108 - * @param creator The creator value.
56.109 - */
56.110 -void msn_object_set_creator(MsnObject *obj, const char *creator);
56.111 -
56.112 -/**
56.113 - * Sets the size field in a MsnObject.
56.114 - *
56.115 - * @param size The size value.
56.116 - */
56.117 -void msn_object_set_size(MsnObject *obj, int size);
56.118 -
56.119 -/**
56.120 - * Sets the type field in a MsnObject.
56.121 - *
56.122 - * @param type The type value.
56.123 - */
56.124 -void msn_object_set_type(MsnObject *obj, MsnObjectType type);
56.125 -
56.126 -/**
56.127 - * Sets the location field in a MsnObject.
56.128 - *
56.129 - * @param location The location value.
56.130 - */
56.131 -void msn_object_set_location(MsnObject *obj, const char *location);
56.132 -
56.133 -/**
56.134 - * Sets the friendly name field in a MsnObject.
56.135 - *
56.136 - * @param friendly The friendly name value.
56.137 - */
56.138 -void msn_object_set_friendly(MsnObject *obj, const char *friendly);
56.139 -
56.140 -/**
56.141 - * Sets the SHA1D field in a MsnObject.
56.142 - *
56.143 - * @param sha1d The sha1d value.
56.144 - */
56.145 -void msn_object_set_sha1d(MsnObject *obj, const char *sha1d);
56.146 -
56.147 -/**
56.148 - * Sets the SHA1C field in a MsnObject.
56.149 - *
56.150 - * @param sha1c The sha1c value.
56.151 - */
56.152 -void msn_object_set_sha1c(MsnObject *obj, const char *sha1c);
56.153 -
56.154 -/**
56.155 - * Associates an image with a MsnObject.
56.156 - *
56.157 - * @param obj The object.
56.158 - * @param img The image to associate.
56.159 - */
56.160 -void msn_object_set_image(MsnObject *obj, PurpleStoredImage *img);
56.161 -
56.162 -/**
56.163 - * Returns a MsnObject's creator value.
56.164 - *
56.165 - * @param obj The object.
56.166 - *
56.167 - * @return The creator value.
56.168 - */
56.169 -const char *msn_object_get_creator(const MsnObject *obj);
56.170 -
56.171 -/**
56.172 - * Returns a MsnObject's size value.
56.173 - *
56.174 - * @param obj The object.
56.175 - *
56.176 - * @return The size value.
56.177 - */
56.178 -int msn_object_get_size(const MsnObject *obj);
56.179 -
56.180 -/**
56.181 - * Returns a MsnObject's type.
56.182 - *
56.183 - * @param obj The object.
56.184 - *
56.185 - * @return The object type.
56.186 - */
56.187 -MsnObjectType msn_object_get_type(const MsnObject *obj);
56.188 -
56.189 -/**
56.190 - * Returns a MsnObject's location value.
56.191 - *
56.192 - * @param obj The object.
56.193 - *
56.194 - * @return The location value.
56.195 - */
56.196 -const char *msn_object_get_location(const MsnObject *obj);
56.197 -
56.198 -/**
56.199 - * Returns a MsnObject's friendly name value.
56.200 - *
56.201 - * @param obj The object.
56.202 - *
56.203 - * @return The friendly name value.
56.204 - */
56.205 -const char *msn_object_get_friendly(const MsnObject *obj);
56.206 -
56.207 -/**
56.208 - * Returns a MsnObject's SHA1D value.
56.209 - *
56.210 - * @param obj The object.
56.211 - *
56.212 - * @return The SHA1D value.
56.213 - */
56.214 -const char *msn_object_get_sha1d(const MsnObject *obj);
56.215 -
56.216 -/**
56.217 - * Returns a MsnObject's SHA1C value.
56.218 - *
56.219 - * @param obj The object.
56.220 - *
56.221 - * @return The SHA1C value.
56.222 - */
56.223 -const char *msn_object_get_sha1c(const MsnObject *obj);
56.224 -
56.225 -/**
56.226 - * Returns a MsnObject's SHA1C value if it exists, otherwise SHA1D.
56.227 - *
56.228 - * @param obj The object.
56.229 - *
56.230 - * @return The SHA1C value.
56.231 - */
56.232 -const char *msn_object_get_sha1(const MsnObject *obj);
56.233 -
56.234 -/**
56.235 - * Returns the image associated with the MsnObject.
56.236 - *
56.237 - * @param obj The object.
56.238 - *
56.239 - * @return The associated image.
56.240 - */
56.241 -PurpleStoredImage *msn_object_get_image(const MsnObject *obj);
56.242 -
56.243 -void msn_object_set_local(MsnObject *obj);
56.244 -
56.245 -#endif /* _MSN_OBJECT_H_ */
57.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/oim.h Sun Jun 21 22:04:11 2009 -0400
57.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
57.3 @@ -1,163 +0,0 @@
57.4 -/**
57.5 - * @file oim.h Header file for oim.c
57.6 - * Author
57.7 - * MaYuan<mayuan2006@gmail.com>
57.8 - * purple
57.9 - *
57.10 - * Purple is the legal property of its developers, whose names are too numerous
57.11 - * to list here. Please refer to the COPYRIGHT file distributed with this
57.12 - * source distribution.
57.13 - *
57.14 - * This program is free software; you can redistribute it and/or modify
57.15 - * it under the terms of the GNU General Public License as published by
57.16 - * the Free Software Foundation; either version 2 of the License, or
57.17 - * (at your option) any later version.
57.18 - *
57.19 - * This program is distributed in the hope that it will be useful,
57.20 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
57.21 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
57.22 - * GNU General Public License for more details.
57.23 - *
57.24 - * You should have received a copy of the GNU General Public License
57.25 - * along with this program; if not, write to the Free Software
57.26 - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
57.27 - */
57.28 -#ifndef _MSN_OIM_H_
57.29 -#define _MSN_OIM_H_
57.30 -
57.31 -/* OIM Retrieval Info */
57.32 -#define MSN_OIM_RETRIEVE_HOST "rsi.hotmail.com"
57.33 -#define MSN_OIM_RETRIEVE_URL "/rsi/rsi.asmx"
57.34 -
57.35 -/* OIM GetMetadata SOAP Template */
57.36 -#define MSN_OIM_GET_METADATA_ACTION "http://www.hotmail.msn.com/ws/2004/09/oim/rsi/GetMetadata"
57.37 -
57.38 -#define MSN_OIM_GET_METADATA_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
57.39 -"<soap:Envelope"\
57.40 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
57.41 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
57.42 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">"\
57.43 - "<soap:Header>"\
57.44 - "<PassportCookie xmlns=\"http://www.hotmail.msn.com/ws/2004/09/oim/rsi\">"\
57.45 - "<t>EMPTY</t>"\
57.46 - "<p>EMPTY</p>"\
57.47 - "</PassportCookie>"\
57.48 - "</soap:Header>"\
57.49 - "<soap:Body>"\
57.50 - "<GetMetadata xmlns=\"http://www.hotmail.msn.com/ws/2004/09/oim/rsi\" />"\
57.51 - "</soap:Body>"\
57.52 -"</soap:Envelope>"
57.53 -
57.54 -/*OIM GetMessage SOAP Template*/
57.55 -#define MSN_OIM_GET_SOAP_ACTION "http://www.hotmail.msn.com/ws/2004/09/oim/rsi/GetMessage"
57.56 -
57.57 -#define MSN_OIM_GET_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
57.58 -"<soap:Envelope"\
57.59 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
57.60 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
57.61 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">"\
57.62 - "<soap:Header>"\
57.63 - "<PassportCookie xmlns=\"http://www.hotmail.msn.com/ws/2004/09/oim/rsi\">"\
57.64 - "<t>EMPTY</t>"\
57.65 - "<p>EMPTY</p>"\
57.66 - "</PassportCookie>"\
57.67 - "</soap:Header>"\
57.68 - "<soap:Body>"\
57.69 - "<GetMessage xmlns=\"http://www.hotmail.msn.com/ws/2004/09/oim/rsi\">"\
57.70 - "<messageId>%s</messageId>"\
57.71 - "<alsoMarkAsRead>false</alsoMarkAsRead>"\
57.72 - "</GetMessage>"\
57.73 - "</soap:Body>"\
57.74 -"</soap:Envelope>"
57.75 -
57.76 -/*OIM DeleteMessages SOAP Template*/
57.77 -#define MSN_OIM_DEL_SOAP_ACTION "http://www.hotmail.msn.com/ws/2004/09/oim/rsi/DeleteMessages"
57.78 -
57.79 -#define MSN_OIM_DEL_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
57.80 -"<soap:Envelope"\
57.81 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
57.82 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
57.83 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">"\
57.84 - "<soap:Header>"\
57.85 - "<PassportCookie xmlns=\"http://www.hotmail.msn.com/ws/2004/09/oim/rsi\">"\
57.86 - "<t>EMPTY</t>"\
57.87 - "<p>EMPTY</p>"\
57.88 - "</PassportCookie>"\
57.89 - "</soap:Header>"\
57.90 - "<soap:Body>"\
57.91 - "<DeleteMessages xmlns=\"http://www.hotmail.msn.com/ws/2004/09/oim/rsi\">"\
57.92 - "<messageIds>"\
57.93 - "<messageId>%s</messageId>"\
57.94 - "</messageIds>"\
57.95 - "</DeleteMessages>"\
57.96 - "</soap:Body>"\
57.97 -"</soap:Envelope>"
57.98 -
57.99 -/*OIM Send SOAP Template*/
57.100 -#define MSN_OIM_MSG_TEMPLATE "MIME-Version: 1.0\n"\
57.101 - "Content-Type: text/plain; charset=UTF-8\n"\
57.102 - "Content-Transfer-Encoding: base64\n"\
57.103 - "X-OIM-Message-Type: OfflineMessage\n"\
57.104 - "X-OIM-Run-Id: {%s}\n"\
57.105 - "X-OIM-Sequence-Num: %d\n\n"
57.106 -
57.107 -#define MSN_OIM_SEND_HOST "ows.messenger.msn.com"
57.108 -#define MSN_OIM_SEND_URL "/OimWS/oim.asmx"
57.109 -#define MSN_OIM_SEND_SOAP_ACTION "http://messenger.live.com/ws/2006/09/oim/Store2"
57.110 -#define MSN_OIM_SEND_TEMPLATE "<?xml version=\"1.0\" encoding=\"utf-8\"?>"\
57.111 -"<soap:Envelope"\
57.112 - " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""\
57.113 - " xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\""\
57.114 - " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">"\
57.115 - "<soap:Header>"\
57.116 - "<From"\
57.117 - " memberName=\"%s\""\
57.118 - " friendlyName=\"%s\""\
57.119 - " xml:lang=\"en-US\""\
57.120 - " proxy=\"MSNMSGR\""\
57.121 - " xmlns=\"http://messenger.msn.com/ws/2004/09/oim/\""\
57.122 - " msnpVer=\"MSNP15\""\
57.123 - " buildVer=\"8.5.1288\"/>"\
57.124 - "<To memberName=\"%s\" xmlns=\"http://messenger.msn.com/ws/2004/09/oim/\"/>"\
57.125 - "<Ticket passport=\"EMPTY\" appid=\"%s\" lockkey=\"%s\" xmlns=\"http://messenger.msn.com/ws/2004/09/oim/\"/>"\
57.126 - "<Sequence xmlns=\"http://schemas.xmlsoap.org/ws/2003/03/rm\">"\
57.127 - "<Identifier xmlns=\"http://schemas.xmlsoap.org/ws/2002/07/utility\">http://messenger.msn.com</Identifier>"\
57.128 - "<MessageNumber>%d</MessageNumber>"\
57.129 - "</Sequence>"\
57.130 - "</soap:Header>"\
57.131 - "<soap:Body>"\
57.132 - "<MessageType xmlns=\"http://messenger.msn.com/ws/2004/09/oim/\">text</MessageType>"\
57.133 - "<Content xmlns=\"http://messenger.msn.com/ws/2004/09/oim/\">%s</Content>"\
57.134 - "</soap:Body>"\
57.135 -"</soap:Envelope>"
57.136 -
57.137 -typedef struct _MsnOim MsnOim;
57.138 -
57.139 -struct _MsnOim
57.140 -{
57.141 - MsnSession *session;
57.142 -
57.143 - GList * oim_list;
57.144 -
57.145 - char *challenge;
57.146 - char *run_id;
57.147 - gint send_seq;
57.148 - GQueue *send_queue;
57.149 -};
57.150 -
57.151 -/****************************************************
57.152 - * function prototype
57.153 - * **************************************************/
57.154 -MsnOim * msn_oim_new(MsnSession *session);
57.155 -void msn_oim_destroy(MsnOim *oim);
57.156 -
57.157 -void msn_parse_oim_msg(MsnOim *oim,const char *xmlmsg);
57.158 -
57.159 -/*Send OIM Message*/
57.160 -void msn_oim_prep_send_msg_info(MsnOim *oim, const char *membername,
57.161 - const char *friendname, const char *tomember,
57.162 - const char * msg);
57.163 -
57.164 -void msn_oim_send_msg(MsnOim *oim);
57.165 -
57.166 -#endif/* _MSN_OIM_H_*/
58.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/oscar.h Sun Jun 21 22:04:11 2009 -0400
58.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
58.3 @@ -1,1656 +0,0 @@
58.4 -/*
58.5 - * Purple's oscar protocol plugin
58.6 - * This file is the legal property of its developers.
58.7 - * Please see the AUTHORS file distributed alongside this file.
58.8 - *
58.9 - * This library is free software; you can redistribute it and/or
58.10 - * modify it under the terms of the GNU Lesser General Public
58.11 - * License as published by the Free Software Foundation; either
58.12 - * version 2 of the License, or (at your option) any later version.
58.13 - *
58.14 - * This library is distributed in the hope that it will be useful,
58.15 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
58.16 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
58.17 - * Lesser General Public License for more details.
58.18 - *
58.19 - * You should have received a copy of the GNU Lesser General Public
58.20 - * License along with this library; if not, write to the Free Software
58.21 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
58.22 -*/
58.23 -
58.24 -/*
58.25 - * Main libfaim header. Must be included in client for prototypes/macros.
58.26 - *
58.27 - * "come on, i turned a chick lesbian; i think this is the hackish equivalent"
58.28 - * -- Josh Myer
58.29 - *
58.30 - */
58.31 -
58.32 -#ifndef _OSCAR_H_
58.33 -#define _OSCAR_H_
58.34 -
58.35 -#include "circbuffer.h"
58.36 -#include "debug.h"
58.37 -#include "eventloop.h"
58.38 -#include "internal.h"
58.39 -#include "proxy.h"
58.40 -#include "sslconn.h"
58.41 -
58.42 -#include <stdio.h>
58.43 -#include <string.h>
58.44 -#include <fcntl.h>
58.45 -#include <sys/types.h>
58.46 -#include <stdlib.h>
58.47 -#include <stdarg.h>
58.48 -#include <errno.h>
58.49 -#include <time.h>
58.50 -
58.51 -#ifndef _WIN32
58.52 -#include <sys/time.h>
58.53 -#include <unistd.h>
58.54 -#include <netdb.h>
58.55 -#include <netinet/in.h>
58.56 -#include <sys/socket.h>
58.57 -#else
58.58 -#include "libc_interface.h"
58.59 -#endif
58.60 -
58.61 -typedef struct _ByteStream ByteStream;
58.62 -typedef struct _ClientInfo ClientInfo;
58.63 -typedef struct _FlapConnection FlapConnection;
58.64 -typedef struct _FlapFrame FlapFrame;
58.65 -typedef struct _IcbmArgsCh2 IcbmArgsCh2;
58.66 -typedef struct _IcbmCookie IcbmCookie;
58.67 -typedef struct _OscarData OscarData;
58.68 -typedef struct _QueuedSnac QueuedSnac;
58.69 -
58.70 -typedef guint32 aim_snacid_t;
58.71 -
58.72 -#include "snactypes.h"
58.73 -
58.74 -#ifdef __cplusplus
58.75 -extern "C" {
58.76 -#endif
58.77 -
58.78 -#define FAIM_SNAC_HASH_SIZE 16
58.79 -
58.80 -/*
58.81 - * Current Maximum Length for Screen Names (not including NULL)
58.82 - *
58.83 - * Currently only names up to 16 characters can be registered
58.84 - * however it is apparently legal for them to be larger.
58.85 - */
58.86 -#define MAXSNLEN 97
58.87 -
58.88 -/*
58.89 - * Current Maximum Length for Instant Messages
58.90 - *
58.91 - * This was found basically by experiment, but not wholly
58.92 - * accurate experiment. It should not be regarded
58.93 - * as completely correct. But its a decent approximation.
58.94 - *
58.95 - * Note that although we can send this much, its impossible
58.96 - * for WinAIM clients (up through the latest (4.0.1957)) to
58.97 - * send any more than 1kb. Amaze all your windows friends
58.98 - * with utterly oversized instant messages!
58.99 - */
58.100 -#define MAXMSGLEN 2544
58.101 -
58.102 -/*
58.103 - * Maximum size of a Buddy Icon.
58.104 - */
58.105 -#define MAXICONLEN 7168
58.106 -#define AIM_ICONIDENT "AVT1picture.id"
58.107 -
58.108 -/*
58.109 - * Current Maximum Length for Chat Room Messages
58.110 - *
58.111 - * This is actually defined by the protocol to be
58.112 - * dynamic, but I have yet to see due cause to
58.113 - * define it dynamically here. Maybe later.
58.114 - *
58.115 - */
58.116 -#define MAXCHATMSGLEN 512
58.117 -
58.118 -/*
58.119 - * Found by trial and error.
58.120 - */
58.121 -#define MAXAVAILMSGLEN 251
58.122 -
58.123 -/**
58.124 - * Maximum length for the password of an ICQ account
58.125 - */
58.126 -#define MAXICQPASSLEN 8
58.127 -
58.128 -#define AIM_MD5_STRING "AOL Instant Messenger (SM)"
58.129 -
58.130 -/*
58.131 - * Client info. Filled in by the client and passed in to
58.132 - * aim_send_login(). The information ends up getting passed to OSCAR
58.133 - * through the initial login command.
58.134 - *
58.135 - */
58.136 -struct _ClientInfo
58.137 -{
58.138 - const char *clientstring;
58.139 - guint16 clientid;
58.140 - guint16 major;
58.141 - guint16 minor;
58.142 - guint16 point;
58.143 - guint16 build;
58.144 - guint32 distrib;
58.145 - const char *country; /* two-letter abbrev */
58.146 - const char *lang; /* two-letter abbrev */
58.147 -};
58.148 -
58.149 -/* Needs to be checked */
58.150 -#define CLIENTINFO_AIM_3_5_1670 { \
58.151 - "AOL Instant Messenger (SM), version 3.5.1670/WIN32", \
58.152 - 0x0004, \
58.153 - 0x0003, 0x0005, \
58.154 - 0x0000, 0x0686, \
58.155 - 0x0000002a, \
58.156 - "us", "en", \
58.157 -}
58.158 -
58.159 -/* Needs to be checked */
58.160 -/* Latest winaim without ssi */
58.161 -#define CLIENTINFO_AIM_4_1_2010 { \
58.162 - "AOL Instant Messenger (SM), version 4.1.2010/WIN32", \
58.163 - 0x0004, \
58.164 - 0x0004, 0x0001, \
58.165 - 0x0000, 0x07da, \
58.166 - 0x0000004b, \
58.167 - "us", "en", \
58.168 -}
58.169 -
58.170 -/* Needs to be checked */
58.171 -#define CLIENTINFO_AIM_4_3_2188 { \
58.172 - "AOL Instant Messenger (SM), version 4.3.2188/WIN32", \
58.173 - 0x0109, \
58.174 - 0x0400, 0x0003, \
58.175 - 0x0000, 0x088c, \
58.176 - 0x00000086, \
58.177 - "us", "en", \
58.178 -}
58.179 -
58.180 -/* Needs to be checked */
58.181 -#define CLIENTINFO_AIM_4_8_2540 { \
58.182 - "AOL Instant Messenger (SM), version 4.8.2540/WIN32", \
58.183 - 0x0109, \
58.184 - 0x0004, 0x0008, \
58.185 - 0x0000, 0x09ec, \
58.186 - 0x000000af, \
58.187 - "us", "en", \
58.188 -}
58.189 -
58.190 -/* Needs to be checked */
58.191 -#define CLIENTINFO_AIM_5_0_2938 { \
58.192 - "AOL Instant Messenger, version 5.0.2938/WIN32", \
58.193 - 0x0109, \
58.194 - 0x0005, 0x0000, \
58.195 - 0x0000, 0x0b7a, \
58.196 - 0x00000000, \
58.197 - "us", "en", \
58.198 -}
58.199 -
58.200 -#define CLIENTINFO_AIM_5_1_3036 { \
58.201 - "AOL Instant Messenger, version 5.1.3036/WIN32", \
58.202 - 0x0109, \
58.203 - 0x0005, 0x0001, \
58.204 - 0x0000, 0x0bdc, \
58.205 - 0x000000d2, \
58.206 - "us", "en", \
58.207 -}
58.208 -
58.209 -#define CLIENTINFO_AIM_5_5_3415 { \
58.210 - "AOL Instant Messenger, version 5.5.3415/WIN32", \
58.211 - 0x0109, \
58.212 - 0x0005, 0x0005, \
58.213 - 0x0000, 0x0057, \
58.214 - 0x000000ef, \
58.215 - "us", "en", \
58.216 -}
58.217 -
58.218 -#define CLIENTINFO_AIM_5_9_3702 { \
58.219 - "AOL Instant Messenger, version 5.9.3702/WIN32", \
58.220 - 0x0109, \
58.221 - 0x0005, 0x0009, \
58.222 - 0x0000, 0x0e76, \
58.223 - 0x00000111, \
58.224 - "us", "en", \
58.225 -}
58.226 -
58.227 -#define CLIENTINFO_ICHAT_1_0 { \
58.228 - "Apple iChat", \
58.229 - 0x311a, \
58.230 - 0x0001, 0x0000, \
58.231 - 0x0000, 0x003c, \
58.232 - 0x000000c6, \
58.233 - "us", "en", \
58.234 -}
58.235 -
58.236 -/* Needs to be checked */
58.237 -#define CLIENTINFO_ICQ_4_65_3281 { \
58.238 - "ICQ Inc. - Product of ICQ (TM) 2000b.4.65.1.3281.85", \
58.239 - 0x010a, \
58.240 - 0x0004, 0x0041, \
58.241 - 0x0001, 0x0cd1, \
58.242 - 0x00000055, \
58.243 - "us", "en", \
58.244 -}
58.245 -
58.246 -/* Needs to be checked */
58.247 -#define CLIENTINFO_ICQ_5_34_3728 { \
58.248 - "ICQ Inc. - Product of ICQ (TM).2002a.5.34.1.3728.85", \
58.249 - 0x010a, \
58.250 - 0x0005, 0x0022, \
58.251 - 0x0001, 0x0e8f, \
58.252 - 0x00000055, \
58.253 - "us", "en", \
58.254 -}
58.255 -
58.256 -#define CLIENTINFO_ICQ_5_45_3777 { \
58.257 - "ICQ Inc. - Product of ICQ (TM).2003a.5.45.1.3777.85", \
58.258 - 0x010a, \
58.259 - 0x0005, 0x002d, \
58.260 - 0x0001, 0x0ec1, \
58.261 - 0x00000055, \
58.262 - "us", "en", \
58.263 -}
58.264 -
58.265 -#define CLIENTINFO_ICQ6_6_0_6059 { \
58.266 - "ICQ Client", \
58.267 - 0x010a, \
58.268 - 0x0006, 0x0000, \
58.269 - 0x0000, 0x17ab, \
58.270 - 0x00007535, \
58.271 - "us", "en", \
58.272 -}
58.273 -
58.274 -#define CLIENTINFO_ICQBASIC_14_3_1068 { \
58.275 - "ICQBasic", \
58.276 - 0x010a, \
58.277 - 0x0014, 0x0003, \
58.278 - 0x0000, 0x042c, \
58.279 - 0x0000043d, \
58.280 - "us", "en", \
58.281 -}
58.282 -
58.283 -#define CLIENTINFO_ICQBASIC_14_34_3000 { \
58.284 - "ICQBasic", \
58.285 - 0x010a, \
58.286 - 0x0014, 0x0034, \
58.287 - 0x0000, 0x0bb8, \
58.288 - 0x0000043d, \
58.289 - "us", "en", \
58.290 -}
58.291 -
58.292 -#define CLIENTINFO_ICQBASIC_14_34_3096 { \
58.293 - "ICQBasic", \
58.294 - 0x010a, \
58.295 - 0x0014, 0x0034, \
58.296 - 0x0000, 0x0c18, \
58.297 - 0x0000043d, \
58.298 - "us", "en", \
58.299 -}
58.300 -
58.301 -#define CLIENTINFO_NETSCAPE_7_0_1 { \
58.302 - "Netscape 2000 an approved user of AOL Instant Messenger (SM)", \
58.303 - 0x1d0d, \
58.304 - 0x0007, 0x0000, \
58.305 - 0x0001, 0x0000, \
58.306 - 0x00000058, \
58.307 - "us", "en", \
58.308 -}
58.309 -
58.310 -/*
58.311 - * We need to use the major-minor-micro versions from the official
58.312 - * AIM and ICQ programs here or AOL won't let us use certain features.
58.313 - */
58.314 -
58.315 -#define CLIENTINFO_PURPLE_AIM { \
58.316 - "Purple/" VERSION, \
58.317 - 0x0109, \
58.318 - 0x0005, 0x0001, \
58.319 - 0x0000, 0x0bdc, \
58.320 - 0x000000d2, \
58.321 - "us", "en", \
58.322 -}
58.323 -
58.324 -#define CLIENTINFO_PURPLE_ICQ { \
58.325 - "Purple/" VERSION, \
58.326 - 0x010a, \
58.327 - 0x0014, 0x0034, \
58.328 - 0x0000, 0x0c18, \
58.329 - 0x0000043d, \
58.330 - "us", "en", \
58.331 -}
58.332 -
58.333 -#define CLIENTINFO_AIM_KNOWNGOOD CLIENTINFO_AIM_5_1_3036
58.334 -#define CLIENTINFO_ICQ_KNOWNGOOD CLIENTINFO_ICQBASIC_14_34_3096
58.335 -
58.336 -typedef enum
58.337 -{
58.338 - OSCAR_DISCONNECT_DONE, /* not considered an error */
58.339 - OSCAR_DISCONNECT_LOCAL_CLOSED, /* peer connections only, not considered an error */
58.340 - OSCAR_DISCONNECT_REMOTE_CLOSED,
58.341 - OSCAR_DISCONNECT_REMOTE_REFUSED, /* peer connections only */
58.342 - OSCAR_DISCONNECT_LOST_CONNECTION,
58.343 - OSCAR_DISCONNECT_INVALID_DATA,
58.344 - OSCAR_DISCONNECT_COULD_NOT_CONNECT,
58.345 - OSCAR_DISCONNECT_RETRYING /* peer connections only */
58.346 -} OscarDisconnectReason;
58.347 -
58.348 -typedef enum
58.349 -{
58.350 - OSCAR_CAPABILITY_BUDDYICON = 0x00000001,
58.351 - OSCAR_CAPABILITY_TALK = 0x00000002,
58.352 - OSCAR_CAPABILITY_DIRECTIM = 0x00000004,
58.353 - OSCAR_CAPABILITY_CHAT = 0x00000008,
58.354 - OSCAR_CAPABILITY_GETFILE = 0x00000010,
58.355 - OSCAR_CAPABILITY_SENDFILE = 0x00000020,
58.356 - OSCAR_CAPABILITY_GAMES = 0x00000040,
58.357 - OSCAR_CAPABILITY_ADDINS = 0x00000080,
58.358 - OSCAR_CAPABILITY_SENDBUDDYLIST = 0x00000100,
58.359 - OSCAR_CAPABILITY_GAMES2 = 0x00000200,
58.360 - OSCAR_CAPABILITY_ICQ_DIRECT = 0x00000400,
58.361 - OSCAR_CAPABILITY_APINFO = 0x00000800,
58.362 - OSCAR_CAPABILITY_ICQRTF = 0x00001000,
58.363 - OSCAR_CAPABILITY_EMPTY = 0x00002000,
58.364 - OSCAR_CAPABILITY_ICQSERVERRELAY = 0x00004000,
58.365 - OSCAR_CAPABILITY_UNICODEOLD = 0x00008000,
58.366 - OSCAR_CAPABILITY_TRILLIANCRYPT = 0x00010000,
58.367 - OSCAR_CAPABILITY_UNICODE = 0x00020000,
58.368 - OSCAR_CAPABILITY_INTEROPERATE = 0x00040000,
58.369 - OSCAR_CAPABILITY_SHORTCAPS = 0x00080000,
58.370 - OSCAR_CAPABILITY_HIPTOP = 0x00100000,
58.371 - OSCAR_CAPABILITY_SECUREIM = 0x00200000,
58.372 - OSCAR_CAPABILITY_SMS = 0x00400000,
58.373 - OSCAR_CAPABILITY_VIDEO = 0x00800000,
58.374 - OSCAR_CAPABILITY_ICHATAV = 0x01000000,
58.375 - OSCAR_CAPABILITY_LIVEVIDEO = 0x02000000,
58.376 - OSCAR_CAPABILITY_CAMERA = 0x04000000,
58.377 - OSCAR_CAPABILITY_ICHAT_SCREENSHARE = 0x08000000,
58.378 - OSCAR_CAPABILITY_TYPING = 0x10000000,
58.379 - OSCAR_CAPABILITY_GENERICUNKNOWN = 0x20000000,
58.380 - OSCAR_CAPABILITY_LAST = 0x40000000
58.381 -} OscarCapability;
58.382 -
58.383 -/*
58.384 - * Byte Stream type. Sort of.
58.385 - *
58.386 - * Use of this type serves a couple purposes:
58.387 - * - Buffer/buflen pairs are passed all around everywhere. This turns
58.388 - * that into one value, as well as abstracting it slightly.
58.389 - * - Through the abstraction, it is possible to enable bounds checking
58.390 - * for robustness at the cost of performance. But a clean failure on
58.391 - * weird packets is much better than a segfault.
58.392 - * - I like having variables named "bs".
58.393 - *
58.394 - * Don't touch the insides of this struct. Or I'll have to kill you.
58.395 - *
58.396 - */
58.397 -struct _ByteStream
58.398 -{
58.399 - guint8 *data;
58.400 - guint32 len;
58.401 - guint32 offset;
58.402 -};
58.403 -
58.404 -struct _QueuedSnac
58.405 -{
58.406 - guint16 family;
58.407 - guint16 subtype;
58.408 - FlapFrame *frame;
58.409 -};
58.410 -
58.411 -struct _FlapFrame
58.412 -{
58.413 - guint8 channel;
58.414 - guint16 seqnum;
58.415 - ByteStream data; /* payload stream */
58.416 -};
58.417 -
58.418 -struct _FlapConnection
58.419 -{
58.420 - OscarData *od; /**< Pointer to parent session. */
58.421 - gboolean connected;
58.422 - time_t lastactivity; /**< Time of last transmit. */
58.423 - guint destroy_timeout;
58.424 - OscarDisconnectReason disconnect_reason;
58.425 - gchar *error_message;
58.426 - guint16 disconnect_code;
58.427 -
58.428 - /* A few variables that are only used when connecting */
58.429 - PurpleProxyConnectData *connect_data;
58.430 - guint16 cookielen;
58.431 - guint8 *cookie;
58.432 - gpointer new_conn_data;
58.433 - gchar *ssl_cert_cn;
58.434 -
58.435 - int fd;
58.436 - PurpleSslConnection *gsc;
58.437 - guint8 header[6];
58.438 - gssize header_received;
58.439 - FlapFrame buffer_incoming;
58.440 - PurpleCircBuffer *buffer_outgoing;
58.441 - guint watcher_incoming;
58.442 - guint watcher_outgoing;
58.443 -
58.444 - guint16 type;
58.445 - guint16 subtype;
58.446 - guint16 seqnum_out; /**< The sequence number of most recently sent packet. */
58.447 - guint16 seqnum_in; /**< The sequence number of most recently received packet. */
58.448 - GSList *groups;
58.449 - GSList *rateclasses; /* Contains nodes of struct rateclass. */
58.450 -
58.451 - GQueue *queued_snacs; /**< Contains QueuedSnacs. */
58.452 - GQueue *queued_lowpriority_snacs; /**< Contains QueuedSnacs to send only once queued_snacs is empty */
58.453 - guint queued_timeout;
58.454 -
58.455 - void *internal; /* internal conn-specific libfaim data */
58.456 -};
58.457 -
58.458 -struct _IcbmCookie
58.459 -{
58.460 - guchar cookie[8];
58.461 - int type;
58.462 - void *data;
58.463 - time_t addtime;
58.464 - struct _IcbmCookie *next;
58.465 -};
58.466 -
58.467 -#include "peer.h"
58.468 -
58.469 -/*
58.470 - * AIM Session: The main client-data interface.
58.471 - *
58.472 - */
58.473 -struct _OscarData
58.474 -{
58.475 - gboolean iconconnecting;
58.476 - gboolean set_icon;
58.477 -
58.478 - GSList *create_rooms;
58.479 -
58.480 - gboolean conf;
58.481 - gboolean reqemail;
58.482 - gboolean setemail;
58.483 - char *email;
58.484 - gboolean setnick;
58.485 - char *newsn;
58.486 - gboolean chpass;
58.487 - char *oldp;
58.488 - char *newp;
58.489 -
58.490 - GSList *oscar_chats;
58.491 - GHashTable *buddyinfo;
58.492 - GSList *requesticon;
58.493 -
58.494 - gboolean use_ssl;
58.495 - gboolean icq;
58.496 - guint getblisttimer;
58.497 -
58.498 - struct {
58.499 - guint maxwatchers; /* max users who can watch you */
58.500 - guint maxbuddies; /* max users you can watch */
58.501 - guint maxgroups; /* max groups in server list */
58.502 - guint maxpermits; /* max users on permit list */
58.503 - guint maxdenies; /* max users on deny list */
58.504 - guint maxsiglen; /* max size (bytes) of profile */
58.505 - guint maxawaymsglen; /* max size (bytes) of posted away message */
58.506 - } rights;
58.507 -
58.508 - PurpleConnection *gc;
58.509 -
58.510 - void *modlistv;
58.511 -
58.512 - /*
58.513 - * Outstanding snac handling
58.514 - *
58.515 - * TODO: Should these be per-connection? -mid
58.516 - */
58.517 - void *snac_hash[FAIM_SNAC_HASH_SIZE];
58.518 - aim_snacid_t snacid_next;
58.519 -
58.520 - /*
58.521 - * TODO: Data specific to a certain family should go into a
58.522 - * hashtable and the core parts of libfaim shouldn't
58.523 - * need to know about them.
58.524 - */
58.525 -
58.526 - IcbmCookie *msgcookies;
58.527 - struct aim_icq_info *icq_info;
58.528 - struct aim_authresp_info *authinfo;
58.529 - struct aim_emailinfo *emailinfo;
58.530 -
58.531 - struct {
58.532 - struct aim_userinfo_s *userinfo;
58.533 - struct userinfo_node *requested;
58.534 - } locate;
58.535 -
58.536 - /* Server-stored information (ssi) */
58.537 - struct {
58.538 - gboolean received_data;
58.539 - guint16 numitems;
58.540 - struct aim_ssi_item *official;
58.541 - struct aim_ssi_item *local;
58.542 - struct aim_ssi_tmp *pending;
58.543 - time_t timestamp;
58.544 - gboolean waiting_for_ack;
58.545 - gboolean in_transaction;
58.546 - } ssi;
58.547 -
58.548 - /** Contains pointers to handler functions for each family/subtype. */
58.549 - GHashTable *handlerlist;
58.550 -
58.551 - /** A linked list containing FlapConnections. */
58.552 - GSList *oscar_connections;
58.553 -
58.554 - /** A linked list containing PeerConnections. */
58.555 - GSList *peer_connections;
58.556 -};
58.557 -
58.558 -/* Valid for calling aim_icq_setstatus() and for aim_userinfo_t->icqinfo.status */
58.559 -#define AIM_ICQ_STATE_NORMAL 0x00000000
58.560 -#define AIM_ICQ_STATE_AWAY 0x00000001
58.561 -#define AIM_ICQ_STATE_DND 0x00000002
58.562 -#define AIM_ICQ_STATE_OUT 0x00000004
58.563 -#define AIM_ICQ_STATE_BUSY 0x00000010
58.564 -#define AIM_ICQ_STATE_CHAT 0x00000020
58.565 -#define AIM_ICQ_STATE_INVISIBLE 0x00000100
58.566 -#define AIM_ICQ_STATE_WEBAWARE 0x00010000
58.567 -#define AIM_ICQ_STATE_HIDEIP 0x00020000
58.568 -#define AIM_ICQ_STATE_BIRTHDAY 0x00080000
58.569 -#define AIM_ICQ_STATE_DIRECTDISABLED 0x00100000
58.570 -#define AIM_ICQ_STATE_ICQHOMEPAGE 0x00200000
58.571 -#define AIM_ICQ_STATE_DIRECTREQUIREAUTH 0x10000000
58.572 -#define AIM_ICQ_STATE_DIRECTCONTACTLIST 0x20000000
58.573 -
58.574 -typedef int (*aim_rxcallback_t)(OscarData *od, FlapConnection *conn, FlapFrame *frame, ...);
58.575 -
58.576 -
58.577 -/* family_auth.c */
58.578 -struct aim_clientrelease
58.579 -{
58.580 - char *name;
58.581 - guint32 build;
58.582 - char *url;
58.583 - char *info;
58.584 -};
58.585 -
58.586 -struct aim_authresp_info
58.587 -{
58.588 - char *sn;
58.589 - guint16 errorcode;
58.590 - char *errorurl;
58.591 - guint16 regstatus;
58.592 - char *email;
58.593 - char *bosip;
58.594 - guint16 cookielen;
58.595 - guint8 *cookie;
58.596 - char *chpassurl;
58.597 - struct aim_clientrelease latestrelease;
58.598 - struct aim_clientrelease latestbeta;
58.599 -};
58.600 -
58.601 -/* Callback data for redirect. */
58.602 -struct aim_redirect_data
58.603 -{
58.604 - guint16 group;
58.605 - const char *ip;
58.606 - guint16 cookielen;
58.607 - const guint8 *cookie;
58.608 - const char *ssl_cert_cn;
58.609 - guint8 use_ssl;
58.610 - struct { /* group == SNAC_FAMILY_CHAT */
58.611 - guint16 exchange;
58.612 - const char *room;
58.613 - guint16 instance;
58.614 - } chat;
58.615 -};
58.616 -
58.617 -int aim_request_login(OscarData *od, FlapConnection *conn, const char *sn);
58.618 -int aim_send_login(OscarData *od, FlapConnection *conn, const char *sn, const char *password, gboolean truncate_pass, ClientInfo *ci, const char *key, gboolean allow_multiple_logins);
58.619 -/* 0x000b */ int aim_auth_securid_send(OscarData *od, const char *securid);
58.620 -
58.621 -void oscar_data_addhandler(OscarData *od, guint16 family, guint16 subtype, aim_rxcallback_t newhandler, guint16 flags);
58.622 -aim_rxcallback_t aim_callhandler(OscarData *od, guint16 family, guint16 subtype);
58.623 -
58.624 -/* flap_connection.c */
58.625 -FlapConnection *flap_connection_new(OscarData *, int type);
58.626 -void flap_connection_close(OscarData *od, FlapConnection *conn);
58.627 -void flap_connection_destroy(FlapConnection *conn, OscarDisconnectReason reason, const gchar *error_message);
58.628 -void flap_connection_schedule_destroy(FlapConnection *conn, OscarDisconnectReason reason, const gchar *error_message);
58.629 -FlapConnection *flap_connection_findbygroup(OscarData *od, guint16 group);
58.630 -FlapConnection *flap_connection_getbytype(OscarData *, int type);
58.631 -FlapConnection *flap_connection_getbytype_all(OscarData *, int type);
58.632 -void flap_connection_recv_cb(gpointer data, gint source, PurpleInputCondition cond);
58.633 -void flap_connection_recv_cb_ssl(gpointer data, PurpleSslConnection *gsc, PurpleInputCondition cond);
58.634 -
58.635 -void flap_connection_send(FlapConnection *conn, FlapFrame *frame);
58.636 -void flap_connection_send_version(OscarData *od, FlapConnection *conn);
58.637 -void flap_connection_send_version_with_cookie(OscarData *od, FlapConnection *conn, guint16 length, const guint8 *chipsahoy);
58.638 -void flap_connection_send_snac(OscarData *od, FlapConnection *conn, guint16 family, const guint16 subtype, guint16 flags, aim_snacid_t snacid, ByteStream *data);
58.639 -void flap_connection_send_snac_with_priority(OscarData *od, FlapConnection *conn, guint16 family, const guint16 subtype, guint16 flags, aim_snacid_t snacid, ByteStream *data, gboolean high_priority);
58.640 -void flap_connection_send_keepalive(OscarData *od, FlapConnection *conn);
58.641 -FlapFrame *flap_frame_new(OscarData *od, guint16 channel, int datalen);
58.642 -
58.643 -OscarData *oscar_data_new(void);
58.644 -void oscar_data_destroy(OscarData *);
58.645 -
58.646 -/* misc.c */
58.647 -#define AIM_VISIBILITYCHANGE_PERMITADD 0x05
58.648 -#define AIM_VISIBILITYCHANGE_PERMITREMOVE 0x06
58.649 -#define AIM_VISIBILITYCHANGE_DENYADD 0x07
58.650 -#define AIM_VISIBILITYCHANGE_DENYREMOVE 0x08
58.651 -
58.652 -#define AIM_PRIVFLAGS_ALLOWIDLE 0x01
58.653 -#define AIM_PRIVFLAGS_ALLOWMEMBERSINCE 0x02
58.654 -
58.655 -#define AIM_WARN_ANON 0x01
58.656 -
58.657 -
58.658 -
58.659 -/* 0x0001 - family_oservice.c */
58.660 -/* 0x0002 */ void aim_srv_clientready(OscarData *od, FlapConnection *conn);
58.661 -/* 0x0004 */ void aim_srv_requestnew(OscarData *od, guint16 serviceid);
58.662 -/* 0x0006 */ void aim_srv_reqrates(OscarData *od, FlapConnection *conn);
58.663 -/* 0x0008 */ void aim_srv_rates_addparam(OscarData *od, FlapConnection *conn);
58.664 -/* 0x0009 */ void aim_srv_rates_delparam(OscarData *od, FlapConnection *conn);
58.665 -/* 0x000c */ void aim_srv_sendpauseack(OscarData *od, FlapConnection *conn);
58.666 -/* 0x000e */ void aim_srv_reqpersonalinfo(OscarData *od, FlapConnection *conn);
58.667 -/* 0x0011 */ void aim_srv_setidle(OscarData *od, guint32 idletime);
58.668 -/* 0x0014 */ void aim_srv_setprivacyflags(OscarData *od, FlapConnection *conn, guint32);
58.669 -/* 0x0016 */ void aim_srv_nop(OscarData *od, FlapConnection *conn);
58.670 -/* 0x0017 */ void aim_srv_setversions(OscarData *od, FlapConnection *conn);
58.671 -/* 0x001e */ int aim_srv_setextrainfo(OscarData *od, gboolean seticqstatus, guint32 icqstatus, gboolean setavailmsg, const char *availmsg, const char *itmsurl);
58.672 -
58.673 -
58.674 -void aim_bos_reqrights(OscarData *od, FlapConnection *conn);
58.675 -int aim_bos_changevisibility(OscarData *od, FlapConnection *conn, int, const char *);
58.676 -void aim_bos_setgroupperm(OscarData *od, FlapConnection *conn, guint32 mask);
58.677 -
58.678 -
58.679 -
58.680 -#define AIM_CLIENTTYPE_UNKNOWN 0x0000
58.681 -#define AIM_CLIENTTYPE_MC 0x0001
58.682 -#define AIM_CLIENTTYPE_WINAIM 0x0002
58.683 -#define AIM_CLIENTTYPE_WINAIM41 0x0003
58.684 -#define AIM_CLIENTTYPE_AOL_TOC 0x0004
58.685 -guint16 aim_im_fingerprint(const guint8 *msghdr, int len);
58.686 -
58.687 -#define AIM_RATE_CODE_CHANGE 0x0001
58.688 -#define AIM_RATE_CODE_WARNING 0x0002
58.689 -#define AIM_RATE_CODE_LIMIT 0x0003
58.690 -#define AIM_RATE_CODE_CLEARLIMIT 0x0004
58.691 -void aim_ads_requestads(OscarData *od, FlapConnection *conn);
58.692 -
58.693 -
58.694 -
58.695 -/* family_icbm.c */
58.696 -#define AIM_OFT_SUBTYPE_SEND_FILE 0x0001
58.697 -#define AIM_OFT_SUBTYPE_SEND_DIR 0x0002
58.698 -#define AIM_OFT_SUBTYPE_GET_FILE 0x0011
58.699 -#define AIM_OFT_SUBTYPE_GET_LIST 0x0012
58.700 -
58.701 -#define AIM_TRANSFER_DENY_NOTSUPPORTED 0x0000
58.702 -#define AIM_TRANSFER_DENY_DECLINE 0x0001
58.703 -#define AIM_TRANSFER_DENY_NOTACCEPTING 0x0002
58.704 -
58.705 -#define AIM_IMPARAM_FLAG_CHANMSGS_ALLOWED 0x00000001
58.706 -#define AIM_IMPARAM_FLAG_MISSEDCALLS_ENABLED 0x00000002
58.707 -#define AIM_IMPARAM_FLAG_SUPPORT_OFFLINEMSGS 0x00000100
58.708 -
58.709 -/* This is what the server will give you if you don't set them yourself. */
58.710 -#define AIM_IMPARAM_DEFAULTS { \
58.711 - 0, \
58.712 - AIM_IMPARAM_FLAG_CHANMSGS_ALLOWED | AIM_IMPARAM_FLAG_MISSEDCALLS_ENABLED, \
58.713 - 512, /* !! Note how small this is. */ \
58.714 - (99.9)*10, (99.9)*10, \
58.715 - 1000 /* !! And how large this is. */ \
58.716 -}
58.717 -
58.718 -/* This is what most AIM versions use. */
58.719 -#define AIM_IMPARAM_REASONABLE { \
58.720 - 0, \
58.721 - AIM_IMPARAM_FLAG_CHANMSGS_ALLOWED | AIM_IMPARAM_FLAG_MISSEDCALLS_ENABLED, \
58.722 - 8000, \
58.723 - (99.9)*10, (99.9)*10, \
58.724 - 0 \
58.725 -}
58.726 -
58.727 -struct aim_icbmparameters
58.728 -{
58.729 - guint16 maxchan;
58.730 - guint32 flags; /* AIM_IMPARAM_FLAG_ */
58.731 - guint16 maxmsglen; /* message size that you will accept */
58.732 - guint16 maxsenderwarn; /* this and below are *10 (999=99.9%) */
58.733 - guint16 maxrecverwarn;
58.734 - guint32 minmsginterval; /* in milliseconds? */
58.735 -};
58.736 -
58.737 -/*
58.738 - * TODO: Should probably combine this with struct chat_connection.
58.739 - */
58.740 -struct aim_chat_roominfo
58.741 -{
58.742 - guint16 exchange;
58.743 - char *name;
58.744 - guint8 namelen;
58.745 - guint16 instance;
58.746 -};
58.747 -
58.748 -struct chat_connection
58.749 -{
58.750 - char *name;
58.751 - char *show; /* AOL did something funny to us */
58.752 - guint16 exchange;
58.753 - guint16 instance;
58.754 - FlapConnection *conn;
58.755 - int id;
58.756 - PurpleConnection *gc;
58.757 - PurpleConversation *conv;
58.758 - int maxlen;
58.759 - int maxvis;
58.760 -};
58.761 -
58.762 -/*
58.763 - * All this chat struct stuff should be in family_chat.c
58.764 - */
58.765 -void oscar_chat_destroy(struct chat_connection *cc);
58.766 -
58.767 -#define AIM_IMFLAGS_AWAY 0x0001 /* mark as an autoreply */
58.768 -#define AIM_IMFLAGS_ACK 0x0002 /* request a receipt notice */
58.769 -#define AIM_IMFLAGS_BUDDYREQ 0x0010 /* buddy icon requested */
58.770 -#define AIM_IMFLAGS_HASICON 0x0020 /* already has icon */
58.771 -#define AIM_IMFLAGS_SUBENC_MACINTOSH 0x0040 /* damn that Steve Jobs! */
58.772 -#define AIM_IMFLAGS_CUSTOMFEATURES 0x0080 /* features field present */
58.773 -#define AIM_IMFLAGS_EXTDATA 0x0100
58.774 -#define AIM_IMFLAGS_X 0x0200
58.775 -#define AIM_IMFLAGS_MULTIPART 0x0400 /* ->mpmsg section valid */
58.776 -#define AIM_IMFLAGS_OFFLINE 0x0800 /* send to offline user */
58.777 -#define AIM_IMFLAGS_TYPINGNOT 0x1000 /* typing notification */
58.778 -
58.779 -#define AIM_CHARSET_ASCII 0x0000
58.780 -#define AIM_CHARSET_UNICODE 0x0002 /* UTF-16BE */
58.781 -#define AIM_CHARSET_CUSTOM 0x0003
58.782 -
58.783 -/*
58.784 - * Multipart message structures.
58.785 - */
58.786 -typedef struct aim_mpmsg_section_s
58.787 -{
58.788 - guint16 charset;
58.789 - guint16 charsubset;
58.790 - gchar *data;
58.791 - guint16 datalen;
58.792 - struct aim_mpmsg_section_s *next;
58.793 -} aim_mpmsg_section_t;
58.794 -
58.795 -typedef struct aim_mpmsg_s
58.796 -{
58.797 - unsigned int numparts;
58.798 - aim_mpmsg_section_t *parts;
58.799 -} aim_mpmsg_t;
58.800 -
58.801 -int aim_mpmsg_init(OscarData *od, aim_mpmsg_t *mpm);
58.802 -int aim_mpmsg_addraw(OscarData *od, aim_mpmsg_t *mpm, guint16 charset, guint16 charsubset, const gchar *data, guint16 datalen);
58.803 -int aim_mpmsg_addascii(OscarData *od, aim_mpmsg_t *mpm, const char *ascii);
58.804 -int aim_mpmsg_addunicode(OscarData *od, aim_mpmsg_t *mpm, const guint16 *unicode, guint16 unicodelen);
58.805 -void aim_mpmsg_free(OscarData *od, aim_mpmsg_t *mpm);
58.806 -
58.807 -/*
58.808 - * Arguments to aim_send_im_ext().
58.809 - *
58.810 - * This is really complicated. But immensely versatile.
58.811 - *
58.812 - */
58.813 -struct aim_sendimext_args
58.814 -{
58.815 -
58.816 - /* These are _required_ */
58.817 - const char *destsn;
58.818 - guint32 flags; /* often 0 */
58.819 -
58.820 - /* Only required if not using multipart messages */
58.821 - const char *msg;
58.822 - int msglen;
58.823 -
58.824 - /* Required if ->msg is not provided */
58.825 - aim_mpmsg_t *mpmsg;
58.826 -
58.827 - /* Only used if AIM_IMFLAGS_HASICON is set */
58.828 - guint32 iconlen;
58.829 - time_t iconstamp;
58.830 - guint32 iconsum;
58.831 -
58.832 - /* Only used if AIM_IMFLAGS_CUSTOMFEATURES is set */
58.833 - guint16 featureslen;
58.834 - guint8 *features;
58.835 -
58.836 - /* Only used if AIM_IMFLAGS_CUSTOMCHARSET is set and mpmsg not used */
58.837 - guint16 charset;
58.838 - guint16 charsubset;
58.839 -};
58.840 -
58.841 -/*
58.842 - * Arguments to aim_send_rtfmsg().
58.843 - */
58.844 -struct aim_sendrtfmsg_args
58.845 -{
58.846 - const char *destsn;
58.847 - guint32 fgcolor;
58.848 - guint32 bgcolor;
58.849 - const char *rtfmsg; /* must be in RTF */
58.850 -};
58.851 -
58.852 -/*
58.853 - * This information is provided in the Incoming ICBM callback for
58.854 - * Channel 1 ICBM's.
58.855 - *
58.856 - * Note that although CUSTOMFEATURES and CUSTOMCHARSET say they
58.857 - * are optional, both are always set by the current libfaim code.
58.858 - * That may or may not change in the future. It is mainly for
58.859 - * consistency with aim_sendimext_args.
58.860 - *
58.861 - * Multipart messages require some explanation. If you want to use them,
58.862 - * I suggest you read all the comments in family_icbm.c.
58.863 - *
58.864 - */
58.865 -struct aim_incomingim_ch1_args
58.866 -{
58.867 -
58.868 - /* Always provided */
58.869 - aim_mpmsg_t mpmsg;
58.870 - guint32 icbmflags; /* some flags apply only to ->msg, not all mpmsg */
58.871 - time_t timestamp; /* Only set for offline messages */
58.872 -
58.873 - /* Only provided if message has a human-readable section */
58.874 - gchar *msg;
58.875 - int msglen;
58.876 -
58.877 - /* Only provided if AIM_IMFLAGS_HASICON is set */
58.878 - time_t iconstamp;
58.879 - guint32 iconlen;
58.880 - guint16 iconsum;
58.881 -
58.882 - /* Only provided if AIM_IMFLAGS_CUSTOMFEATURES is set */
58.883 - guint8 *features;
58.884 - guint8 featureslen;
58.885 -
58.886 - /* Only provided if AIM_IMFLAGS_EXTDATA is set */
58.887 - guint8 extdatalen;
58.888 - guint8 *extdata;
58.889 -
58.890 - /* Only used if AIM_IMFLAGS_CUSTOMCHARSET is set */
58.891 - guint16 charset;
58.892 - guint16 charsubset;
58.893 -};
58.894 -
58.895 -/* Valid values for channel 2 args->status */
58.896 -#define AIM_RENDEZVOUS_PROPOSE 0x0000
58.897 -#define AIM_RENDEZVOUS_CANCEL 0x0001
58.898 -#define AIM_RENDEZVOUS_CONNECTED 0x0002
58.899 -
58.900 -struct _IcbmArgsCh2
58.901 -{
58.902 - guint16 status;
58.903 - guchar cookie[8];
58.904 - int type; /* One of the OSCAR_CAPABILITY_ constants */
58.905 - const char *proxyip;
58.906 - const char *clientip;
58.907 - const char *verifiedip;
58.908 - guint16 port;
58.909 - gboolean use_proxy;
58.910 - guint16 errorcode;
58.911 - const char *msg; /* invite message or file description */
58.912 - guint16 msglen;
58.913 - const char *encoding;
58.914 - const char *language;
58.915 - guint16 requestnumber;
58.916 - union {
58.917 - struct {
58.918 - guint32 checksum;
58.919 - guint32 length;
58.920 - time_t timestamp;
58.921 - guint8 *icon;
58.922 - } icon;
58.923 - struct {
58.924 - struct aim_chat_roominfo roominfo;
58.925 - } chat;
58.926 - struct {
58.927 - guint16 msgtype;
58.928 - guint32 fgcolor;
58.929 - guint32 bgcolor;
58.930 - const char *rtfmsg;
58.931 - } rtfmsg;
58.932 - struct {
58.933 - guint16 subtype;
58.934 - guint16 totfiles;
58.935 - guint32 totsize;
58.936 - char *filename;
58.937 - } sendfile;
58.938 - } info;
58.939 - void *destructor; /* used internally only */
58.940 -};
58.941 -
58.942 -/* Valid values for channel 4 args->type */
58.943 -#define AIM_ICQMSG_AUTHREQUEST 0x0006
58.944 -#define AIM_ICQMSG_AUTHDENIED 0x0007
58.945 -#define AIM_ICQMSG_AUTHGRANTED 0x0008
58.946 -
58.947 -struct aim_incomingim_ch4_args
58.948 -{
58.949 - guint32 uin; /* Of the sender of the ICBM */
58.950 - guint8 type;
58.951 - guint8 flags;
58.952 - gchar *msg; /* Reason for auth request, deny, or accept */
58.953 - int msglen;
58.954 -};
58.955 -
58.956 -/* SNAC sending functions */
58.957 -/* 0x0002 */ int aim_im_setparams(OscarData *od, struct aim_icbmparameters *params);
58.958 -/* 0x0004 */ int aim_im_reqparams(OscarData *od);
58.959 -/* 0x0006 */ int aim_im_sendch1_ext(OscarData *od, struct aim_sendimext_args *args);
58.960 -/* 0x0006 */ int aim_im_sendch1(OscarData *, const char *destsn, guint16 flags, const char *msg);
58.961 -/* 0x0006 */ int aim_im_sendch2_chatinvite(OscarData *od, const char *sn, const char *msg, guint16 exchange, const char *roomname, guint16 instance);
58.962 -/* 0x0006 */ int aim_im_sendch2_icon(OscarData *od, const char *sn, const guint8 *icon, int iconlen, time_t stamp, guint16 iconsum);
58.963 -/* 0x0006 */ int aim_im_sendch2_rtfmsg(OscarData *od, struct aim_sendrtfmsg_args *args);
58.964 -
58.965 -/* 0x0006 */ void aim_im_sendch2_cancel(PeerConnection *peer_conn);
58.966 -/* 0x0006 */ void aim_im_sendch2_connected(PeerConnection *peer_conn);
58.967 -/* 0x0006 */ void aim_im_sendch2_odc_requestdirect(OscarData *od, guchar *cookie, const char *sn, const guint8 *ip, guint16 port, guint16 requestnumber);
58.968 -/* 0x0006 */ void aim_im_sendch2_odc_requestproxy(OscarData *od, guchar *cookie, const char *sn, const guint8 *ip, guint16 pin, guint16 requestnumber);
58.969 -/* 0x0006 */ void aim_im_sendch2_sendfile_requestdirect(OscarData *od, guchar *cookie, const char *sn, const guint8 *ip, guint16 port, guint16 requestnumber, const gchar *filename, guint32 size, guint16 numfiles);
58.970 -/* 0x0006 */ void aim_im_sendch2_sendfile_requestproxy(OscarData *od, guchar *cookie, const char *sn, const guint8 *ip, guint16 pin, guint16 requestnumber, const gchar *filename, guint32 size, guint16 numfiles);
58.971 -
58.972 -/* 0x0006 */ int aim_im_sendch2_geticqaway(OscarData *od, const char *sn, int type);
58.973 -/* 0x0006 */ int aim_im_sendch4(OscarData *od, const char *sn, guint16 type, const char *message);
58.974 -/* 0x0008 */ int aim_im_warn(OscarData *od, FlapConnection *conn, const char *destsn, guint32 flags);
58.975 -/* 0x000b */ int aim_im_denytransfer(OscarData *od, const char *sn, const guchar *cookie, guint16 code);
58.976 -/* 0x0010 */ int aim_im_reqofflinemsgs(OscarData *od);
58.977 -/* 0x0014 */ int aim_im_sendmtn(OscarData *od, guint16 type1, const char *sn, guint16 type2);
58.978 -void aim_icbm_makecookie(guchar* cookie);
58.979 -gchar *oscar_encoding_extract(const char *encoding);
58.980 -gchar *oscar_encoding_to_utf8(PurpleAccount *account, const char *encoding, const char *text, int textlen);
58.981 -gchar *purple_plugin_oscar_decode_im_part(PurpleAccount *account, const char *sourcesn, guint16 charset, guint16 charsubset, const gchar *data, gsize datalen);
58.982 -
58.983 -
58.984 -/* 0x0002 - family_locate.c */
58.985 -/*
58.986 - * AIM User Info, Standard Form.
58.987 - */
58.988 -#define AIM_FLAG_UNCONFIRMED 0x0001 /* "damned transients" */
58.989 -#define AIM_FLAG_ADMINISTRATOR 0x0002
58.990 -#define AIM_FLAG_AOL 0x0004
58.991 -#define AIM_FLAG_OSCAR_PAY 0x0008
58.992 -#define AIM_FLAG_FREE 0x0010
58.993 -#define AIM_FLAG_AWAY 0x0020
58.994 -#define AIM_FLAG_ICQ 0x0040
58.995 -#define AIM_FLAG_WIRELESS 0x0080
58.996 -#define AIM_FLAG_UNKNOWN100 0x0100
58.997 -#define AIM_FLAG_UNKNOWN200 0x0200
58.998 -#define AIM_FLAG_ACTIVEBUDDY 0x0400
58.999 -#define AIM_FLAG_UNKNOWN800 0x0800
58.1000 -#define AIM_FLAG_ABINTERNAL 0x1000
58.1001 -#define AIM_FLAG_ALLUSERS 0x001f
58.1002 -
58.1003 -#define AIM_USERINFO_PRESENT_FLAGS 0x00000001
58.1004 -#define AIM_USERINFO_PRESENT_MEMBERSINCE 0x00000002
58.1005 -#define AIM_USERINFO_PRESENT_ONLINESINCE 0x00000004
58.1006 -#define AIM_USERINFO_PRESENT_IDLE 0x00000008
58.1007 -#define AIM_USERINFO_PRESENT_ICQEXTSTATUS 0x00000010
58.1008 -#define AIM_USERINFO_PRESENT_ICQIPADDR 0x00000020
58.1009 -#define AIM_USERINFO_PRESENT_ICQDATA 0x00000040
58.1010 -#define AIM_USERINFO_PRESENT_CAPABILITIES 0x00000080
58.1011 -#define AIM_USERINFO_PRESENT_SESSIONLEN 0x00000100
58.1012 -#define AIM_USERINFO_PRESENT_CREATETIME 0x00000200
58.1013 -
58.1014 -struct userinfo_node
58.1015 -{
58.1016 - char *sn;
58.1017 - struct userinfo_node *next;
58.1018 -};
58.1019 -
58.1020 -typedef struct aim_userinfo_s
58.1021 -{
58.1022 - char *sn;
58.1023 - guint16 warnlevel; /* evil percent * 10 (999 = 99.9%) */
58.1024 - guint16 idletime; /* in seconds */
58.1025 - guint16 flags;
58.1026 - guint32 createtime; /* time_t */
58.1027 - guint32 membersince; /* time_t */
58.1028 - guint32 onlinesince; /* time_t */
58.1029 - guint32 sessionlen; /* in seconds */
58.1030 - guint32 capabilities;
58.1031 - struct {
58.1032 - guint32 status;
58.1033 - guint32 ipaddr;
58.1034 - guint8 crap[0x25]; /* until we figure it out... */
58.1035 - } icqinfo;
58.1036 - guint32 present;
58.1037 -
58.1038 - guint8 iconcsumtype;
58.1039 - guint16 iconcsumlen;
58.1040 - guint8 *iconcsum;
58.1041 -
58.1042 - char *info;
58.1043 - char *info_encoding;
58.1044 - guint16 info_len;
58.1045 -
58.1046 - char *status;
58.1047 - char *status_encoding;
58.1048 - guint16 status_len;
58.1049 -
58.1050 - char *itmsurl;
58.1051 - char *itmsurl_encoding;
58.1052 - guint16 itmsurl_len;
58.1053 -
58.1054 - char *away;
58.1055 - char *away_encoding;
58.1056 - guint16 away_len;
58.1057 -
58.1058 - struct aim_userinfo_s *next;
58.1059 -} aim_userinfo_t;
58.1060 -
58.1061 -#define AIM_SENDMEMBLOCK_FLAG_ISREQUEST 0
58.1062 -#define AIM_SENDMEMBLOCK_FLAG_ISHASH 1
58.1063 -
58.1064 -int aim_sendmemblock(OscarData *od, FlapConnection *conn, guint32 offset, guint32 len, const guint8 *buf, guint8 flag);
58.1065 -
58.1066 -struct aim_invite_priv
58.1067 -{
58.1068 - char *sn;
58.1069 - char *roomname;
58.1070 - guint16 exchange;
58.1071 - guint16 instance;
58.1072 -};
58.1073 -
58.1074 -#define AIM_COOKIETYPE_UNKNOWN 0x00
58.1075 -#define AIM_COOKIETYPE_ICBM 0x01
58.1076 -#define AIM_COOKIETYPE_ADS 0x02
58.1077 -#define AIM_COOKIETYPE_BOS 0x03
58.1078 -#define AIM_COOKIETYPE_IM 0x04
58.1079 -#define AIM_COOKIETYPE_CHAT 0x05
58.1080 -#define AIM_COOKIETYPE_CHATNAV 0x06
58.1081 -#define AIM_COOKIETYPE_INVITE 0x07
58.1082 -/* we'll move OFT up a bit to give breathing room. not like it really
58.1083 - * matters. */
58.1084 -#define AIM_COOKIETYPE_OFTIM 0x10
58.1085 -#define AIM_COOKIETYPE_OFTGET 0x11
58.1086 -#define AIM_COOKIETYPE_OFTSEND 0x12
58.1087 -#define AIM_COOKIETYPE_OFTVOICE 0x13
58.1088 -#define AIM_COOKIETYPE_OFTIMAGE 0x14
58.1089 -#define AIM_COOKIETYPE_OFTICON 0x15
58.1090 -
58.1091 -aim_userinfo_t *aim_locate_finduserinfo(OscarData *od, const char *sn);
58.1092 -void aim_locate_dorequest(OscarData *od);
58.1093 -
58.1094 -/* 0x0002 */ int aim_locate_reqrights(OscarData *od);
58.1095 -/* 0x0004 */ int aim_locate_setcaps(OscarData *od, guint32 caps);
58.1096 -/* 0x0004 */ int aim_locate_setprofile(OscarData *od, const char *profile_encoding, const gchar *profile, const int profile_len, const char *awaymsg_encoding, const gchar *awaymsg, const int awaymsg_len);
58.1097 -/* 0x0005 */ int aim_locate_getinfo(OscarData *od, const char *, guint16);
58.1098 -/* 0x0009 */ int aim_locate_setdirinfo(OscarData *od, const char *first, const char *middle, const char *last, const char *maiden, const char *nickname, const char *street, const char *city, const char *state, const char *zip, int country, guint16 privacy);
58.1099 -/* 0x000b */ int aim_locate_000b(OscarData *od, const char *sn);
58.1100 -/* 0x000f */ int aim_locate_setinterests(OscarData *od, const char *interest1, const char *interest2, const char *interest3, const char *interest4, const char *interest5, guint16 privacy);
58.1101 -/* 0x0015 */ int aim_locate_getinfoshort(OscarData *od, const char *sn, guint32 flags);
58.1102 -
58.1103 -void aim_locate_autofetch_away_message(OscarData *od, const char *sn);
58.1104 -guint32 aim_locate_getcaps(OscarData *od, ByteStream *bs, int len);
58.1105 -guint32 aim_locate_getcaps_short(OscarData *od, ByteStream *bs, int len);
58.1106 -void aim_info_free(aim_userinfo_t *);
58.1107 -int aim_info_extract(OscarData *od, ByteStream *bs, aim_userinfo_t *);
58.1108 -int aim_putuserinfo(ByteStream *bs, aim_userinfo_t *info);
58.1109 -
58.1110 -
58.1111 -
58.1112 -/* 0x0003 - family_buddy.c */
58.1113 -/* 0x0002 */ void aim_buddylist_reqrights(OscarData *, FlapConnection *);
58.1114 -/* 0x0004 */ int aim_buddylist_set(OscarData *, FlapConnection *, const char *);
58.1115 -/* 0x0004 */ int aim_buddylist_addbuddy(OscarData *, FlapConnection *, const char *);
58.1116 -/* 0x0005 */ int aim_buddylist_removebuddy(OscarData *, FlapConnection *, const char *);
58.1117 -
58.1118 -
58.1119 -
58.1120 -/* 0x000a - family_userlookup.c */
58.1121 -int aim_search_address(OscarData *, const char *);
58.1122 -
58.1123 -
58.1124 -
58.1125 -/* 0x000d - family_chatnav.c */
58.1126 -/* 0x000e - family_chat.c */
58.1127 -/* These apply to exchanges as well. */
58.1128 -#define AIM_CHATROOM_FLAG_EVILABLE 0x0001
58.1129 -#define AIM_CHATROOM_FLAG_NAV_ONLY 0x0002
58.1130 -#define AIM_CHATROOM_FLAG_INSTANCING_ALLOWED 0x0004
58.1131 -#define AIM_CHATROOM_FLAG_OCCUPANT_PEEK_ALLOWED 0x0008
58.1132 -
58.1133 -struct aim_chat_exchangeinfo
58.1134 -{
58.1135 - guint16 number;
58.1136 - guint16 flags;
58.1137 - char *name;
58.1138 - char *charset1;
58.1139 - char *lang1;
58.1140 - char *charset2;
58.1141 - char *lang2;
58.1142 -};
58.1143 -
58.1144 -#define AIM_CHATFLAGS_NOREFLECT 0x0001
58.1145 -#define AIM_CHATFLAGS_AWAY 0x0002
58.1146 -int aim_chat_send_im(OscarData *od, FlapConnection *conn, guint16 flags, const gchar *msg, int msglen, const char *encoding, const char *language);
58.1147 -int aim_chat_join(OscarData *od, guint16 exchange, const char *roomname, guint16 instance);
58.1148 -int aim_chat_attachname(FlapConnection *conn, guint16 exchange, const char *roomname, guint16 instance);
58.1149 -char *aim_chat_getname(FlapConnection *conn);
58.1150 -FlapConnection *aim_chat_getconn(OscarData *, const char *name);
58.1151 -
58.1152 -void aim_chatnav_reqrights(OscarData *od, FlapConnection *conn);
58.1153 -
58.1154 -int aim_chatnav_createroom(OscarData *od, FlapConnection *conn, const char *name, guint16 exchange);
58.1155 -int aim_chat_leaveroom(OscarData *od, const char *name);
58.1156 -
58.1157 -
58.1158 -
58.1159 -/* 0x000f - family_odir.c */
58.1160 -struct aim_odir
58.1161 -{
58.1162 - char *first;
58.1163 - char *last;
58.1164 - char *middle;
58.1165 - char *maiden;
58.1166 - char *email;
58.1167 - char *country;
58.1168 - char *state;
58.1169 - char *city;
58.1170 - char *sn;
58.1171 - char *interest;
58.1172 - char *nick;
58.1173 - char *zip;
58.1174 - char *region;
58.1175 - char *address;
58.1176 - struct aim_odir *next;
58.1177 -};
58.1178 -
58.1179 -int aim_odir_email(OscarData *, const char *, const char *);
58.1180 -int aim_odir_name(OscarData *, const char *, const char *, const char *, const char *, const char *, const char *, const char *, const char *, const char *, const char *, const char *);
58.1181 -int aim_odir_interest(OscarData *, const char *, const char *);
58.1182 -
58.1183 -
58.1184 -
58.1185 -/* 0x0010 - family_bart.c */
58.1186 -int aim_bart_upload(OscarData *od, const guint8 *icon, guint16 iconlen);
58.1187 -int aim_bart_request(OscarData *od, const char *sn, guint8 iconcsumtype, const guint8 *iconstr, guint16 iconstrlen);
58.1188 -
58.1189 -
58.1190 -
58.1191 -/* 0x0013 - family_feedbag.c */
58.1192 -#define AIM_SSI_TYPE_BUDDY 0x0000
58.1193 -#define AIM_SSI_TYPE_GROUP 0x0001
58.1194 -#define AIM_SSI_TYPE_PERMIT 0x0002
58.1195 -#define AIM_SSI_TYPE_DENY 0x0003
58.1196 -#define AIM_SSI_TYPE_PDINFO 0x0004
58.1197 -#define AIM_SSI_TYPE_PRESENCEPREFS 0x0005
58.1198 -#define AIM_SSI_TYPE_ICONINFO 0x0014
58.1199 -
58.1200 -#define AIM_SSI_ACK_SUCCESS 0x0000
58.1201 -#define AIM_SSI_ACK_ITEMNOTFOUND 0x0002
58.1202 -#define AIM_SSI_ACK_IDNUMINUSE 0x000a
58.1203 -#define AIM_SSI_ACK_ATMAX 0x000c
58.1204 -#define AIM_SSI_ACK_INVALIDNAME 0x000d
58.1205 -#define AIM_SSI_ACK_AUTHREQUIRED 0x000e
58.1206 -
58.1207 -/* These flags are set in the 0x00c9 TLV of SSI teyp 0x0005 */
58.1208 -#define AIM_SSI_PRESENCE_FLAG_SHOWIDLE 0x00000400
58.1209 -#define AIM_SSI_PRESENCE_FLAG_NORECENTBUDDIES 0x00020000
58.1210 -
58.1211 -struct aim_ssi_item
58.1212 -{
58.1213 - char *name;
58.1214 - guint16 gid;
58.1215 - guint16 bid;
58.1216 - guint16 type;
58.1217 - GSList *data;
58.1218 - struct aim_ssi_item *next;
58.1219 -};
58.1220 -
58.1221 -struct aim_ssi_tmp
58.1222 -{
58.1223 - guint16 action;
58.1224 - guint16 ack;
58.1225 - char *name;
58.1226 - struct aim_ssi_item *item;
58.1227 - struct aim_ssi_tmp *next;
58.1228 -};
58.1229 -
58.1230 -/* These build the actual SNACs and queue them to be sent */
58.1231 -/* 0x0002 */ int aim_ssi_reqrights(OscarData *od);
58.1232 -/* 0x0004 */ int aim_ssi_reqdata(OscarData *od);
58.1233 -/* 0x0005 */ int aim_ssi_reqifchanged(OscarData *od, time_t localstamp, guint16 localrev);
58.1234 -/* 0x0007 */ int aim_ssi_enable(OscarData *od);
58.1235 -/* 0x0011 */ int aim_ssi_modbegin(OscarData *od);
58.1236 -/* 0x0012 */ int aim_ssi_modend(OscarData *od);
58.1237 -/* 0x0014 */ int aim_ssi_sendauth(OscarData *od, char *sn, char *msg);
58.1238 -/* 0x0018 */ int aim_ssi_sendauthrequest(OscarData *od, char *sn, const char *msg);
58.1239 -/* 0x001a */ int aim_ssi_sendauthreply(OscarData *od, char *sn, guint8 reply, const char *msg);
58.1240 -
58.1241 -/* Client functions for retrieving SSI data */
58.1242 -struct aim_ssi_item *aim_ssi_itemlist_find(struct aim_ssi_item *list, guint16 gid, guint16 bid);
58.1243 -struct aim_ssi_item *aim_ssi_itemlist_finditem(struct aim_ssi_item *list, const char *gn, const char *sn, guint16 type);
58.1244 -struct aim_ssi_item *aim_ssi_itemlist_exists(struct aim_ssi_item *list, const char *sn);
58.1245 -char *aim_ssi_itemlist_findparentname(struct aim_ssi_item *list, const char *sn);
58.1246 -int aim_ssi_getpermdeny(struct aim_ssi_item *list);
58.1247 -guint32 aim_ssi_getpresence(struct aim_ssi_item *list);
58.1248 -char *aim_ssi_getalias(struct aim_ssi_item *list, const char *gn, const char *sn);
58.1249 -char *aim_ssi_getcomment(struct aim_ssi_item *list, const char *gn, const char *sn);
58.1250 -gboolean aim_ssi_waitingforauth(struct aim_ssi_item *list, const char *gn, const char *sn);
58.1251 -
58.1252 -/* Client functions for changing SSI data */
58.1253 -int aim_ssi_addbuddy(OscarData *od, const char *name, const char *group, GSList *tlvlist, const char *alias, const char *comment, const char *smsnum, gboolean needauth);
58.1254 -int aim_ssi_addpermit(OscarData *od, const char *name);
58.1255 -int aim_ssi_adddeny(OscarData *od, const char *name);
58.1256 -int aim_ssi_delbuddy(OscarData *od, const char *name, const char *group);
58.1257 -int aim_ssi_delgroup(OscarData *od, const char *group);
58.1258 -int aim_ssi_delpermit(OscarData *od, const char *name);
58.1259 -int aim_ssi_deldeny(OscarData *od, const char *name);
58.1260 -int aim_ssi_movebuddy(OscarData *od, const char *oldgn, const char *newgn, const char *sn);
58.1261 -int aim_ssi_aliasbuddy(OscarData *od, const char *gn, const char *sn, const char *alias);
58.1262 -int aim_ssi_editcomment(OscarData *od, const char *gn, const char *sn, const char *alias);
58.1263 -int aim_ssi_rename_group(OscarData *od, const char *oldgn, const char *newgn);
58.1264 -int aim_ssi_cleanlist(OscarData *od);
58.1265 -int aim_ssi_deletelist(OscarData *od);
58.1266 -int aim_ssi_setpermdeny(OscarData *od, guint8 permdeny, guint32 vismask);
58.1267 -int aim_ssi_setpresence(OscarData *od, guint32 presence);
58.1268 -int aim_ssi_seticon(OscarData *od, const guint8 *iconsum, guint8 iconsumlen);
58.1269 -int aim_ssi_delicon(OscarData *od);
58.1270 -
58.1271 -
58.1272 -
58.1273 -/* 0x0015 - family_icq.c */
58.1274 -#define AIM_ICQ_INFO_SIMPLE 0x001
58.1275 -#define AIM_ICQ_INFO_SUMMARY 0x002
58.1276 -#define AIM_ICQ_INFO_EMAIL 0x004
58.1277 -#define AIM_ICQ_INFO_PERSONAL 0x008
58.1278 -#define AIM_ICQ_INFO_ADDITIONAL 0x010
58.1279 -#define AIM_ICQ_INFO_WORK 0x020
58.1280 -#define AIM_ICQ_INFO_INTERESTS 0x040
58.1281 -#define AIM_ICQ_INFO_ORGS 0x080
58.1282 -#define AIM_ICQ_INFO_UNKNOWN 0x100
58.1283 -#define AIM_ICQ_INFO_HAVEALL 0x1ff
58.1284 -
58.1285 -#ifdef OLDSTYLE_ICQ_OFFLINEMSGS
58.1286 -struct aim_icq_offlinemsg
58.1287 -{
58.1288 - guint32 sender;
58.1289 - guint16 year;
58.1290 - guint8 month, day, hour, minute;
58.1291 - guint8 type;
58.1292 - guint8 flags;
58.1293 - char *msg;
58.1294 - int msglen;
58.1295 -};
58.1296 -#endif /* OLDSTYLE_ICQ_OFFLINEMSGS */
58.1297 -
58.1298 -struct aim_icq_info
58.1299 -{
58.1300 - guint16 reqid;
58.1301 -
58.1302 - /* simple */
58.1303 - guint32 uin;
58.1304 -
58.1305 - /* general and "home" information (0x00c8) */
58.1306 - char *nick;
58.1307 - char *first;
58.1308 - char *last;
58.1309 - char *email;
58.1310 - char *homecity;
58.1311 - char *homestate;
58.1312 - char *homephone;
58.1313 - char *homefax;
58.1314 - char *homeaddr;
58.1315 - char *mobile;
58.1316 - char *homezip;
58.1317 - guint16 homecountry;
58.1318 -/* guint8 timezone;
58.1319 - guint8 hideemail; */
58.1320 -
58.1321 - /* personal (0x00dc) */
58.1322 - guint8 age;
58.1323 - guint8 unknown;
58.1324 - guint8 gender;
58.1325 - char *personalwebpage;
58.1326 - guint16 birthyear;
58.1327 - guint8 birthmonth;
58.1328 - guint8 birthday;
58.1329 - guint8 language1;
58.1330 - guint8 language2;
58.1331 - guint8 language3;
58.1332 -
58.1333 - /* work (0x00d2) */
58.1334 - char *workcity;
58.1335 - char *workstate;
58.1336 - char *workphone;
58.1337 - char *workfax;
58.1338 - char *workaddr;
58.1339 - char *workzip;
58.1340 - guint16 workcountry;
58.1341 - char *workcompany;
58.1342 - char *workdivision;
58.1343 - char *workposition;
58.1344 - char *workwebpage;
58.1345 -
58.1346 - /* additional personal information (0x00e6) */
58.1347 - char *info;
58.1348 -
58.1349 - /* email (0x00eb) */
58.1350 - guint16 numaddresses;
58.1351 - char **email2;
58.1352 -
58.1353 - /* we keep track of these in a linked list because we're 1337 */
58.1354 - struct aim_icq_info *next;
58.1355 -
58.1356 - /* status note info */
58.1357 - guint8 icbm_cookie[8];
58.1358 - char *status_note_title;
58.1359 -};
58.1360 -
58.1361 -#ifdef OLDSTYLE_ICQ_OFFLINEMSGS
58.1362 -int aim_icq_reqofflinemsgs(OscarData *od);
58.1363 -int aim_icq_ackofflinemsgs(OscarData *od);
58.1364 -#endif
58.1365 -int aim_icq_setsecurity(OscarData *od, gboolean auth_required, gboolean webaware);
58.1366 -int aim_icq_changepasswd(OscarData *od, const char *passwd);
58.1367 -int aim_icq_getsimpleinfo(OscarData *od, const char *uin);
58.1368 -int aim_icq_getalias(OscarData *od, const char *uin);
58.1369 -int aim_icq_getallinfo(OscarData *od, const char *uin);
58.1370 -int aim_icq_sendsms(OscarData *od, const char *name, const char *msg, const char *alias);
58.1371 -
58.1372 -
58.1373 -/* 0x0017 - family_auth.c */
58.1374 -void aim_sendcookie(OscarData *, FlapConnection *, const guint16 length, const guint8 *);
58.1375 -void aim_admin_changepasswd(OscarData *, FlapConnection *, const char *newpw, const char *curpw);
58.1376 -void aim_admin_reqconfirm(OscarData *od, FlapConnection *conn);
58.1377 -void aim_admin_getinfo(OscarData *od, FlapConnection *conn, guint16 info);
58.1378 -void aim_admin_setemail(OscarData *od, FlapConnection *conn, const char *newemail);
58.1379 -void aim_admin_setnick(OscarData *od, FlapConnection *conn, const char *newnick);
58.1380 -
58.1381 -
58.1382 -
58.1383 -/* 0x0018 - family_alert.c */
58.1384 -struct aim_emailinfo
58.1385 -{
58.1386 - guint8 *cookie16;
58.1387 - guint8 *cookie8;
58.1388 - char *url;
58.1389 - guint16 nummsgs;
58.1390 - guint8 unread;
58.1391 - char *domain;
58.1392 - guint16 flag;
58.1393 - struct aim_emailinfo *next;
58.1394 -};
58.1395 -
58.1396 -int aim_email_sendcookies(OscarData *od);
58.1397 -int aim_email_activate(OscarData *od);
58.1398 -
58.1399 -
58.1400 -
58.1401 -/* tlv.c - TLV handling */
58.1402 -
58.1403 -/* TLV structure */
58.1404 -typedef struct aim_tlv_s
58.1405 -{
58.1406 - guint16 type;
58.1407 - guint16 length;
58.1408 - guint8 *value;
58.1409 -} aim_tlv_t;
58.1410 -
58.1411 -/* TLV handling functions */
58.1412 -char *aim_tlv_getvalue_as_string(aim_tlv_t *tlv);
58.1413 -
58.1414 -aim_tlv_t *aim_tlv_gettlv(GSList *list, const guint16 type, const int nth);
58.1415 -int aim_tlv_getlength(GSList *list, const guint16 type, const int nth);
58.1416 -char *aim_tlv_getstr(GSList *list, const guint16 type, const int nth);
58.1417 -guint8 aim_tlv_get8(GSList *list, const guint16 type, const int nth);
58.1418 -guint16 aim_tlv_get16(GSList *list, const guint16 type, const int nth);
58.1419 -guint32 aim_tlv_get32(GSList *list, const guint16 type, const int nth);
58.1420 -
58.1421 -/* TLV list handling functions */
58.1422 -GSList *aim_tlvlist_read(ByteStream *bs);
58.1423 -GSList *aim_tlvlist_readnum(ByteStream *bs, guint16 num);
58.1424 -GSList *aim_tlvlist_readlen(ByteStream *bs, guint16 len);
58.1425 -GSList *aim_tlvlist_copy(GSList *orig);
58.1426 -
58.1427 -int aim_tlvlist_count(GSList *list);
58.1428 -int aim_tlvlist_size(GSList *list);
58.1429 -int aim_tlvlist_cmp(GSList *one, GSList *two);
58.1430 -int aim_tlvlist_write(ByteStream *bs, GSList **list);
58.1431 -void aim_tlvlist_free(GSList *list);
58.1432 -
58.1433 -int aim_tlvlist_add_raw(GSList **list, const guint16 type, const guint16 length, const guint8 *value);
58.1434 -int aim_tlvlist_add_noval(GSList **list, const guint16 type);
58.1435 -int aim_tlvlist_add_8(GSList **list, const guint16 type, const guint8 value);
58.1436 -int aim_tlvlist_add_16(GSList **list, const guint16 type, const guint16 value);
58.1437 -int aim_tlvlist_add_32(GSList **list, const guint16 type, const guint32 value);
58.1438 -int aim_tlvlist_add_str(GSList **list, const guint16 type, const char *value);
58.1439 -int aim_tlvlist_add_caps(GSList **list, const guint16 type, const guint32 caps);
58.1440 -int aim_tlvlist_add_userinfo(GSList **list, guint16 type, aim_userinfo_t *userinfo);
58.1441 -int aim_tlvlist_add_chatroom(GSList **list, guint16 type, guint16 exchange, const char *roomname, guint16 instance);
58.1442 -int aim_tlvlist_add_frozentlvlist(GSList **list, guint16 type, GSList **tl);
58.1443 -
58.1444 -int aim_tlvlist_replace_raw(GSList **list, const guint16 type, const guint16 lenth, const guint8 *value);
58.1445 -int aim_tlvlist_replace_str(GSList **list, const guint16 type, const char *str);
58.1446 -int aim_tlvlist_replace_noval(GSList **list, const guint16 type);
58.1447 -int aim_tlvlist_replace_8(GSList **list, const guint16 type, const guint8 value);
58.1448 -int aim_tlvlist_replace_16(GSList **list, const guint16 type, const guint16 value);
58.1449 -int aim_tlvlist_replace_32(GSList **list, const guint16 type, const guint32 value);
58.1450 -
58.1451 -void aim_tlvlist_remove(GSList **list, const guint16 type);
58.1452 -
58.1453 -
58.1454 -
58.1455 -/* util.c */
58.1456 -/* These are really ugly. You'd think this was LISP. I wish it was. */
58.1457 -#define aimutil_put8(buf, data) ((*(buf) = (guint8)(data)&0xff),1)
58.1458 -#define aimutil_get8(buf) ((*(buf))&0xff)
58.1459 -#define aimutil_put16(buf, data) ( \
58.1460 - (*(buf) = (guint8)((data)>>8)&0xff), \
58.1461 - (*((buf)+1) = (guint8)(data)&0xff), \
58.1462 - 2)
58.1463 -#define aimutil_get16(buf) ((((*(buf))<<8)&0xff00) + ((*((buf)+1)) & 0xff))
58.1464 -#define aimutil_put32(buf, data) ( \
58.1465 - (*((buf)) = (guint8)((data)>>24)&0xff), \
58.1466 - (*((buf)+1) = (guint8)((data)>>16)&0xff), \
58.1467 - (*((buf)+2) = (guint8)((data)>>8)&0xff), \
58.1468 - (*((buf)+3) = (guint8)(data)&0xff), \
58.1469 - 4)
58.1470 -#define aimutil_get32(buf) ((((*(buf))<<24)&0xff000000) + \
58.1471 - (((*((buf)+1))<<16)&0x00ff0000) + \
58.1472 - (((*((buf)+2))<< 8)&0x0000ff00) + \
58.1473 - (((*((buf)+3) )&0x000000ff)))
58.1474 -
58.1475 -/* Little-endian versions (damn ICQ) */
58.1476 -#define aimutil_putle8(buf, data) ( \
58.1477 - (*(buf) = (guint8)(data) & 0xff), \
58.1478 - 1)
58.1479 -#define aimutil_getle8(buf) ( \
58.1480 - (*(buf)) & 0xff \
58.1481 - )
58.1482 -#define aimutil_putle16(buf, data) ( \
58.1483 - (*((buf)+0) = (guint8)((data) >> 0) & 0xff), \
58.1484 - (*((buf)+1) = (guint8)((data) >> 8) & 0xff), \
58.1485 - 2)
58.1486 -#define aimutil_getle16(buf) ( \
58.1487 - (((*((buf)+0)) << 0) & 0x00ff) + \
58.1488 - (((*((buf)+1)) << 8) & 0xff00) \
58.1489 - )
58.1490 -#define aimutil_putle32(buf, data) ( \
58.1491 - (*((buf)+0) = (guint8)((data) >> 0) & 0xff), \
58.1492 - (*((buf)+1) = (guint8)((data) >> 8) & 0xff), \
58.1493 - (*((buf)+2) = (guint8)((data) >> 16) & 0xff), \
58.1494 - (*((buf)+3) = (guint8)((data) >> 24) & 0xff), \
58.1495 - 4)
58.1496 -#define aimutil_getle32(buf) ( \
58.1497 - (((*((buf)+0)) << 0) & 0x000000ff) + \
58.1498 - (((*((buf)+1)) << 8) & 0x0000ff00) + \
58.1499 - (((*((buf)+2)) << 16) & 0x00ff0000) + \
58.1500 - (((*((buf)+3)) << 24) & 0xff000000))
58.1501 -
58.1502 -guint16 aimutil_iconsum(const guint8 *buf, int buflen);
58.1503 -int aimutil_tokslen(char *toSearch, int theindex, char dl);
58.1504 -int aimutil_itemcnt(char *toSearch, char dl);
58.1505 -char *aimutil_itemindex(char *toSearch, int theindex, char dl);
58.1506 -
58.1507 -gboolean aim_snvalid(const char *sn);
58.1508 -gboolean aim_snvalid_icq(const char *sn);
58.1509 -gboolean aim_snvalid_sms(const char *sn);
58.1510 -int aim_snlen(const char *sn);
58.1511 -int aim_sncmp(const char *sn1, const char *sn2);
58.1512 -
58.1513 -
58.1514 -
58.1515 -
58.1516 -typedef struct {
58.1517 - guint16 family;
58.1518 - guint16 subtype;
58.1519 - guint16 flags;
58.1520 - guint32 id;
58.1521 -} aim_modsnac_t;
58.1522 -
58.1523 -#define AIM_MODULENAME_MAXLEN 16
58.1524 -#define AIM_MODFLAG_MULTIFAMILY 0x0001
58.1525 -typedef struct aim_module_s
58.1526 -{
58.1527 - guint16 family;
58.1528 - guint16 version;
58.1529 - guint16 toolid;
58.1530 - guint16 toolversion;
58.1531 - guint16 flags;
58.1532 - char name[AIM_MODULENAME_MAXLEN+1];
58.1533 - int (*snachandler)(OscarData *od, FlapConnection *conn, struct aim_module_s *mod, FlapFrame *rx, aim_modsnac_t *snac, ByteStream *bs);
58.1534 - void (*shutdown)(OscarData *od, struct aim_module_s *mod);
58.1535 - void *priv;
58.1536 - struct aim_module_s *next;
58.1537 -} aim_module_t;
58.1538 -
58.1539 -int aim__registermodule(OscarData *od, int (*modfirst)(OscarData *, aim_module_t *));
58.1540 -void aim__shutdownmodules(OscarData *od);
58.1541 -aim_module_t *aim__findmodulebygroup(OscarData *od, guint16 group);
58.1542 -aim_module_t *aim__findmodule(OscarData *od, const char *name);
58.1543 -
58.1544 -int admin_modfirst(OscarData *od, aim_module_t *mod);
58.1545 -int buddylist_modfirst(OscarData *od, aim_module_t *mod);
58.1546 -int bos_modfirst(OscarData *od, aim_module_t *mod);
58.1547 -int search_modfirst(OscarData *od, aim_module_t *mod);
58.1548 -int stats_modfirst(OscarData *od, aim_module_t *mod);
58.1549 -int auth_modfirst(OscarData *od, aim_module_t *mod);
58.1550 -int msg_modfirst(OscarData *od, aim_module_t *mod);
58.1551 -int misc_modfirst(OscarData *od, aim_module_t *mod);
58.1552 -int chatnav_modfirst(OscarData *od, aim_module_t *mod);
58.1553 -int chat_modfirst(OscarData *od, aim_module_t *mod);
58.1554 -int locate_modfirst(OscarData *od, aim_module_t *mod);
58.1555 -int service_modfirst(OscarData *od, aim_module_t *mod);
58.1556 -int invite_modfirst(OscarData *od, aim_module_t *mod);
58.1557 -int translate_modfirst(OscarData *od, aim_module_t *mod);
58.1558 -int popups_modfirst(OscarData *od, aim_module_t *mod);
58.1559 -int adverts_modfirst(OscarData *od, aim_module_t *mod);
58.1560 -int odir_modfirst(OscarData *od, aim_module_t *mod);
58.1561 -int bart_modfirst(OscarData *od, aim_module_t *mod);
58.1562 -int ssi_modfirst(OscarData *od, aim_module_t *mod);
58.1563 -int icq_modfirst(OscarData *od, aim_module_t *mod);
58.1564 -int email_modfirst(OscarData *od, aim_module_t *mod);
58.1565 -
58.1566 -void aim_genericreq_n(OscarData *od, FlapConnection *conn, guint16 family, guint16 subtype);
58.1567 -void aim_genericreq_n_snacid(OscarData *od, FlapConnection *conn, guint16 family, guint16 subtype);
58.1568 -void aim_genericreq_l(OscarData *od, FlapConnection *conn, guint16 family, guint16 subtype, guint32 *);
58.1569 -void aim_genericreq_s(OscarData *od, FlapConnection *conn, guint16 family, guint16 subtype, guint16 *);
58.1570 -
58.1571 -/* bstream.c */
58.1572 -int byte_stream_new(ByteStream *bs, guint32 len);
58.1573 -int byte_stream_init(ByteStream *bs, guint8 *data, int len);
58.1574 -void byte_stream_destroy(ByteStream *bs);
58.1575 -int byte_stream_empty(ByteStream *bs);
58.1576 -int byte_stream_curpos(ByteStream *bs);
58.1577 -int byte_stream_setpos(ByteStream *bs, unsigned int off);
58.1578 -void byte_stream_rewind(ByteStream *bs);
58.1579 -int byte_stream_advance(ByteStream *bs, int n);
58.1580 -guint8 byte_stream_get8(ByteStream *bs);
58.1581 -guint16 byte_stream_get16(ByteStream *bs);
58.1582 -guint32 byte_stream_get32(ByteStream *bs);
58.1583 -guint8 byte_stream_getle8(ByteStream *bs);
58.1584 -guint16 byte_stream_getle16(ByteStream *bs);
58.1585 -guint32 byte_stream_getle32(ByteStream *bs);
58.1586 -int byte_stream_getrawbuf(ByteStream *bs, guint8 *buf, int len);
58.1587 -guint8 *byte_stream_getraw(ByteStream *bs, int len);
58.1588 -char *byte_stream_getstr(ByteStream *bs, int len);
58.1589 -int byte_stream_put8(ByteStream *bs, guint8 v);
58.1590 -int byte_stream_put16(ByteStream *bs, guint16 v);
58.1591 -int byte_stream_put32(ByteStream *bs, guint32 v);
58.1592 -int byte_stream_putle8(ByteStream *bs, guint8 v);
58.1593 -int byte_stream_putle16(ByteStream *bs, guint16 v);
58.1594 -int byte_stream_putle32(ByteStream *bs, guint32 v);
58.1595 -int byte_stream_putraw(ByteStream *bs, const guint8 *v, int len);
58.1596 -int byte_stream_putstr(ByteStream *bs, const char *str);
58.1597 -int byte_stream_putbs(ByteStream *bs, ByteStream *srcbs, int len);
58.1598 -int byte_stream_putuid(ByteStream *bs, OscarData *od);
58.1599 -int byte_stream_putcaps(ByteStream *bs, guint32 caps);
58.1600 -
58.1601 -/*
58.1602 - * Generic SNAC structure. Rarely if ever used.
58.1603 - */
58.1604 -typedef struct aim_snac_s {
58.1605 - aim_snacid_t id;
58.1606 - guint16 family;
58.1607 - guint16 type;
58.1608 - guint16 flags;
58.1609 - void *data;
58.1610 - time_t issuetime;
58.1611 - struct aim_snac_s *next;
58.1612 -} aim_snac_t;
58.1613 -
58.1614 -/* snac.c */
58.1615 -void aim_initsnachash(OscarData *od);
58.1616 -aim_snacid_t aim_newsnac(OscarData *, aim_snac_t *newsnac);
58.1617 -aim_snacid_t aim_cachesnac(OscarData *od, const guint16 family, const guint16 type, const guint16 flags, const void *data, const int datalen);
58.1618 -aim_snac_t *aim_remsnac(OscarData *, aim_snacid_t id);
58.1619 -void aim_cleansnacs(OscarData *, int maxage);
58.1620 -int aim_putsnac(ByteStream *, guint16 family, guint16 type, guint16 flags, aim_snacid_t id);
58.1621 -
58.1622 -struct chatsnacinfo {
58.1623 - guint16 exchange;
58.1624 - char name[128];
58.1625 - guint16 instance;
58.1626 -};
58.1627 -
58.1628 -struct rateclass {
58.1629 - guint16 classid;
58.1630 - guint32 windowsize;
58.1631 - guint32 clear;
58.1632 - guint32 alert;
58.1633 - guint32 limit;
58.1634 - guint32 disconnect;
58.1635 - guint32 current;
58.1636 - guint32 max;
58.1637 - guint8 unknown[5]; /* only present in versions >= 3 */
58.1638 - GHashTable *members; /* Key is family and subtype, value is TRUE. */
58.1639 -
58.1640 - struct timeval last; /**< The time when we last sent a SNAC of this rate class. */
58.1641 -};
58.1642 -
58.1643 -int aim_cachecookie(OscarData *od, IcbmCookie *cookie);
58.1644 -IcbmCookie *aim_uncachecookie(OscarData *od, guint8 *cookie, int type);
58.1645 -IcbmCookie *aim_mkcookie(guint8 *, int, void *);
58.1646 -IcbmCookie *aim_checkcookie(OscarData *, const unsigned char *, const int);
58.1647 -int aim_freecookie(OscarData *od, IcbmCookie *cookie);
58.1648 -int aim_msgcookie_gettype(int type);
58.1649 -int aim_cookie_free(OscarData *od, IcbmCookie *cookie);
58.1650 -
58.1651 -int aim_chat_readroominfo(ByteStream *bs, struct aim_chat_roominfo *outinfo);
58.1652 -
58.1653 -void flap_connection_destroy_chat(OscarData *od, FlapConnection *conn);
58.1654 -
58.1655 -#ifdef __cplusplus
58.1656 -}
58.1657 -#endif
58.1658 -
58.1659 -#endif /* _OSCAR_H_ */
59.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/page.h Sun Jun 21 22:04:11 2009 -0400
59.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
59.3 @@ -1,81 +0,0 @@
59.4 -/**
59.5 - * @file page.h Paging functions
59.6 - *
59.7 - * purple
59.8 - *
59.9 - * Purple is the legal property of its developers, whose names are too numerous
59.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
59.11 - * source distribution.
59.12 - *
59.13 - * This program is free software; you can redistribute it and/or modify
59.14 - * it under the terms of the GNU General Public License as published by
59.15 - * the Free Software Foundation; either version 2 of the License, or
59.16 - * (at your option) any later version.
59.17 - *
59.18 - * This program is distributed in the hope that it will be useful,
59.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
59.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
59.21 - * GNU General Public License for more details.
59.22 - *
59.23 - * You should have received a copy of the GNU General Public License
59.24 - * along with this program; if not, write to the Free Software
59.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
59.26 - */
59.27 -#ifndef _MSN_PAGE_H_
59.28 -#define _MSN_PAGE_H_
59.29 -
59.30 -typedef struct _MsnPage MsnPage;
59.31 -
59.32 -#include "session.h"
59.33 -
59.34 -/**
59.35 - * A page.
59.36 - */
59.37 -struct _MsnPage
59.38 -{
59.39 - char *from_location;
59.40 - char *from_phone;
59.41 -
59.42 - char *body;
59.43 -};
59.44 -
59.45 -/**
59.46 - * Creates a new, empty page.
59.47 - *
59.48 - * @return A new page.
59.49 - */
59.50 -MsnPage *msn_page_new(void);
59.51 -
59.52 -/**
59.53 - * Destroys a page.
59.54 - */
59.55 -void msn_page_destroy(MsnPage *page);
59.56 -
59.57 -/**
59.58 - * Generates the payload data of a page.
59.59 - *
59.60 - * @param page The page.
59.61 - * @param ret_size The returned size of the payload.
59.62 - *
59.63 - * @return The payload data of a page.
59.64 - */
59.65 -char *msn_page_gen_payload(const MsnPage *page, size_t *ret_size);
59.66 -
59.67 -/**
59.68 - * Sets the body of a page.
59.69 - *
59.70 - * @param page The page.
59.71 - * @param body The body of the page.
59.72 - */
59.73 -void msn_page_set_body(MsnPage *page, const char *body);
59.74 -
59.75 -/**
59.76 - * Returns the body of the page.
59.77 - *
59.78 - * @param page The page.
59.79 - *
59.80 - * @return The body of the page.
59.81 - */
59.82 -const char *msn_page_get_body(const MsnPage *page);
59.83 -
59.84 -#endif /* _MSN_PAGE_H_ */
60.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/pecan_config.h Sun Jun 21 22:04:11 2009 -0400
60.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
60.3 @@ -1,27 +0,0 @@
60.4 -/**
60.5 - * Copyright (C) 2008 Felipe Contreras
60.6 - *
60.7 - * This program is free software; you can redistribute it and/or modify
60.8 - * it under the terms of the GNU General Public License as published by
60.9 - * the Free Software Foundation; either version 2 of the License, or
60.10 - * (at your option) any later version.
60.11 - *
60.12 - * This program is distributed in the hope that it will be useful,
60.13 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
60.14 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
60.15 - * GNU General Public License for more details.
60.16 - *
60.17 - * You should have received a copy of the GNU General Public License
60.18 - * along with this program; if not, write to the Free Software
60.19 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
60.20 - */
60.21 -
60.22 -#ifndef PECAN_CONFIG_H
60.23 -#define PECAN_CONFIG_H
60.24 -
60.25 -#define PACKAGE_NAME "msn-pecan"
60.26 -
60.27 -#define MSN_BUF_LEN 8192
60.28 -#define PECAN_MAX_MESSAGE_LENGTH 1564
60.29 -
60.30 -#endif /* PECAN_CONFIG_H */
61.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/pecan_log.h Sun Jun 21 22:04:11 2009 -0400
61.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
61.3 @@ -1,79 +0,0 @@
61.4 -/**
61.5 - * Copyright (C) 2007-2008 Felipe Contreras
61.6 - *
61.7 - * This program is free software; you can redistribute it and/or modify
61.8 - * it under the terms of the GNU General Public License as published by
61.9 - * the Free Software Foundation; either version 2 of the License, or
61.10 - * (at your option) any later version.
61.11 - *
61.12 - * This program is distributed in the hope that it will be useful,
61.13 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
61.14 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
61.15 - * GNU General Public License for more details.
61.16 - *
61.17 - * You should have received a copy of the GNU General Public License
61.18 - * along with this program; if not, write to the Free Software
61.19 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
61.20 - */
61.21 -
61.22 -#ifndef PECAN_LOG_H
61.23 -#define PECAN_LOG_H
61.24 -
61.25 -#include <glib.h>
61.26 -#include "msn.h"
61.27 -
61.28 -#define PECAN_DEBUG
61.29 -
61.30 -#if defined(PECAN_DEBUG)
61.31 -
61.32 -/* #define PECAN_DEBUG_MSG */
61.33 -/* #define PECAN_DEBUG_SLPMSG */
61.34 -/* #define PECAN_DEBUG_HTTP */
61.35 -
61.36 -/* #define PECAN_DEBUG_SLP_VERBOSE */
61.37 -/* #define PECAN_DEBUG_SLP_FILES */
61.38 -
61.39 -/* #define PECAN_DEBUG_NS */
61.40 -/* #define PECAN_DEBUG_SB */
61.41 -/* #define PECAN_DEBUG_DC */
61.42 -
61.43 -/* #define PECAN_DEBUG_DC_FILES */
61.44 -
61.45 -enum PecanLogLevel
61.46 -{
61.47 - PECAN_LOG_LEVEL_NONE,
61.48 - PECAN_LOG_LEVEL_ERROR,
61.49 - PECAN_LOG_LEVEL_WARNING,
61.50 - PECAN_LOG_LEVEL_INFO,
61.51 - PECAN_LOG_LEVEL_DEBUG,
61.52 - PECAN_LOG_LEVEL_LOG
61.53 -};
61.54 -
61.55 -typedef enum PecanLogLevel PecanLogLevel;
61.56 -
61.57 -void msn_base_log_helper (PecanLogLevel level, const gchar *file, const gchar *function, gint line, const gchar *fmt, ...);
61.58 -void msn_dump_file (const gchar *buffer, gsize len);
61.59 -
61.60 -#define pecan_print(...) g_print (__VA_ARGS__);
61.61 -
61.62 -#define msn_base_log(level, ...) msn_base_log_helper (level, __FILE__, __func__, __LINE__, __VA_ARGS__);
61.63 -
61.64 -#define pecan_error(...) msn_base_log (PECAN_LOG_LEVEL_ERROR, __VA_ARGS__);
61.65 -#define pecan_warning(...) msn_base_log (PECAN_LOG_LEVEL_WARNING, __VA_ARGS__);
61.66 -#define pecan_info(...) msn_base_log (PECAN_LOG_LEVEL_INFO, __VA_ARGS__);
61.67 -#define pecan_debug(...) msn_base_log (PECAN_LOG_LEVEL_DEBUG, __VA_ARGS__);
61.68 -#define pecan_log(...) msn_base_log (PECAN_LOG_LEVEL_LOG, __VA_ARGS__);
61.69 -
61.70 -#elif !defined(PECAN_DEBUG)
61.71 -
61.72 -#define pecan_print(...) {}
61.73 -#define pecan_error(...) {}
61.74 -#define pecan_warning(...) {}
61.75 -#define pecan_info(...) {}
61.76 -#define pecan_debug(...) {}
61.77 -#define pecan_log(...) {}
61.78 -#define msn_dump_file(...) {}
61.79 -
61.80 -#endif /* !defined(PECAN_DEBUG) */
61.81 -
61.82 -#endif /* PECAN_LOG_H */
62.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/pecan_oim.h Sun Jun 21 22:04:11 2009 -0400
62.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
62.3 @@ -1,34 +0,0 @@
62.4 -/**
62.5 - * Copyright (C) 2008 Felipe Contreras
62.6 - *
62.7 - * This program is free software; you can redistribute it and/or modify
62.8 - * it under the terms of the GNU General Public License as published by
62.9 - * the Free Software Foundation; either version 2 of the License, or
62.10 - * (at your option) any later version.
62.11 - *
62.12 - * This program is distributed in the hope that it will be useful,
62.13 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
62.14 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
62.15 - * GNU General Public License for more details.
62.16 - *
62.17 - * You should have received a copy of the GNU General Public License
62.18 - * along with this program; if not, write to the Free Software
62.19 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
62.20 - */
62.21 -
62.22 -#ifndef PECAN_OIM_H
62.23 -#define PECAN_OIM_H
62.24 -
62.25 -typedef struct PecanOimSession PecanOimSession;
62.26 -
62.27 -#include "session.h"
62.28 -
62.29 -struct MsnSession;
62.30 -
62.31 -PecanOimSession *pecan_oim_session_new (MsnSession *session);
62.32 -void pecan_oim_session_free (PecanOimSession *oim_session);
62.33 -void pecan_oim_session_request (PecanOimSession *oim_session,
62.34 - const gchar *passport,
62.35 - const gchar *message_id);
62.36 -
62.37 -#endif /* PECAN_OIM_H */
63.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/pecan_oim_private.h Sun Jun 21 22:04:11 2009 -0400
63.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
63.3 @@ -1,32 +0,0 @@
63.4 -/**
63.5 - * Copyright (C) 2008 Felipe Contreras
63.6 - *
63.7 - * This program is free software; you can redistribute it and/or modify
63.8 - * it under the terms of the GNU General Public License as published by
63.9 - * the Free Software Foundation; either version 2 of the License, or
63.10 - * (at your option) any later version.
63.11 - *
63.12 - * This program is distributed in the hope that it will be useful,
63.13 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
63.14 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
63.15 - * GNU General Public License for more details.
63.16 - *
63.17 - * You should have received a copy of the GNU General Public License
63.18 - * along with this program; if not, write to the Free Software
63.19 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
63.20 - */
63.21 -
63.22 -#ifndef PECAN_OIM_PRIVATE_H
63.23 -#define PECAN_OIM_PRIVATE_H
63.24 -
63.25 -#include "pecan_oim.h"
63.26 -
63.27 -#include <glib.h>
63.28 -
63.29 -struct PecanOimSession
63.30 -{
63.31 - MsnSession *session;
63.32 - GQueue *request_queue;
63.33 -};
63.34 -
63.35 -#endif /* PECAN_OIM_PRIVATE_H */
64.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/pecan_printf.h Sun Jun 21 22:04:11 2009 -0400
64.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
64.3 @@ -1,34 +0,0 @@
64.4 -/**
64.5 - * Copyright (C) 2007-2008 Felipe Contreras
64.6 - *
64.7 - * This program is free software; you can redistribute it and/or modify
64.8 - * it under the terms of the GNU General Public License as published by
64.9 - * the Free Software Foundation; either version 2 of the License, or
64.10 - * (at your option) any later version.
64.11 - *
64.12 - * This program is distributed in the hope that it will be useful,
64.13 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
64.14 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
64.15 - * GNU General Public License for more details.
64.16 - *
64.17 - * You should have received a copy of the GNU General Public License
64.18 - * along with this program; if not, write to the Free Software
64.19 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
64.20 - */
64.21 -
64.22 -#ifndef PECAN_PRINTF_H
64.23 -#define PECAN_PRINTF_H
64.24 -
64.25 -#include <glib.h>
64.26 -
64.27 -#define PECAN_CUSTOM_PRINTF
64.28 -
64.29 -#ifdef PECAN_CUSTOM_PRINTF
64.30 -gchar *pecan_strdup_vprintf (const gchar *format, va_list args);
64.31 -gchar *pecan_strdup_printf (const gchar *format, ...);
64.32 -#else
64.33 -#define pecan_strdup_vprintf g_strdup_vprintf
64.34 -#define pecan_strdup_printf g_strdup_printf
64.35 -#endif /* PECAN_CUSTOM_PRINTF */
64.36 -
64.37 -#endif /* PECAN_PRINTF_H */
65.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/pecan_status.h Sun Jun 21 22:04:11 2009 -0400
65.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
65.3 @@ -1,60 +0,0 @@
65.4 -/**
65.5 - * Copyright (C) 2007-2008 Felipe Contreras
65.6 - *
65.7 - * Purple is the legal property of its developers, whose names are too numerous
65.8 - * to list here. Please refer to the COPYRIGHT file distributed with this
65.9 - * source distribution.
65.10 - *
65.11 - * This program is free software; you can redistribute it and/or modify
65.12 - * it under the terms of the GNU General Public License as published by
65.13 - * the Free Software Foundation; either version 2 of the License, or
65.14 - * (at your option) any later version.
65.15 - *
65.16 - * This program is distributed in the hope that it will be useful,
65.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
65.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
65.19 - * GNU General Public License for more details.
65.20 - *
65.21 - * You should have received a copy of the GNU General Public License
65.22 - * along with this program; if not, write to the Free Software
65.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
65.24 - */
65.25 -
65.26 -#ifndef PECAN_STATUS_H
65.27 -#define PECAN_STATUS_H
65.28 -
65.29 -/**
65.30 - * Status types.
65.31 - */
65.32 -typedef enum
65.33 -{
65.34 - PECAN_STATUS_NONE,
65.35 - PECAN_STATUS_ONLINE,
65.36 - PECAN_STATUS_BUSY,
65.37 - PECAN_STATUS_IDLE,
65.38 - PECAN_STATUS_BRB,
65.39 - PECAN_STATUS_AWAY,
65.40 - PECAN_STATUS_PHONE,
65.41 - PECAN_STATUS_LUNCH,
65.42 - PECAN_STATUS_OFFLINE,
65.43 - PECAN_STATUS_HIDDEN
65.44 -
65.45 -} PecanStatusType;
65.46 -
65.47 -struct MsnSession;
65.48 -
65.49 -/**
65.50 - * Updates the status of the user.
65.51 - *
65.52 - * @param session The MSN session.
65.53 - */
65.54 -void pecan_update_status (struct MsnSession *session);
65.55 -
65.56 -/**
65.57 - * Updates the personal message of the user.
65.58 - *
65.59 - * @param session The MSN session.
65.60 - */
65.61 -void pecan_update_personal_message (struct MsnSession *session);
65.62 -
65.63 -#endif /* PECAN_STATUS_H */
66.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/pecan_util.h Sun Jun 21 22:04:11 2009 -0400
66.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
66.3 @@ -1,70 +0,0 @@
66.4 -/**
66.5 - * Copyright (C) 2007-2008 Felipe Contreras
66.6 - *
66.7 - * Purple is the legal property of its developers, whose names are too numerous
66.8 - * to list here. Please refer to the COPYRIGHT file distributed with this
66.9 - * source distribution.
66.10 - *
66.11 - * This program is free software; you can redistribute it and/or modify
66.12 - * it under the terms of the GNU General Public License as published by
66.13 - * the Free Software Foundation; either version 2 of the License, or
66.14 - * (at your option) any later version.
66.15 - *
66.16 - * This program is distributed in the hope that it will be useful,
66.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
66.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
66.19 - * GNU General Public License for more details.
66.20 - *
66.21 - * You should have received a copy of the GNU General Public License
66.22 - * along with this program; if not, write to the Free Software
66.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
66.24 - */
66.25 -
66.26 -#ifndef PECAN_UTIL_H
66.27 -#define PECAN_UTIL_H
66.28 -
66.29 -#include <glib.h>
66.30 -
66.31 -gchar *pecan_url_decode (const gchar *url);
66.32 -
66.33 -/**
66.34 - * Parses the MSN message formatting into a format compatible with Purple.
66.35 - *
66.36 - * @param mime The mime header with the formatting.
66.37 - * @param pre_ret The returned prefix string.
66.38 - * @param post_ret The returned postfix string.
66.39 - *
66.40 - * @return The new message.
66.41 - */
66.42 -void msn_parse_format(const char *mime, char **pre_ret, char **post_ret);
66.43 -
66.44 -/**
66.45 - * Parses the Purple message formatting (html) into the MSN format.
66.46 - *
66.47 - * @param html The html message to format.
66.48 - * @param attributes The returned attributes string.
66.49 - * @param message The returned message string.
66.50 - *
66.51 - * @return The new message.
66.52 - */
66.53 -void msn_import_html(const char *html, char **attributes, char **message);
66.54 -
66.55 -void
66.56 -pecan_handle_challenge (const gchar *input,
66.57 - const gchar *product_id,
66.58 - gchar *output);
66.59 -
66.60 -void msn_parse_socket(const char *str, char **ret_host, int *ret_port);
66.61 -char *msn_rand_guid(void);
66.62 -gchar *pecan_normalize (const gchar *str);
66.63 -
66.64 -#if !GLIB_CHECK_VERSION(2,12,0)
66.65 -void g_hash_table_remove_all (GHashTable *hash_table);
66.66 -#endif /* !GLIB_CHECK_VERSION(2,12,0) */
66.67 -gpointer g_hash_table_peek_first (GHashTable *hash_table);
66.68 -gboolean g_ascii_strcase_equal (gconstpointer v1, gconstpointer v2);
66.69 -guint g_ascii_strcase_hash (gconstpointer v);
66.70 -
66.71 -gchar *pecan_get_xml_field (const gchar *tag, const gchar *start, const gchar *end);
66.72 -
66.73 -#endif /* PECAN_UTIL_H */
67.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/peer.h Sun Jun 21 22:04:11 2009 -0400
67.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
67.3 @@ -1,281 +0,0 @@
67.4 -/*
67.5 - * Purple's oscar protocol plugin
67.6 - * This file is the legal property of its developers.
67.7 - * Please see the AUTHORS file distributed alongside this file.
67.8 - *
67.9 - * This library is free software; you can redistribute it and/or
67.10 - * modify it under the terms of the GNU Lesser General Public
67.11 - * License as published by the Free Software Foundation; either
67.12 - * version 2 of the License, or (at your option) any later version.
67.13 - *
67.14 - * This library is distributed in the hope that it will be useful,
67.15 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
67.16 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
67.17 - * Lesser General Public License for more details.
67.18 - *
67.19 - * You should have received a copy of the GNU Lesser General Public
67.20 - * License along with this library; if not, write to the Free Software
67.21 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
67.22 -*/
67.23 -
67.24 -/*
67.25 - * OFT and ODC Services
67.26 - */
67.27 -
67.28 -#ifndef _PEER_H_
67.29 -#define _PEER_H_
67.30 -
67.31 -#include "ft.h"
67.32 -#include "network.h"
67.33 -#include "proxy.h"
67.34 -
67.35 -typedef struct _ChecksumData ChecksumData;
67.36 -typedef struct _OdcFrame OdcFrame;
67.37 -typedef struct _OftFrame OftFrame;
67.38 -typedef struct _ProxyFrame ProxyFrame;
67.39 -typedef struct _PeerConnection PeerConnection;
67.40 -
67.41 -#define PEER_CONNECTION_FLAG_INITIATED_BY_ME 0x0001
67.42 -#define PEER_CONNECTION_FLAG_APPROVED 0x0002
67.43 -#define PEER_CONNECTION_FLAG_TRIED_DIRECT 0x0004
67.44 -#define PEER_CONNECTION_FLAG_TRIED_INCOMING 0x0008
67.45 -#define PEER_CONNECTION_FLAG_TRIED_PROXY 0x0010
67.46 -#define PEER_CONNECTION_FLAG_IS_INCOMING 0x0020
67.47 -
67.48 -#define PEER_TYPE_PROMPT 0x0101 /* "I am going to send you this file, is that ok?" */
67.49 -#define PEER_TYPE_RESUMEACCEPT 0x0106 /* We are accepting the resume */
67.50 -#define PEER_TYPE_ACK 0x0202 /* "Yes, it is ok for you to send me that file" */
67.51 -#define PEER_TYPE_DONE 0x0204 /* "I received that file with no problems, thanks a bunch" */
67.52 -#define PEER_TYPE_RESUME 0x0205 /* Resume transferring, sent by whoever receives */
67.53 -#define PEER_TYPE_RESUMEACK 0x0207 /* Our resume accept was ACKed */
67.54 -
67.55 -#define PEER_TYPE_GETFILE_REQUESTLISTING 0x1108 /* "I have a listing.txt file, do you want it?" */
67.56 -#define PEER_TYPE_GETFILE_RECEIVELISTING 0x1209 /* "Yes, please send me your listing.txt file" */
67.57 -#define PEER_TYPE_GETFILE_RECEIVEDLISTING 0x120a /* received corrupt listing.txt file? I'm just guessing about this one... */
67.58 -#define PEER_TYPE_GETFILE_ACKLISTING 0x120b /* "I received the listing.txt file successfully" */
67.59 -#define PEER_TYPE_GETFILE_REQUESTFILE 0x120c /* "Please send me this file" */
67.60 -
67.61 -/*
67.62 - * For peer proxying
67.63 - */
67.64 -#define PEER_PROXY_SERVER "ars.oscar.aol.com"
67.65 -#define PEER_PROXY_PORT 5190 /* The port we should always connect to */
67.66 -#define PEER_PROXY_PACKET_VERSION 0x044a
67.67 -
67.68 -/* Thanks to Keith Lea and the Joust project for documenting these */
67.69 -#define PEER_PROXY_TYPE_ERROR 0x0001
67.70 -#define PEER_PROXY_TYPE_CREATE 0x0002
67.71 -#define PEER_PROXY_TYPE_CREATED 0x0003
67.72 -#define PEER_PROXY_TYPE_JOIN 0x0004
67.73 -#define PEER_PROXY_TYPE_READY 0x0005
67.74 -
67.75 -struct _OdcFrame
67.76 -{
67.77 - /* guchar magic[4]; */ /* 0 */
67.78 - /* guint16 length; */ /* 4 */
67.79 - guint16 type; /* 6 */
67.80 - guint16 subtype; /* 8 */
67.81 - /* Unknown */ /* 10 */
67.82 - guchar cookie[8]; /* 12 */
67.83 - /* Unknown */
67.84 - /* guint32 payloadlength; */ /* 28 */
67.85 - guint16 encoding; /* 32 */
67.86 - /* Unknown */
67.87 - guint16 flags; /* 38 */
67.88 - /* Unknown */
67.89 - guchar sn[32]; /* 44 */
67.90 - /* Unknown */
67.91 - ByteStream payload; /* 76 */
67.92 -};
67.93 -
67.94 -struct _OftFrame
67.95 -{
67.96 - /* guchar magic[4]; */ /* 0 */
67.97 - /* guint16 length; */ /* 4 */
67.98 - guint16 type; /* 6 */
67.99 - guchar cookie[8]; /* 8 */
67.100 - guint16 encrypt; /* 16 */
67.101 - guint16 compress; /* 18 */
67.102 - guint16 totfiles; /* 20 */
67.103 - guint16 filesleft; /* 22 */
67.104 - guint16 totparts; /* 24 */
67.105 - guint16 partsleft; /* 26 */
67.106 - guint32 totsize; /* 28 */
67.107 - guint32 size; /* 32 */
67.108 - guint32 modtime; /* 36 */
67.109 - guint32 checksum; /* 40 */
67.110 - guint32 rfrcsum; /* 44 */
67.111 - guint32 rfsize; /* 48 */
67.112 - guint32 cretime; /* 52 */
67.113 - guint32 rfcsum; /* 56 */
67.114 - guint32 nrecvd; /* 60 */
67.115 - guint32 recvcsum; /* 64 */
67.116 - guchar idstring[32]; /* 68 */
67.117 - guint8 flags; /* 100 */
67.118 - guint8 lnameoffset; /* 101 */
67.119 - guint8 lsizeoffset; /* 102 */
67.120 - guchar dummy[69]; /* 103 */
67.121 - guchar macfileinfo[16]; /* 172 */
67.122 - guint16 nencode; /* 188 */
67.123 - guint16 nlanguage; /* 190 */
67.124 - guchar *name; /* 192 */
67.125 - size_t name_length;
67.126 - /* Payload? */ /* 256 */
67.127 -};
67.128 -
67.129 -struct _ProxyFrame
67.130 -{
67.131 - /* guint16 length; */ /* 0 */
67.132 - guint16 version; /* 2 */
67.133 - guint16 type; /* 4 */
67.134 - guint32 unknown; /* 6 */
67.135 - guint16 flags; /* 10 */
67.136 - ByteStream payload; /* 12 */
67.137 -};
67.138 -
67.139 -struct _PeerConnection
67.140 -{
67.141 - OscarData *od;
67.142 - OscarCapability type;
67.143 - char *sn;
67.144 - guchar magic[4];
67.145 - guchar cookie[8];
67.146 - guint16 lastrequestnumber;
67.147 -
67.148 - gboolean ready;
67.149 - int flags; /**< Bitmask of PEER_CONNECTION_FLAG_ */
67.150 - time_t lastactivity; /**< Time of last transmit. */
67.151 - guint destroy_timeout;
67.152 - OscarDisconnectReason disconnect_reason;
67.153 - char *error_message;
67.154 -
67.155 - /**
67.156 - * A pointer to either an OdcFrame or an OftFrame.
67.157 - */
67.158 - gpointer frame;
67.159 -
67.160 - /**
67.161 - * This is only used when the peer connection is being established.
67.162 - */
67.163 - PurpleProxyConnectData *client_connect_data;
67.164 - PurpleProxyConnectData *verified_connect_data;
67.165 -
67.166 - /**
67.167 - * This is only used when the peer connection is being established.
67.168 - */
67.169 - PurpleNetworkListenData *listen_data;
67.170 -
67.171 -
67.172 - /**
67.173 - * This is only used when the peer connection is being established.
67.174 - */
67.175 - guint connect_timeout_timer;
67.176 -
67.177 - /**
67.178 - * This is only used while the remote user is attempting to
67.179 - * connect to us.
67.180 - */
67.181 - int listenerfd;
67.182 -
67.183 - int fd;
67.184 - guint8 header[6];
67.185 - gssize header_received;
67.186 - guint8 proxy_header[12];
67.187 - gssize proxy_header_received;
67.188 - ByteStream buffer_incoming;
67.189 - PurpleCircBuffer *buffer_outgoing;
67.190 - guint watcher_incoming;
67.191 - guint watcher_outgoing;
67.192 -
67.193 - /**
67.194 - * IP address of the proxy server, if applicable.
67.195 - */
67.196 - gchar *proxyip;
67.197 -
67.198 - /**
67.199 - * IP address of the remote user from THEIR point of view.
67.200 - */
67.201 - gchar *clientip;
67.202 -
67.203 - /**
67.204 - * IP address of the remote user from the oscar server's
67.205 - * point of view.
67.206 - */
67.207 - gchar *verifiedip;
67.208 -
67.209 - guint16 port;
67.210 - gboolean use_proxy;
67.211 -
67.212 - /**
67.213 - * Checksumming
67.214 - */
67.215 - ChecksumData *checksum_data;
67.216 -
67.217 - /* TODOFT */
67.218 - PurpleXfer *xfer;
67.219 - OftFrame xferdata;
67.220 - guint sending_data_timer;
67.221 -};
67.222 -
67.223 -/*
67.224 - * For all peer connections
67.225 - */
67.226 -
67.227 -/**
67.228 - * Create a new PeerConnection structure and initialize it with some
67.229 - * sane defaults.
67.230 - *
67.231 - * @param type The type of the peer connection. One of
67.232 - * OSCAR_CAPABILITY_DIRECTIM or OSCAR_CAPABILITY_SENDFILE.
67.233 - */
67.234 -PeerConnection *peer_connection_new(OscarData *od, OscarCapability type, const char *sn);
67.235 -
67.236 -void peer_connection_destroy(PeerConnection *conn, OscarDisconnectReason reason, const gchar *error_message);
67.237 -void peer_connection_schedule_destroy(PeerConnection *conn, OscarDisconnectReason reason, const gchar *error_message);
67.238 -PeerConnection *peer_connection_find_by_type(OscarData *od, const char *sn, OscarCapability type);
67.239 -PeerConnection *peer_connection_find_by_cookie(OscarData *od, const char *sn, const guchar *cookie);
67.240 -
67.241 -void peer_connection_listen_cb(gpointer data, gint source, PurpleInputCondition cond);
67.242 -void peer_connection_recv_cb(gpointer data, gint source, PurpleInputCondition cond);
67.243 -void peer_connection_send(PeerConnection *conn, ByteStream *bs);
67.244 -
67.245 -void peer_connection_trynext(PeerConnection *conn);
67.246 -void peer_connection_finalize_connection(PeerConnection *conn);
67.247 -void peer_connection_propose(OscarData *od, OscarCapability type, const char *sn);
67.248 -void peer_connection_got_proposition(OscarData *od, const gchar *sn, const gchar *message, IcbmArgsCh2 *args);
67.249 -
67.250 -/*
67.251 - * For ODC
67.252 - */
67.253 -void peer_odc_close(PeerConnection *conn);
67.254 -void peer_odc_recv_frame(PeerConnection *conn, ByteStream *bs);
67.255 -void peer_odc_send_cookie(PeerConnection *conn);
67.256 -void peer_odc_send_typing(PeerConnection *conn, PurpleTypingState typing);
67.257 -void peer_odc_send_im(PeerConnection *conn, const char *msg, int len, int encoding, gboolean autoreply);
67.258 -
67.259 -/*
67.260 - * For OFT
67.261 - */
67.262 -void peer_oft_close(PeerConnection *conn);
67.263 -void peer_oft_recv_frame(PeerConnection *conn, ByteStream *bs);
67.264 -void peer_oft_send_prompt(PeerConnection *conn);
67.265 -void peer_oft_checksum_destroy(ChecksumData *checksum_data);
67.266 -
67.267 -/* Xfer callbacks for receiving a file */
67.268 -void peer_oft_recvcb_init(PurpleXfer *xfer);
67.269 -void peer_oft_recvcb_end(PurpleXfer *xfer);
67.270 -void peer_oft_recvcb_ack_recv(PurpleXfer *xfer, const guchar *buffer, size_t size);
67.271 -
67.272 -/* Xfer callbacks for sending a file */
67.273 -void peer_oft_sendcb_init(PurpleXfer *xfer);
67.274 -void peer_oft_sendcb_ack(PurpleXfer *xfer, const guchar *buffer, size_t size);
67.275 -
67.276 -/* Xfer callbacks for both sending and receiving */
67.277 -void peer_oft_cb_generic_cancel(PurpleXfer *xfer);
67.278 -
67.279 -/*
67.280 - * For peer proxying
67.281 - */
67.282 -void peer_proxy_connection_established_cb(gpointer data, gint source, const gchar *error_message);
67.283 -
67.284 -#endif /* _PEER_H_ */
68.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/plugin.h Sun Jun 21 22:04:11 2009 -0400
68.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
68.3 @@ -1,712 +0,0 @@
68.4 -/**
68.5 - * @file plugin.h Plugin API
68.6 - * @ingroup core
68.7 - * @see @ref plugin-signals
68.8 - * @see @ref plugin-ids
68.9 - * @see @ref plugin-i18n
68.10 - */
68.11 -
68.12 -/* purple
68.13 - *
68.14 - * Purple is the legal property of its developers, whose names are too numerous
68.15 - * to list here. Please refer to the COPYRIGHT file distributed with this
68.16 - * source distribution.
68.17 - *
68.18 - * This program is free software; you can redistribute it and/or modify
68.19 - * it under the terms of the GNU General Public License as published by
68.20 - * the Free Software Foundation; either version 2 of the License, or
68.21 - * (at your option) any later version.
68.22 - *
68.23 - * This program is distributed in the hope that it will be useful,
68.24 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
68.25 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
68.26 - * GNU General Public License for more details.
68.27 - *
68.28 - * You should have received a copy of the GNU General Public License
68.29 - * along with this program; if not, write to the Free Software
68.30 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
68.31 - */
68.32 -#ifndef _PURPLE_PLUGIN_H_
68.33 -#define _PURPLE_PLUGIN_H_
68.34 -
68.35 -#include <glib/glist.h>
68.36 -#include <gmodule.h>
68.37 -#include "signals.h"
68.38 -#include "value.h"
68.39 -
68.40 -/** @copydoc _PurplePlugin */
68.41 -typedef struct _PurplePlugin PurplePlugin;
68.42 -/** @copydoc _PurplePluginInfo */
68.43 -typedef struct _PurplePluginInfo PurplePluginInfo;
68.44 -/** @copydoc _PurplePluginUiInfo */
68.45 -typedef struct _PurplePluginUiInfo PurplePluginUiInfo;
68.46 -/** @copydoc _PurplePluginLoaderInfo */
68.47 -typedef struct _PurplePluginLoaderInfo PurplePluginLoaderInfo;
68.48 -
68.49 -/** @copydoc _PurplePluginAction */
68.50 -typedef struct _PurplePluginAction PurplePluginAction;
68.51 -
68.52 -typedef int PurplePluginPriority; /**< Plugin priority. */
68.53 -
68.54 -#include "pluginpref.h"
68.55 -
68.56 -/**
68.57 - * Plugin types.
68.58 - */
68.59 -typedef enum
68.60 -{
68.61 - PURPLE_PLUGIN_UNKNOWN = -1, /**< Unknown type. */
68.62 - PURPLE_PLUGIN_STANDARD = 0, /**< Standard plugin. */
68.63 - PURPLE_PLUGIN_LOADER, /**< Loader plugin. */
68.64 - PURPLE_PLUGIN_PROTOCOL /**< Protocol plugin. */
68.65 -
68.66 -} PurplePluginType;
68.67 -
68.68 -#define PURPLE_PRIORITY_DEFAULT 0
68.69 -#define PURPLE_PRIORITY_HIGHEST 9999
68.70 -#define PURPLE_PRIORITY_LOWEST -9999
68.71 -
68.72 -#define PURPLE_PLUGIN_FLAG_INVISIBLE 0x01
68.73 -
68.74 -#define PURPLE_PLUGIN_MAGIC 5 /* once we hit 6.0.0 I think we can remove this */
68.75 -
68.76 -/**
68.77 - * Detailed information about a plugin.
68.78 - *
68.79 - * This is used in the version 2.0 API and up.
68.80 - */
68.81 -struct _PurplePluginInfo
68.82 -{
68.83 - unsigned int magic;
68.84 - unsigned int major_version;
68.85 - unsigned int minor_version;
68.86 - PurplePluginType type;
68.87 - char *ui_requirement;
68.88 - unsigned long flags;
68.89 - GList *dependencies;
68.90 - PurplePluginPriority priority;
68.91 -
68.92 - char *id;
68.93 - char *name;
68.94 - char *version;
68.95 - char *summary;
68.96 - char *description;
68.97 - char *author;
68.98 - char *homepage;
68.99 -
68.100 - /**
68.101 - * If a plugin defines a 'load' function, and it returns FALSE,
68.102 - * then the plugin will not be loaded.
68.103 - */
68.104 - gboolean (*load)(PurplePlugin *plugin);
68.105 - gboolean (*unload)(PurplePlugin *plugin);
68.106 - void (*destroy)(PurplePlugin *plugin);
68.107 -
68.108 - void *ui_info; /**< Used only by UI-specific plugins to build a preference screen with a custom UI */
68.109 - void *extra_info;
68.110 - PurplePluginUiInfo *prefs_info; /**< Used by any plugin to display preferences. If #ui_info has been specified, this will be ignored. */
68.111 - GList *(*actions)(PurplePlugin *plugin, gpointer context);
68.112 -
68.113 - void (*_purple_reserved1)(void);
68.114 - void (*_purple_reserved2)(void);
68.115 - void (*_purple_reserved3)(void);
68.116 - void (*_purple_reserved4)(void);
68.117 -};
68.118 -
68.119 -/**
68.120 - * Extra information for loader plugins.
68.121 - */
68.122 -struct _PurplePluginLoaderInfo
68.123 -{
68.124 - GList *exts;
68.125 -
68.126 - gboolean (*probe)(PurplePlugin *plugin);
68.127 - gboolean (*load)(PurplePlugin *plugin);
68.128 - gboolean (*unload)(PurplePlugin *plugin);
68.129 - void (*destroy)(PurplePlugin *plugin);
68.130 -
68.131 - void (*_purple_reserved1)(void);
68.132 - void (*_purple_reserved2)(void);
68.133 - void (*_purple_reserved3)(void);
68.134 - void (*_purple_reserved4)(void);
68.135 -};
68.136 -
68.137 -/**
68.138 - * A plugin handle.
68.139 - */
68.140 -struct _PurplePlugin
68.141 -{
68.142 - gboolean native_plugin; /**< Native C plugin. */
68.143 - gboolean loaded; /**< The loaded state. */
68.144 - void *handle; /**< The module handle. */
68.145 - char *path; /**< The path to the plugin. */
68.146 - PurplePluginInfo *info; /**< The plugin information. */
68.147 - char *error;
68.148 - void *ipc_data; /**< IPC data. */
68.149 - void *extra; /**< Plugin-specific data. */
68.150 - gboolean unloadable; /**< Unloadable */
68.151 - GList *dependent_plugins; /**< Plugins depending on this */
68.152 -
68.153 - void (*_purple_reserved1)(void);
68.154 - void (*_purple_reserved2)(void);
68.155 - void (*_purple_reserved3)(void);
68.156 - void (*_purple_reserved4)(void);
68.157 -};
68.158 -
68.159 -#define PURPLE_PLUGIN_LOADER_INFO(plugin) \
68.160 - ((PurplePluginLoaderInfo *)(plugin)->info->extra_info)
68.161 -
68.162 -struct _PurplePluginUiInfo {
68.163 - PurplePluginPrefFrame *(*get_plugin_pref_frame)(PurplePlugin *plugin);
68.164 -
68.165 - int page_num; /**< Reserved */
68.166 - PurplePluginPrefFrame *frame; /**< Reserved */
68.167 -
68.168 - void (*_purple_reserved1)(void);
68.169 - void (*_purple_reserved2)(void);
68.170 - void (*_purple_reserved3)(void);
68.171 - void (*_purple_reserved4)(void);
68.172 -};
68.173 -
68.174 -#define PURPLE_PLUGIN_HAS_PREF_FRAME(plugin) \
68.175 - ((plugin)->info != NULL && (plugin)->info->prefs_info != NULL)
68.176 -
68.177 -#define PURPLE_PLUGIN_UI_INFO(plugin) \
68.178 - ((PurplePluginUiInfo*)(plugin)->info->prefs_info)
68.179 -
68.180 -
68.181 -/**
68.182 - * The structure used in the actions member of PurplePluginInfo
68.183 - */
68.184 -struct _PurplePluginAction {
68.185 - char *label;
68.186 - void (*callback)(PurplePluginAction *);
68.187 -
68.188 - /** set to the owning plugin */
68.189 - PurplePlugin *plugin;
68.190 -
68.191 - /** NULL for plugin actions menu, set to the PurpleConnection for
68.192 - account actions menu */
68.193 - gpointer context;
68.194 -
68.195 - gpointer user_data;
68.196 -};
68.197 -
68.198 -#define PURPLE_PLUGIN_HAS_ACTIONS(plugin) \
68.199 - ((plugin)->info != NULL && (plugin)->info->actions != NULL)
68.200 -
68.201 -#define PURPLE_PLUGIN_ACTIONS(plugin, context) \
68.202 - (PURPLE_PLUGIN_HAS_ACTIONS(plugin)? \
68.203 - (plugin)->info->actions(plugin, context): NULL)
68.204 -
68.205 -
68.206 -/**
68.207 - * Handles the initialization of modules.
68.208 - */
68.209 -#if !defined(PURPLE_PLUGINS) || defined(PURPLE_STATIC_PRPL)
68.210 -# define _FUNC_NAME(x) purple_init_##x##_plugin
68.211 -# define PURPLE_INIT_PLUGIN(pluginname, initfunc, plugininfo) \
68.212 - gboolean _FUNC_NAME(pluginname)(void);\
68.213 - gboolean _FUNC_NAME(pluginname)(void) { \
68.214 - PurplePlugin *plugin = purple_plugin_new(TRUE, NULL); \
68.215 - plugin->info = &(plugininfo); \
68.216 - initfunc((plugin)); \
68.217 - purple_plugin_load((plugin)); \
68.218 - return purple_plugin_register(plugin); \
68.219 - }
68.220 -#else /* PURPLE_PLUGINS && !PURPLE_STATIC_PRPL */
68.221 -# define PURPLE_INIT_PLUGIN(pluginname, initfunc, plugininfo) \
68.222 - G_MODULE_EXPORT gboolean purple_init_plugin(PurplePlugin *plugin); \
68.223 - G_MODULE_EXPORT gboolean purple_init_plugin(PurplePlugin *plugin) { \
68.224 - plugin->info = &(plugininfo); \
68.225 - initfunc((plugin)); \
68.226 - return purple_plugin_register(plugin); \
68.227 - }
68.228 -#endif
68.229 -
68.230 -
68.231 -#ifdef __cplusplus
68.232 -extern "C" {
68.233 -#endif
68.234 -
68.235 -/**************************************************************************/
68.236 -/** @name Plugin API */
68.237 -/**************************************************************************/
68.238 -/*@{*/
68.239 -
68.240 -/**
68.241 - * Creates a new plugin structure.
68.242 - *
68.243 - * @param native Whether or not the plugin is native.
68.244 - * @param path The path to the plugin, or @c NULL if statically compiled.
68.245 - *
68.246 - * @return A new PurplePlugin structure.
68.247 - */
68.248 -PurplePlugin *purple_plugin_new(gboolean native, const char *path);
68.249 -
68.250 -/**
68.251 - * Probes a plugin, retrieving the information on it and adding it to the
68.252 - * list of available plugins.
68.253 - *
68.254 - * @param filename The plugin's filename.
68.255 - *
68.256 - * @return The plugin handle.
68.257 - *
68.258 - * @see purple_plugin_load()
68.259 - * @see purple_plugin_destroy()
68.260 - */
68.261 -PurplePlugin *purple_plugin_probe(const char *filename);
68.262 -
68.263 -/**
68.264 - * Registers a plugin and prepares it for loading.
68.265 - *
68.266 - * This shouldn't be called by anything but the internal module code.
68.267 - * Plugins should use the PURPLE_INIT_PLUGIN() macro to register themselves
68.268 - * with the core.
68.269 - *
68.270 - * @param plugin The plugin to register.
68.271 - *
68.272 - * @return @c TRUE if the plugin was registered successfully. Otherwise
68.273 - * @c FALSE is returned (this happens if the plugin does not contain
68.274 - * the necessary information).
68.275 - */
68.276 -gboolean purple_plugin_register(PurplePlugin *plugin);
68.277 -
68.278 -/**
68.279 - * Attempts to load a previously probed plugin.
68.280 - *
68.281 - * @param plugin The plugin to load.
68.282 - *
68.283 - * @return @c TRUE if successful, or @c FALSE otherwise.
68.284 - *
68.285 - * @see purple_plugin_reload()
68.286 - * @see purple_plugin_unload()
68.287 - */
68.288 -gboolean purple_plugin_load(PurplePlugin *plugin);
68.289 -
68.290 -/**
68.291 - * Unloads the specified plugin.
68.292 - *
68.293 - * @param plugin The plugin handle.
68.294 - *
68.295 - * @return @c TRUE if successful, or @c FALSE otherwise.
68.296 - *
68.297 - * @see purple_plugin_load()
68.298 - * @see purple_plugin_reload()
68.299 - */
68.300 -gboolean purple_plugin_unload(PurplePlugin *plugin);
68.301 -
68.302 -/**
68.303 - * Disable a plugin.
68.304 - *
68.305 - * This function adds the plugin to a list of plugins to "disable at the next
68.306 - * startup" by excluding said plugins from the list of plugins to save. The
68.307 - * UI needs to call purple_plugins_save_loaded() after calling this for it
68.308 - * to have any effect.
68.309 - *
68.310 - * @since 2.3.0
68.311 - */
68.312 -void purple_plugin_disable(PurplePlugin *plugin);
68.313 -
68.314 -/**
68.315 - * Reloads a plugin.
68.316 - *
68.317 - * @param plugin The old plugin handle.
68.318 - *
68.319 - * @return @c TRUE if successful, or @c FALSE otherwise.
68.320 - *
68.321 - * @see purple_plugin_load()
68.322 - * @see purple_plugin_unload()
68.323 - */
68.324 -gboolean purple_plugin_reload(PurplePlugin *plugin);
68.325 -
68.326 -/**
68.327 - * Unloads a plugin and destroys the structure from memory.
68.328 - *
68.329 - * @param plugin The plugin handle.
68.330 - */
68.331 -void purple_plugin_destroy(PurplePlugin *plugin);
68.332 -
68.333 -/**
68.334 - * Returns whether or not a plugin is currently loaded.
68.335 - *
68.336 - * @param plugin The plugin.
68.337 - *
68.338 - * @return @c TRUE if loaded, or @c FALSE otherwise.
68.339 - */
68.340 -gboolean purple_plugin_is_loaded(const PurplePlugin *plugin);
68.341 -
68.342 -/**
68.343 - * Returns whether or not a plugin is unloadable.
68.344 - *
68.345 - * If this returns @c TRUE, the plugin is guaranteed to not
68.346 - * be loadable. However, a return value of @c FALSE does not
68.347 - * guarantee the plugin is loadable.
68.348 - *
68.349 - * @param plugin The plugin.
68.350 - *
68.351 - * @return @c TRUE if the plugin is known to be unloadable,\
68.352 - * @c FALSE otherwise
68.353 - */
68.354 -gboolean purple_plugin_is_unloadable(const PurplePlugin *plugin);
68.355 -
68.356 -/**
68.357 - * Returns a plugin's id.
68.358 - *
68.359 - * @param plugin The plugin.
68.360 - *
68.361 - * @return The plugin's id.
68.362 - */
68.363 -const gchar *purple_plugin_get_id(const PurplePlugin *plugin);
68.364 -
68.365 -/**
68.366 - * Returns a plugin's name.
68.367 - *
68.368 - * @param plugin The plugin.
68.369 - *
68.370 - * @return THe name of the plugin, or @c NULL.
68.371 - */
68.372 -const gchar *purple_plugin_get_name(const PurplePlugin *plugin);
68.373 -
68.374 -/**
68.375 - * Returns a plugin's version.
68.376 - *
68.377 - * @param plugin The plugin.
68.378 - *
68.379 - * @return The plugin's version or @c NULL.
68.380 - */
68.381 -const gchar *purple_plugin_get_version(const PurplePlugin *plugin);
68.382 -
68.383 -/**
68.384 - * Returns a plugin's summary.
68.385 - *
68.386 - * @param plugin The plugin.
68.387 - *
68.388 - * @return The plugin's summary.
68.389 - */
68.390 -const gchar *purple_plugin_get_summary(const PurplePlugin *plugin);
68.391 -
68.392 -/**
68.393 - * Returns a plugin's description.
68.394 - *
68.395 - * @param plugin The plugin.
68.396 - *
68.397 - * @return The plugin's description.
68.398 - */
68.399 -const gchar *purple_plugin_get_description(const PurplePlugin *plugin);
68.400 -
68.401 -/**
68.402 - * Returns a plugin's author.
68.403 - *
68.404 - * @param plugin The plugin.
68.405 - *
68.406 - * @return The plugin's author.
68.407 - */
68.408 -const gchar *purple_plugin_get_author(const PurplePlugin *plugin);
68.409 -
68.410 -/**
68.411 - * Returns a plugin's homepage.
68.412 - *
68.413 - * @param plugin The plugin.
68.414 - *
68.415 - * @return The plugin's homepage.
68.416 - */
68.417 -const gchar *purple_plugin_get_homepage(const PurplePlugin *plugin);
68.418 -
68.419 -/*@}*/
68.420 -
68.421 -/**************************************************************************/
68.422 -/** @name Plugin IPC API */
68.423 -/**************************************************************************/
68.424 -/*@{*/
68.425 -
68.426 -/**
68.427 - * Registers an IPC command in a plugin.
68.428 - *
68.429 - * @param plugin The plugin to register the command with.
68.430 - * @param command The name of the command.
68.431 - * @param func The function to execute.
68.432 - * @param marshal The marshalling function.
68.433 - * @param ret_value The return value type.
68.434 - * @param num_params The number of parameters.
68.435 - * @param ... The parameter types.
68.436 - *
68.437 - * @return TRUE if the function was registered successfully, or
68.438 - * FALSE otherwise.
68.439 - */
68.440 -gboolean purple_plugin_ipc_register(PurplePlugin *plugin, const char *command,
68.441 - PurpleCallback func,
68.442 - PurpleSignalMarshalFunc marshal,
68.443 - PurpleValue *ret_value, int num_params, ...);
68.444 -
68.445 -/**
68.446 - * Unregisters an IPC command in a plugin.
68.447 - *
68.448 - * @param plugin The plugin to unregister the command from.
68.449 - * @param command The name of the command.
68.450 - */
68.451 -void purple_plugin_ipc_unregister(PurplePlugin *plugin, const char *command);
68.452 -
68.453 -/**
68.454 - * Unregisters all IPC commands in a plugin.
68.455 - *
68.456 - * @param plugin The plugin to unregister the commands from.
68.457 - */
68.458 -void purple_plugin_ipc_unregister_all(PurplePlugin *plugin);
68.459 -
68.460 -/**
68.461 - * Returns a list of value types used for an IPC command.
68.462 - *
68.463 - * @param plugin The plugin.
68.464 - * @param command The name of the command.
68.465 - * @param ret_value The returned return value.
68.466 - * @param num_params The returned number of parameters.
68.467 - * @param params The returned list of parameters.
68.468 - *
68.469 - * @return TRUE if the command was found, or FALSE otherwise.
68.470 - */
68.471 -gboolean purple_plugin_ipc_get_params(PurplePlugin *plugin, const char *command,
68.472 - PurpleValue **ret_value, int *num_params,
68.473 - PurpleValue ***params);
68.474 -
68.475 -/**
68.476 - * Executes an IPC command.
68.477 - *
68.478 - * @param plugin The plugin to execute the command on.
68.479 - * @param command The name of the command.
68.480 - * @param ok TRUE if the call was successful, or FALSE otherwise.
68.481 - * @param ... The parameters to pass.
68.482 - *
68.483 - * @return The return value, which will be NULL if the command doesn't
68.484 - * return a value.
68.485 - */
68.486 -void *purple_plugin_ipc_call(PurplePlugin *plugin, const char *command,
68.487 - gboolean *ok, ...);
68.488 -
68.489 -/*@}*/
68.490 -
68.491 -/**************************************************************************/
68.492 -/** @name Plugins API */
68.493 -/**************************************************************************/
68.494 -/*@{*/
68.495 -
68.496 -/**
68.497 - * Add a new directory to search for plugins
68.498 - *
68.499 - * @param path The new search path.
68.500 - */
68.501 -void purple_plugins_add_search_path(const char *path);
68.502 -
68.503 -/**
68.504 - * Unloads all loaded plugins.
68.505 - */
68.506 -void purple_plugins_unload_all(void);
68.507 -
68.508 -/**
68.509 - * Destroys all registered plugins.
68.510 - */
68.511 -void purple_plugins_destroy_all(void);
68.512 -
68.513 -/**
68.514 - * Saves the list of loaded plugins to the specified preference key
68.515 - *
68.516 - * @param key The preference key to save the list of plugins to.
68.517 - */
68.518 -void purple_plugins_save_loaded(const char *key);
68.519 -
68.520 -/**
68.521 - * Attempts to load all the plugins in the specified preference key
68.522 - * that were loaded when purple last quit.
68.523 - *
68.524 - * @param key The preference key containing the list of plugins.
68.525 - */
68.526 -void purple_plugins_load_saved(const char *key);
68.527 -
68.528 -/**
68.529 - * Probes for plugins in the registered module paths.
68.530 - *
68.531 - * @param ext The extension type to probe for, or @c NULL for all.
68.532 - *
68.533 - * @see purple_plugin_set_probe_path()
68.534 - */
68.535 -void purple_plugins_probe(const char *ext);
68.536 -
68.537 -/**
68.538 - * Returns whether or not plugin support is enabled.
68.539 - *
68.540 - * @return TRUE if plugin support is enabled, or FALSE otherwise.
68.541 - */
68.542 -gboolean purple_plugins_enabled(void);
68.543 -
68.544 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
68.545 -/**
68.546 - * Registers a function that will be called when probing is finished.
68.547 - *
68.548 - * @param func The callback function.
68.549 - * @param data Data to pass to the callback.
68.550 - * @deprecated If you need this, ask for a plugin-probe signal to be added.
68.551 - */
68.552 -void purple_plugins_register_probe_notify_cb(void (*func)(void *), void *data);
68.553 -#endif
68.554 -
68.555 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
68.556 -/**
68.557 - * Unregisters a function that would be called when probing is finished.
68.558 - *
68.559 - * @param func The callback function.
68.560 - * @deprecated If you need this, ask for a plugin-probe signal to be added.
68.561 - */
68.562 -void purple_plugins_unregister_probe_notify_cb(void (*func)(void *));
68.563 -#endif
68.564 -
68.565 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
68.566 -/**
68.567 - * Registers a function that will be called when a plugin is loaded.
68.568 - *
68.569 - * @param func The callback function.
68.570 - * @param data Data to pass to the callback.
68.571 - * @deprecated Use the plugin-load signal instead.
68.572 - */
68.573 -void purple_plugins_register_load_notify_cb(void (*func)(PurplePlugin *, void *),
68.574 - void *data);
68.575 -#endif
68.576 -
68.577 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
68.578 -/**
68.579 - * Unregisters a function that would be called when a plugin is loaded.
68.580 - *
68.581 - * @param func The callback function.
68.582 - * @deprecated Use the plugin-load signal instead.
68.583 - */
68.584 -void purple_plugins_unregister_load_notify_cb(void (*func)(PurplePlugin *, void *));
68.585 -#endif
68.586 -
68.587 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
68.588 -/**
68.589 - * Registers a function that will be called when a plugin is unloaded.
68.590 - *
68.591 - * @param func The callback function.
68.592 - * @param data Data to pass to the callback.
68.593 - * @deprecated Use the plugin-unload signal instead.
68.594 - */
68.595 -void purple_plugins_register_unload_notify_cb(void (*func)(PurplePlugin *, void *),
68.596 - void *data);
68.597 -#endif
68.598 -
68.599 -#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
68.600 -/**
68.601 - * Unregisters a function that would be called when a plugin is unloaded.
68.602 - *
68.603 - * @param func The callback function.
68.604 - * @deprecated Use the plugin-unload signal instead.
68.605 - */
68.606 -void purple_plugins_unregister_unload_notify_cb(void (*func)(PurplePlugin *,
68.607 - void *));
68.608 -#endif
68.609 -
68.610 -/**
68.611 - * Finds a plugin with the specified name.
68.612 - *
68.613 - * @param name The plugin name.
68.614 - *
68.615 - * @return The plugin if found, or @c NULL if not found.
68.616 - */
68.617 -PurplePlugin *purple_plugins_find_with_name(const char *name);
68.618 -
68.619 -/**
68.620 - * Finds a plugin with the specified filename (filename with a path).
68.621 - *
68.622 - * @param filename The plugin filename.
68.623 - *
68.624 - * @return The plugin if found, or @c NULL if not found.
68.625 - */
68.626 -PurplePlugin *purple_plugins_find_with_filename(const char *filename);
68.627 -
68.628 -/**
68.629 - * Finds a plugin with the specified basename (filename without a path).
68.630 - *
68.631 - * @param basename The plugin basename.
68.632 - *
68.633 - * @return The plugin if found, or @c NULL if not found.
68.634 - */
68.635 -PurplePlugin *purple_plugins_find_with_basename(const char *basename);
68.636 -
68.637 -/**
68.638 - * Finds a plugin with the specified plugin ID.
68.639 - *
68.640 - * @param id The plugin ID.
68.641 - *
68.642 - * @return The plugin if found, or @c NULL if not found.
68.643 - */
68.644 -PurplePlugin *purple_plugins_find_with_id(const char *id);
68.645 -
68.646 -/**
68.647 - * Returns a list of all loaded plugins.
68.648 - *
68.649 - * @constreturn A list of all loaded plugins.
68.650 - */
68.651 -GList *purple_plugins_get_loaded(void);
68.652 -
68.653 -/**
68.654 - * Returns a list of all valid protocol plugins. A protocol
68.655 - * plugin is considered invalid if it does not contain the call
68.656 - * to the PURPLE_INIT_PLUGIN() macro, or if it was compiled
68.657 - * against an incompatable API version.
68.658 - *
68.659 - * @constreturn A list of all protocol plugins.
68.660 - */
68.661 -GList *purple_plugins_get_protocols(void);
68.662 -
68.663 -/**
68.664 - * Returns a list of all plugins, whether loaded or not.
68.665 - *
68.666 - * @constreturn A list of all plugins.
68.667 - */
68.668 -GList *purple_plugins_get_all(void);
68.669 -
68.670 -/*@}*/
68.671 -
68.672 -/**************************************************************************/
68.673 -/** @name Plugins SubSytem API */
68.674 -/**************************************************************************/
68.675 -/*@{*/
68.676 -
68.677 -/**
68.678 - * Returns the plugin subsystem handle.
68.679 - *
68.680 - * @return The plugin sybsystem handle.
68.681 - */
68.682 -void *purple_plugins_get_handle(void);
68.683 -
68.684 -/**
68.685 - * Initializes the plugin subsystem
68.686 - */
68.687 -void purple_plugins_init(void);
68.688 -
68.689 -/**
68.690 - * Uninitializes the plugin subsystem
68.691 - */
68.692 -void purple_plugins_uninit(void);
68.693 -
68.694 -/*@}*/
68.695 -
68.696 -/**
68.697 - * Allocates and returns a new PurplePluginAction.
68.698 - *
68.699 - * @param label The description of the action to show to the user.
68.700 - * @param callback The callback to call when the user selects this action.
68.701 - */
68.702 -PurplePluginAction *purple_plugin_action_new(const char* label, void (*callback)(PurplePluginAction *));
68.703 -
68.704 -/**
68.705 - * Frees a PurplePluginAction
68.706 - *
68.707 - * @param action The PurplePluginAction to free.
68.708 - */
68.709 -void purple_plugin_action_free(PurplePluginAction *action);
68.710 -
68.711 -#ifdef __cplusplus
68.712 -}
68.713 -#endif
68.714 -
68.715 -#endif /* _PURPLE_PLUGIN_H_ */
69.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/pluginpref.h Sun Jun 21 22:04:11 2009 -0400
69.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
69.3 @@ -1,269 +0,0 @@
69.4 -/**
69.5 - * @file pluginpref.h Plugin Preferences API
69.6 - * @ingroup core
69.7 - */
69.8 -
69.9 -/* purple
69.10 - *
69.11 - * Purple is the legal property of its developers, whose names are too numerous
69.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
69.13 - * source distribution.
69.14 - *
69.15 - * This program is free software; you can redistribute it and/or modify
69.16 - * it under the terms of the GNU General Public License as published by
69.17 - * the Free Software Foundation; either version 2 of the License, or
69.18 - * (at your option) any later version.
69.19 - *
69.20 - * This program is distributed in the hope that it will be useful,
69.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
69.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
69.23 - * GNU General Public License for more details.
69.24 - *
69.25 - * You should have received a copy of the GNU General Public License
69.26 - * along with this program; if not, write to the Free Software
69.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
69.28 - *
69.29 - */
69.30 -#ifndef _PURPLE_PLUGINPREF_H_
69.31 -#define _PURPLE_PLUGINPREF_H_
69.32 -
69.33 -typedef struct _PurplePluginPrefFrame PurplePluginPrefFrame;
69.34 -typedef struct _PurplePluginPref PurplePluginPref;
69.35 -
69.36 -/**
69.37 - * String format for preferences.
69.38 - */
69.39 -typedef enum
69.40 -{
69.41 - PURPLE_STRING_FORMAT_TYPE_NONE = 0, /**< The string is plain text. */
69.42 - PURPLE_STRING_FORMAT_TYPE_MULTILINE = 1 << 0, /**< The string can have newlines. */
69.43 - PURPLE_STRING_FORMAT_TYPE_HTML = 1 << 1 /**< The string can be in HTML. */
69.44 -} PurpleStringFormatType;
69.45 -
69.46 -typedef enum {
69.47 - PURPLE_PLUGIN_PREF_NONE,
69.48 - PURPLE_PLUGIN_PREF_CHOICE,
69.49 - PURPLE_PLUGIN_PREF_INFO, /**< no-value label */
69.50 - PURPLE_PLUGIN_PREF_STRING_FORMAT /**< The preference has a string value. */
69.51 -} PurplePluginPrefType;
69.52 -
69.53 -#include <glib.h>
69.54 -#include "prefs.h"
69.55 -
69.56 -#ifdef __cplusplus
69.57 -extern "C" {
69.58 -#endif
69.59 -
69.60 -/**************************************************************************/
69.61 -/** @name Plugin Preference API */
69.62 -/**************************************************************************/
69.63 -/*@{*/
69.64 -
69.65 -/**
69.66 - * Create a new plugin preference frame
69.67 - *
69.68 - * @return a new PurplePluginPrefFrame
69.69 - */
69.70 -PurplePluginPrefFrame *purple_plugin_pref_frame_new(void);
69.71 -
69.72 -/**
69.73 - * Destroy a plugin preference frame
69.74 - *
69.75 - * @param frame The plugin frame to destroy
69.76 - */
69.77 -void purple_plugin_pref_frame_destroy(PurplePluginPrefFrame *frame);
69.78 -
69.79 -/**
69.80 - * Adds a plugin preference to a plugin preference frame
69.81 - *
69.82 - * @param frame The plugin frame to add the preference to
69.83 - * @param pref The preference to add to the frame
69.84 - */
69.85 -void purple_plugin_pref_frame_add(PurplePluginPrefFrame *frame, PurplePluginPref *pref);
69.86 -
69.87 -/**
69.88 - * Get the plugin preferences from a plugin preference frame
69.89 - *
69.90 - * @param frame The plugin frame to get the plugin preferences from
69.91 - * @constreturn a GList of plugin preferences
69.92 - */
69.93 -GList *purple_plugin_pref_frame_get_prefs(PurplePluginPrefFrame *frame);
69.94 -
69.95 -/**
69.96 - * Create a new plugin preference
69.97 - *
69.98 - * @return a new PurplePluginPref
69.99 - */
69.100 -PurplePluginPref *purple_plugin_pref_new(void);
69.101 -
69.102 -/**
69.103 - * Create a new plugin preference with name
69.104 - *
69.105 - * @param name The name of the pref
69.106 - * @return a new PurplePluginPref
69.107 - */
69.108 -PurplePluginPref *purple_plugin_pref_new_with_name(const char *name);
69.109 -
69.110 -/**
69.111 - * Create a new plugin preference with label
69.112 - *
69.113 - * @param label The label to be displayed
69.114 - * @return a new PurplePluginPref
69.115 - */
69.116 -PurplePluginPref *purple_plugin_pref_new_with_label(const char *label);
69.117 -
69.118 -/**
69.119 - * Create a new plugin preference with name and label
69.120 - *
69.121 - * @param name The name of the pref
69.122 - * @param label The label to be displayed
69.123 - * @return a new PurplePluginPref
69.124 - */
69.125 -PurplePluginPref *purple_plugin_pref_new_with_name_and_label(const char *name, const char *label);
69.126 -
69.127 -/**
69.128 - * Destroy a plugin preference
69.129 - *
69.130 - * @param pref The preference to destroy
69.131 - */
69.132 -void purple_plugin_pref_destroy(PurplePluginPref *pref);
69.133 -
69.134 -/**
69.135 - * Set a plugin pref name
69.136 - *
69.137 - * @param pref The plugin pref
69.138 - * @param name The name of the pref
69.139 - */
69.140 -void purple_plugin_pref_set_name(PurplePluginPref *pref, const char *name);
69.141 -
69.142 -/**
69.143 - * Get a plugin pref name
69.144 - *
69.145 - * @param pref The plugin pref
69.146 - * @return The name of the pref
69.147 - */
69.148 -const char *purple_plugin_pref_get_name(PurplePluginPref *pref);
69.149 -
69.150 -/**
69.151 - * Set a plugin pref label
69.152 - *
69.153 - * @param pref The plugin pref
69.154 - * @param label The label for the plugin pref
69.155 - */
69.156 -void purple_plugin_pref_set_label(PurplePluginPref *pref, const char *label);
69.157 -
69.158 -/**
69.159 - * Get a plugin pref label
69.160 - *
69.161 - * @param pref The plugin pref
69.162 - * @return The label for the plugin pref
69.163 - */
69.164 -const char *purple_plugin_pref_get_label(PurplePluginPref *pref);
69.165 -
69.166 -/**
69.167 - * Set the bounds for an integer pref
69.168 - *
69.169 - * @param pref The plugin pref
69.170 - * @param min The min value
69.171 - * @param max The max value
69.172 - */
69.173 -void purple_plugin_pref_set_bounds(PurplePluginPref *pref, int min, int max);
69.174 -
69.175 -/**
69.176 - * Get the bounds for an integer pref
69.177 - *
69.178 - * @param pref The plugin pref
69.179 - * @param min The min value
69.180 - * @param max The max value
69.181 - */
69.182 -void purple_plugin_pref_get_bounds(PurplePluginPref *pref, int *min, int *max);
69.183 -
69.184 -/**
69.185 - * Set the type of a plugin pref
69.186 - *
69.187 - * @param pref The plugin pref
69.188 - * @param type The type
69.189 - */
69.190 -void purple_plugin_pref_set_type(PurplePluginPref *pref, PurplePluginPrefType type);
69.191 -
69.192 -/**
69.193 - * Get the type of a plugin pref
69.194 - *
69.195 - * @param pref The plugin pref
69.196 - * @return The type
69.197 - */
69.198 -PurplePluginPrefType purple_plugin_pref_get_type(PurplePluginPref *pref);
69.199 -
69.200 -/**
69.201 - * Set the choices for a choices plugin pref
69.202 - *
69.203 - * @param pref The plugin pref
69.204 - * @param label The label for the choice
69.205 - * @param choice A gpointer of the choice
69.206 - */
69.207 -void purple_plugin_pref_add_choice(PurplePluginPref *pref, const char *label, gpointer choice);
69.208 -
69.209 -/**
69.210 - * Get the choices for a choices plugin pref
69.211 - *
69.212 - * @param pref The plugin pref
69.213 - * @constreturn GList of the choices
69.214 - */
69.215 -GList *purple_plugin_pref_get_choices(PurplePluginPref *pref);
69.216 -
69.217 -/**
69.218 - * Set the max length for a string plugin pref
69.219 - *
69.220 - * @param pref The plugin pref
69.221 - * @param max_length The max length of the string
69.222 - */
69.223 -void purple_plugin_pref_set_max_length(PurplePluginPref *pref, unsigned int max_length);
69.224 -
69.225 -/**
69.226 - * Get the max length for a string plugin pref
69.227 - *
69.228 - * @param pref The plugin pref
69.229 - * @return the max length
69.230 - */
69.231 -unsigned int purple_plugin_pref_get_max_length(PurplePluginPref *pref);
69.232 -
69.233 -/**
69.234 - * Sets the masking of a string plugin pref
69.235 - *
69.236 - * @param pref The plugin pref
69.237 - * @param mask The value to set
69.238 - */
69.239 -void purple_plugin_pref_set_masked(PurplePluginPref *pref, gboolean mask);
69.240 -
69.241 -/**
69.242 - * Gets the masking of a string plugin pref
69.243 - *
69.244 - * @param pref The plugin pref
69.245 - * @return The masking
69.246 - */
69.247 -gboolean purple_plugin_pref_get_masked(PurplePluginPref *pref);
69.248 -
69.249 -/**
69.250 - * Sets the format type for a formattable-string plugin pref. You need to set the
69.251 - * pref type to PURPLE_PLUGIN_PREF_STRING_FORMAT first before setting the format.
69.252 - *
69.253 - * @param pref The plugin pref
69.254 - * @param format The format of the string
69.255 - */
69.256 -void purple_plugin_pref_set_format_type(PurplePluginPref *pref, PurpleStringFormatType format);
69.257 -
69.258 -/**
69.259 - * Gets the format type of the formattable-string plugin pref.
69.260 - *
69.261 - * @param pref The plugin pref
69.262 - * @return The format of the pref
69.263 - */
69.264 -PurpleStringFormatType purple_plugin_pref_get_format_type(PurplePluginPref *pref);
69.265 -
69.266 -/*@}*/
69.267 -
69.268 -#ifdef __cplusplus
69.269 -}
69.270 -#endif
69.271 -
69.272 -#endif /* _PURPLE_PLUGINPREF_H_ */
70.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/pounce.h Sun Jun 21 22:04:11 2009 -0400
70.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
70.3 @@ -1,380 +0,0 @@
70.4 -/**
70.5 - * @file pounce.h Buddy Pounce API
70.6 - * @ingroup core
70.7 - */
70.8 -
70.9 -/* purple
70.10 - *
70.11 - * Purple is the legal property of its developers, whose names are too numerous
70.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
70.13 - * source distribution.
70.14 - *
70.15 - * This program is free software; you can redistribute it and/or modify
70.16 - * it under the terms of the GNU General Public License as published by
70.17 - * the Free Software Foundation; either version 2 of the License, or
70.18 - * (at your option) any later version.
70.19 - *
70.20 - * This program is distributed in the hope that it will be useful,
70.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
70.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
70.23 - * GNU General Public License for more details.
70.24 - *
70.25 - * You should have received a copy of the GNU General Public License
70.26 - * along with this program; if not, write to the Free Software
70.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
70.28 - */
70.29 -#ifndef _PURPLE_POUNCE_H_
70.30 -#define _PURPLE_POUNCE_H_
70.31 -
70.32 -typedef struct _PurplePounce PurplePounce;
70.33 -
70.34 -#include <glib.h>
70.35 -#include "account.h"
70.36 -
70.37 -/**
70.38 - * Events that trigger buddy pounces.
70.39 - */
70.40 -typedef enum
70.41 -{
70.42 - PURPLE_POUNCE_NONE = 0x000, /**< No events. */
70.43 - PURPLE_POUNCE_SIGNON = 0x001, /**< The buddy signed on. */
70.44 - PURPLE_POUNCE_SIGNOFF = 0x002, /**< The buddy signed off. */
70.45 - PURPLE_POUNCE_AWAY = 0x004, /**< The buddy went away. */
70.46 - PURPLE_POUNCE_AWAY_RETURN = 0x008, /**< The buddy returned from away. */
70.47 - PURPLE_POUNCE_IDLE = 0x010, /**< The buddy became idle. */
70.48 - PURPLE_POUNCE_IDLE_RETURN = 0x020, /**< The buddy is no longer idle. */
70.49 - PURPLE_POUNCE_TYPING = 0x040, /**< The buddy started typing. */
70.50 - PURPLE_POUNCE_TYPED = 0x080, /**< The buddy has entered text. */
70.51 - PURPLE_POUNCE_TYPING_STOPPED = 0x100, /**< The buddy stopped typing. */
70.52 - PURPLE_POUNCE_MESSAGE_RECEIVED = 0x200 /**< The buddy sent a message */
70.53 -
70.54 -} PurplePounceEvent;
70.55 -
70.56 -typedef enum
70.57 -{
70.58 - PURPLE_POUNCE_OPTION_NONE = 0x00, /**< No Option */
70.59 - PURPLE_POUNCE_OPTION_AWAY = 0x01 /**< Pounce only when away */
70.60 -} PurplePounceOption;
70.61 -
70.62 -/** A pounce callback. */
70.63 -typedef void (*PurplePounceCb)(PurplePounce *, PurplePounceEvent, void *);
70.64 -
70.65 -/**
70.66 - * A buddy pounce structure.
70.67 - *
70.68 - * Buddy pounces are actions triggered by a buddy-related event. For
70.69 - * example, a sound can be played or an IM window opened when a buddy
70.70 - * signs on or returns from away. Such responses are handled in the
70.71 - * UI. The events themselves are done in the core.
70.72 - */
70.73 -struct _PurplePounce
70.74 -{
70.75 - char *ui_type; /**< The type of UI. */
70.76 -
70.77 - PurplePounceEvent events; /**< The event(s) to pounce on. */
70.78 - PurplePounceOption options; /**< The pounce options */
70.79 - PurpleAccount *pouncer; /**< The user who is pouncing. */
70.80 -
70.81 - char *pouncee; /**< The buddy to pounce on. */
70.82 -
70.83 - GHashTable *actions; /**< The registered actions. */
70.84 -
70.85 - gboolean save; /**< Whether or not the pounce should
70.86 - be saved after activation. */
70.87 - void *data; /**< Pounce-specific data. */
70.88 -};
70.89 -
70.90 -#ifdef __cplusplus
70.91 -extern "C" {
70.92 -#endif
70.93 -
70.94 -/**************************************************************************/
70.95 -/** @name Buddy Pounce API */
70.96 -/**************************************************************************/
70.97 -/*@{*/
70.98 -
70.99 -/**
70.100 - * Creates a new buddy pounce.
70.101 - *
70.102 - * @param ui_type The type of UI the pounce is for.
70.103 - * @param pouncer The account that will pounce.
70.104 - * @param pouncee The buddy to pounce on.
70.105 - * @param event The event(s) to pounce on.
70.106 - * @param option Pounce options.
70.107 - *
70.108 - * @return The new buddy pounce structure.
70.109 - */
70.110 -PurplePounce *purple_pounce_new(const char *ui_type, PurpleAccount *pouncer,
70.111 - const char *pouncee, PurplePounceEvent event,
70.112 - PurplePounceOption option);
70.113 -
70.114 -/**
70.115 - * Destroys a buddy pounce.
70.116 - *
70.117 - * @param pounce The buddy pounce.
70.118 - */
70.119 -void purple_pounce_destroy(PurplePounce *pounce);
70.120 -
70.121 -/**
70.122 - * Destroys all buddy pounces for the account
70.123 - *
70.124 - * @param account The account to remove all pounces from.
70.125 - */
70.126 -void purple_pounce_destroy_all_by_account(PurpleAccount *account);
70.127 -
70.128 -/**
70.129 - * Sets the events a pounce should watch for.
70.130 - *
70.131 - * @param pounce The buddy pounce.
70.132 - * @param events The events to watch for.
70.133 - */
70.134 -void purple_pounce_set_events(PurplePounce *pounce, PurplePounceEvent events);
70.135 -
70.136 -/**
70.137 - * Sets the options for a pounce.
70.138 - *
70.139 - * @param pounce The buddy pounce.
70.140 - * @param options The options for the pounce.
70.141 - */
70.142 -void purple_pounce_set_options(PurplePounce *pounce, PurplePounceOption options);
70.143 -
70.144 -/**
70.145 - * Sets the account that will do the pouncing.
70.146 - *
70.147 - * @param pounce The buddy pounce.
70.148 - * @param pouncer The account that will pounce.
70.149 - */
70.150 -void purple_pounce_set_pouncer(PurplePounce *pounce, PurpleAccount *pouncer);
70.151 -
70.152 -/**
70.153 - * Sets the buddy a pounce should pounce on.
70.154 - *
70.155 - * @param pounce The buddy pounce.
70.156 - * @param pouncee The buddy to pounce on.
70.157 - */
70.158 -void purple_pounce_set_pouncee(PurplePounce *pounce, const char *pouncee);
70.159 -
70.160 -/**
70.161 - * Sets whether or not the pounce should be saved after execution.
70.162 - *
70.163 - * @param pounce The buddy pounce.
70.164 - * @param save @c TRUE if the pounce should be saved, or @c FALSE otherwise.
70.165 - */
70.166 -void purple_pounce_set_save(PurplePounce *pounce, gboolean save);
70.167 -
70.168 -/**
70.169 - * Registers an action type for the pounce.
70.170 - *
70.171 - * @param pounce The buddy pounce.
70.172 - * @param name The action name.
70.173 - */
70.174 -void purple_pounce_action_register(PurplePounce *pounce, const char *name);
70.175 -
70.176 -/**
70.177 - * Enables or disables an action for a pounce.
70.178 - *
70.179 - * @param pounce The buddy pounce.
70.180 - * @param action The name of the action.
70.181 - * @param enabled The enabled state.
70.182 - */
70.183 -void purple_pounce_action_set_enabled(PurplePounce *pounce, const char *action,
70.184 - gboolean enabled);
70.185 -
70.186 -/**
70.187 - * Sets a value for an attribute in an action.
70.188 - *
70.189 - * If @a value is @c NULL, the value will be unset.
70.190 - *
70.191 - * @param pounce The buddy pounce.
70.192 - * @param action The action name.
70.193 - * @param attr The attribute name.
70.194 - * @param value The value.
70.195 - */
70.196 -void purple_pounce_action_set_attribute(PurplePounce *pounce, const char *action,
70.197 - const char *attr, const char *value);
70.198 -
70.199 -/**
70.200 - * Sets the pounce-specific data.
70.201 - *
70.202 - * @param pounce The buddy pounce.
70.203 - * @param data Data specific to the pounce.
70.204 - */
70.205 -void purple_pounce_set_data(PurplePounce *pounce, void *data);
70.206 -
70.207 -/**
70.208 - * Returns the events a pounce should watch for.
70.209 - *
70.210 - * @param pounce The buddy pounce.
70.211 - *
70.212 - * @return The events the pounce is watching for.
70.213 - */
70.214 -PurplePounceEvent purple_pounce_get_events(const PurplePounce *pounce);
70.215 -
70.216 -/**
70.217 - * Returns the options for a pounce.
70.218 - *
70.219 - * @param pounce The buddy pounce.
70.220 - *
70.221 - * @return The options for the pounce.
70.222 - */
70.223 -PurplePounceOption purple_pounce_get_options(const PurplePounce *pounce);
70.224 -
70.225 -/**
70.226 - * Returns the account that will do the pouncing.
70.227 - *
70.228 - * @param pounce The buddy pounce.
70.229 - *
70.230 - * @return The account that will pounce.
70.231 - */
70.232 -PurpleAccount *purple_pounce_get_pouncer(const PurplePounce *pounce);
70.233 -
70.234 -/**
70.235 - * Returns the buddy a pounce should pounce on.
70.236 - *
70.237 - * @param pounce The buddy pounce.
70.238 - *
70.239 - * @return The buddy to pounce on.
70.240 - */
70.241 -const char *purple_pounce_get_pouncee(const PurplePounce *pounce);
70.242 -
70.243 -/**
70.244 - * Returns whether or not the pounce should save after execution.
70.245 - *
70.246 - * @param pounce The buddy pounce.
70.247 - *
70.248 - * @return @c TRUE if the pounce should be saved after execution, or
70.249 - * @c FALSE otherwise.
70.250 - */
70.251 -gboolean purple_pounce_get_save(const PurplePounce *pounce);
70.252 -
70.253 -/**
70.254 - * Returns whether or not an action is enabled.
70.255 - *
70.256 - * @param pounce The buddy pounce.
70.257 - * @param action The action name.
70.258 - *
70.259 - * @return @c TRUE if the action is enabled, or @c FALSE otherwise.
70.260 - */
70.261 -gboolean purple_pounce_action_is_enabled(const PurplePounce *pounce,
70.262 - const char *action);
70.263 -
70.264 -/**
70.265 - * Returns the value for an attribute in an action.
70.266 - *
70.267 - * @param pounce The buddy pounce.
70.268 - * @param action The action name.
70.269 - * @param attr The attribute name.
70.270 - *
70.271 - * @return The attribute value, if it exists, or @c NULL.
70.272 - */
70.273 -const char *purple_pounce_action_get_attribute(const PurplePounce *pounce,
70.274 - const char *action,
70.275 - const char *attr);
70.276 -
70.277 -/**
70.278 - * Returns the pounce-specific data.
70.279 - *
70.280 - * @param pounce The buddy pounce.
70.281 - *
70.282 - * @return The data specific to a buddy pounce.
70.283 - */
70.284 -void *purple_pounce_get_data(const PurplePounce *pounce);
70.285 -
70.286 -/**
70.287 - * Executes a pounce with the specified pouncer, pouncee, and event type.
70.288 - *
70.289 - * @param pouncer The account that will do the pouncing.
70.290 - * @param pouncee The buddy that is being pounced.
70.291 - * @param events The events that triggered the pounce.
70.292 - */
70.293 -void purple_pounce_execute(const PurpleAccount *pouncer, const char *pouncee,
70.294 - PurplePounceEvent events);
70.295 -
70.296 -/*@}*/
70.297 -
70.298 -/**************************************************************************/
70.299 -/** @name Buddy Pounce Subsystem API */
70.300 -/**************************************************************************/
70.301 -/*@{*/
70.302 -
70.303 -/**
70.304 - * Finds a pounce with the specified event(s) and buddy.
70.305 - *
70.306 - * @param pouncer The account to match against.
70.307 - * @param pouncee The buddy to match against.
70.308 - * @param events The event(s) to match against.
70.309 - *
70.310 - * @return The pounce if found, or @c NULL otherwise.
70.311 - */
70.312 -PurplePounce *purple_find_pounce(const PurpleAccount *pouncer,
70.313 - const char *pouncee, PurplePounceEvent events);
70.314 -
70.315 -
70.316 -/**
70.317 - * Loads the pounces.
70.318 - *
70.319 - * @return @c TRUE if the pounces could be loaded.
70.320 - */
70.321 -gboolean purple_pounces_load(void);
70.322 -
70.323 -/**
70.324 - * Registers a pounce handler for a UI.
70.325 - *
70.326 - * @param ui The UI name.
70.327 - * @param cb The callback function.
70.328 - * @param new_pounce The function called when a pounce is created.
70.329 - * @param free_pounce The function called when a pounce is freed.
70.330 - */
70.331 -void purple_pounces_register_handler(const char *ui, PurplePounceCb cb,
70.332 - void (*new_pounce)(PurplePounce *pounce),
70.333 - void (*free_pounce)(PurplePounce *pounce));
70.334 -
70.335 -/**
70.336 - * Unregisters a pounce handle for a UI.
70.337 - *
70.338 - * @param ui The UI name.
70.339 - */
70.340 -void purple_pounces_unregister_handler(const char *ui);
70.341 -
70.342 -/**
70.343 - * Returns a list of all registered buddy pounces.
70.344 - *
70.345 - * @constreturn The list of buddy pounces.
70.346 - */
70.347 -GList *purple_pounces_get_all(void);
70.348 -
70.349 -/**
70.350 - * Returns a list of registered buddy pounces for the ui-type.
70.351 - *
70.352 - * @param ui The ID of the UI using the core.
70.353 - *
70.354 - * @return The list of buddy pounces. The list should be freed by
70.355 - * the caller when it's no longer used.
70.356 - * @since 2.1.0
70.357 - */
70.358 -GList *purple_pounces_get_all_for_ui(const char *ui);
70.359 -
70.360 -/**
70.361 - * Returns the buddy pounce subsystem handle.
70.362 - *
70.363 - * @return The subsystem handle.
70.364 - */
70.365 -void *purple_pounces_get_handle(void);
70.366 -
70.367 -/**
70.368 - * Initializes the pounces subsystem.
70.369 - */
70.370 -void purple_pounces_init(void);
70.371 -
70.372 -/**
70.373 - * Uninitializes the pounces subsystem.
70.374 - */
70.375 -void purple_pounces_uninit(void);
70.376 -
70.377 -/*@}*/
70.378 -
70.379 -#ifdef __cplusplus
70.380 -}
70.381 -#endif
70.382 -
70.383 -#endif /* _PURPLE_POUNCE_H_ */
71.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/prefs.h Sun Jun 21 22:04:11 2009 -0400
71.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
71.3 @@ -1,353 +0,0 @@
71.4 -/**
71.5 - * @file prefs.h Prefs API
71.6 - * @ingroup core
71.7 - */
71.8 -
71.9 -/* purple
71.10 - *
71.11 - * Purple is the legal property of its developers, whose names are too numerous
71.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
71.13 - * source distribution.
71.14 - *
71.15 - * This program is free software; you can redistribute it and/or modify
71.16 - * it under the terms of the GNU General Public License as published by
71.17 - * the Free Software Foundation; either version 2 of the License, or
71.18 - * (at your option) any later version.
71.19 - *
71.20 - * This program is distributed in the hope that it will be useful,
71.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
71.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
71.23 - * GNU General Public License for more details.
71.24 - *
71.25 - * You should have received a copy of the GNU General Public License
71.26 - * along with this program; if not, write to the Free Software
71.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
71.28 - *
71.29 - */
71.30 -#ifndef _PURPLE_PREFS_H_
71.31 -#define _PURPLE_PREFS_H_
71.32 -
71.33 -#include <glib.h>
71.34 -
71.35 -/**
71.36 - * Preference data types.
71.37 - */
71.38 -typedef enum _PurplePrefType
71.39 -{
71.40 - PURPLE_PREF_NONE, /**< No type. */
71.41 - PURPLE_PREF_BOOLEAN, /**< Boolean. */
71.42 - PURPLE_PREF_INT, /**< Integer. */
71.43 - PURPLE_PREF_STRING, /**< String. */
71.44 - PURPLE_PREF_STRING_LIST, /**< List of strings. */
71.45 - PURPLE_PREF_PATH, /**< Path. */
71.46 - PURPLE_PREF_PATH_LIST /**< List of paths. */
71.47 -
71.48 -} PurplePrefType;
71.49 -
71.50 -/**
71.51 - * The type of callbacks for preference changes.
71.52 - *
71.53 - * @param name the name of the preference which has changed.
71.54 - * @param type the type of the preferenced named @a name
71.55 - * @param val the new value of the preferencs; should be cast to the correct
71.56 - * type. For instance, to recover the value of a #PURPLE_PREF_INT
71.57 - * preference, use <tt>GPOINTER_TO_INT(val)</tt>. Alternatively,
71.58 - * just call purple_prefs_get_int(), purple_prefs_get_string_list()
71.59 - * etc.
71.60 - * @param data Arbitrary data specified when the callback was connected with
71.61 - * purple_prefs_connect_callback().
71.62 - *
71.63 - * @see purple_prefs_connect_callback()
71.64 - */
71.65 -typedef void (*PurplePrefCallback) (const char *name, PurplePrefType type,
71.66 - gconstpointer val, gpointer data);
71.67 -
71.68 -#ifdef __cplusplus
71.69 -extern "C" {
71.70 -#endif
71.71 -
71.72 -/**************************************************************************/
71.73 -/** @name Prefs API
71.74 - Preferences are named according to a directory-like structure.
71.75 - Example: "/plugins/core/potato/is_from_idaho" (probably a boolean) */
71.76 -/**************************************************************************/
71.77 -/*@{*/
71.78 -
71.79 -/**
71.80 - * Returns the prefs subsystem handle.
71.81 - *
71.82 - * @return The prefs subsystem handle.
71.83 - */
71.84 -void *purple_prefs_get_handle(void);
71.85 -
71.86 -/**
71.87 - * Initialize core prefs
71.88 - */
71.89 -void purple_prefs_init(void);
71.90 -
71.91 -/**
71.92 - * Uninitializes the prefs subsystem.
71.93 - */
71.94 -void purple_prefs_uninit(void);
71.95 -
71.96 -/**
71.97 - * Add a new typeless pref.
71.98 - *
71.99 - * @param name The name of the pref
71.100 - */
71.101 -void purple_prefs_add_none(const char *name);
71.102 -
71.103 -/**
71.104 - * Add a new boolean pref.
71.105 - *
71.106 - * @param name The name of the pref
71.107 - * @param value The initial value to set
71.108 - */
71.109 -void purple_prefs_add_bool(const char *name, gboolean value);
71.110 -
71.111 -/**
71.112 - * Add a new integer pref.
71.113 - *
71.114 - * @param name The name of the pref
71.115 - * @param value The initial value to set
71.116 - */
71.117 -void purple_prefs_add_int(const char *name, int value);
71.118 -
71.119 -/**
71.120 - * Add a new string pref.
71.121 - *
71.122 - * @param name The name of the pref
71.123 - * @param value The initial value to set
71.124 - */
71.125 -void purple_prefs_add_string(const char *name, const char *value);
71.126 -
71.127 -/**
71.128 - * Add a new string list pref.
71.129 - *
71.130 - * @param name The name of the pref
71.131 - * @param value The initial value to set
71.132 - * @note This function takes a copy of the strings in the value list. The list
71.133 - * itself and original copies of the strings are up to the caller to
71.134 - * free.
71.135 - */
71.136 -void purple_prefs_add_string_list(const char *name, GList *value);
71.137 -
71.138 -/**
71.139 - * Add a new path pref.
71.140 - *
71.141 - * @param name The name of the pref
71.142 - * @param value The initial value to set
71.143 - */
71.144 -void purple_prefs_add_path(const char *name, const char *value);
71.145 -
71.146 -/**
71.147 - * Add a new path list pref.
71.148 - *
71.149 - * @param name The name of the pref
71.150 - * @param value The initial value to set
71.151 - * @note This function takes a copy of the strings in the value list. The list
71.152 - * itself and original copies of the strings are up to the caller to
71.153 - * free.
71.154 - */
71.155 -void purple_prefs_add_path_list(const char *name, GList *value);
71.156 -
71.157 -
71.158 -/**
71.159 - * Remove a pref.
71.160 - *
71.161 - * @param name The name of the pref
71.162 - */
71.163 -void purple_prefs_remove(const char *name);
71.164 -
71.165 -/**
71.166 - * Rename a pref
71.167 - *
71.168 - * @param oldname The old name of the pref
71.169 - * @param newname The new name for the pref
71.170 - */
71.171 -void purple_prefs_rename(const char *oldname, const char *newname);
71.172 -
71.173 -/**
71.174 - * Rename a boolean pref, toggling it's value
71.175 - *
71.176 - * @param oldname The old name of the pref
71.177 - * @param newname The new name for the pref
71.178 - */
71.179 -void purple_prefs_rename_boolean_toggle(const char *oldname, const char *newname);
71.180 -
71.181 -/**
71.182 - * Remove all prefs.
71.183 - */
71.184 -void purple_prefs_destroy(void);
71.185 -
71.186 -/**
71.187 - * Set raw pref value
71.188 - *
71.189 - * @param name The name of the pref
71.190 - * @param value The value to set
71.191 - */
71.192 -void purple_prefs_set_generic(const char *name, gpointer value);
71.193 -
71.194 -/**
71.195 - * Set boolean pref value
71.196 - *
71.197 - * @param name The name of the pref
71.198 - * @param value The value to set
71.199 - */
71.200 -void purple_prefs_set_bool(const char *name, gboolean value);
71.201 -
71.202 -/**
71.203 - * Set integer pref value
71.204 - *
71.205 - * @param name The name of the pref
71.206 - * @param value The value to set
71.207 - */
71.208 -void purple_prefs_set_int(const char *name, int value);
71.209 -
71.210 -/**
71.211 - * Set string pref value
71.212 - *
71.213 - * @param name The name of the pref
71.214 - * @param value The value to set
71.215 - */
71.216 -void purple_prefs_set_string(const char *name, const char *value);
71.217 -
71.218 -/**
71.219 - * Set string list pref value
71.220 - *
71.221 - * @param name The name of the pref
71.222 - * @param value The value to set
71.223 - */
71.224 -void purple_prefs_set_string_list(const char *name, GList *value);
71.225 -
71.226 -/**
71.227 - * Set path pref value
71.228 - *
71.229 - * @param name The name of the pref
71.230 - * @param value The value to set
71.231 - */
71.232 -void purple_prefs_set_path(const char *name, const char *value);
71.233 -
71.234 -/**
71.235 - * Set path list pref value
71.236 - *
71.237 - * @param name The name of the pref
71.238 - * @param value The value to set
71.239 - */
71.240 -void purple_prefs_set_path_list(const char *name, GList *value);
71.241 -
71.242 -
71.243 -/**
71.244 - * Check if a pref exists
71.245 - *
71.246 - * @param name The name of the pref
71.247 - * @return TRUE if the pref exists. Otherwise FALSE.
71.248 - */
71.249 -gboolean purple_prefs_exists(const char *name);
71.250 -
71.251 -/**
71.252 - * Get pref type
71.253 - *
71.254 - * @param name The name of the pref
71.255 - * @return The type of the pref
71.256 - */
71.257 -PurplePrefType purple_prefs_get_type(const char *name);
71.258 -
71.259 -/**
71.260 - * Get boolean pref value
71.261 - *
71.262 - * @param name The name of the pref
71.263 - * @return The value of the pref
71.264 - */
71.265 -gboolean purple_prefs_get_bool(const char *name);
71.266 -
71.267 -/**
71.268 - * Get integer pref value
71.269 - *
71.270 - * @param name The name of the pref
71.271 - * @return The value of the pref
71.272 - */
71.273 -int purple_prefs_get_int(const char *name);
71.274 -
71.275 -/**
71.276 - * Get string pref value
71.277 - *
71.278 - * @param name The name of the pref
71.279 - * @return The value of the pref
71.280 - */
71.281 -const char *purple_prefs_get_string(const char *name);
71.282 -
71.283 -/**
71.284 - * Get string list pref value
71.285 - *
71.286 - * @param name The name of the pref
71.287 - * @return The value of the pref
71.288 - */
71.289 -GList *purple_prefs_get_string_list(const char *name);
71.290 -
71.291 -/**
71.292 - * Get path pref value
71.293 - *
71.294 - * @param name The name of the pref
71.295 - * @return The value of the pref
71.296 - */
71.297 -const char *purple_prefs_get_path(const char *name);
71.298 -
71.299 -/**
71.300 - * Get path list pref value
71.301 - *
71.302 - * @param name The name of the pref
71.303 - * @return The value of the pref
71.304 - */
71.305 -GList *purple_prefs_get_path_list(const char *name);
71.306 -
71.307 -/**
71.308 - * Returns a list of children for a pref
71.309 - *
71.310 - * @param name The parent pref
71.311 - * @return A list of newly allocated strings denoting the names of the children.
71.312 - * Returns @c NULL if there are no children or if pref doesn't exist.
71.313 - * The caller must free all the strings and the list.
71.314 - *
71.315 - * @since 2.1.0
71.316 - */
71.317 -GList *purple_prefs_get_children_names(const char *name);
71.318 -
71.319 -/**
71.320 - * Add a callback to a pref (and its children)
71.321 - */
71.322 -guint purple_prefs_connect_callback(void *handle, const char *name, PurplePrefCallback cb,
71.323 - gpointer data);
71.324 -
71.325 -/**
71.326 - * Remove a callback to a pref
71.327 - */
71.328 -void purple_prefs_disconnect_callback(guint callback_id);
71.329 -
71.330 -/**
71.331 - * Remove all pref callbacks by handle
71.332 - */
71.333 -void purple_prefs_disconnect_by_handle(void *handle);
71.334 -
71.335 -/**
71.336 - * Trigger callbacks as if the pref changed
71.337 - */
71.338 -void purple_prefs_trigger_callback(const char *name);
71.339 -
71.340 -/**
71.341 - * Read preferences
71.342 - */
71.343 -gboolean purple_prefs_load(void);
71.344 -
71.345 -/**
71.346 - * Rename legacy prefs and delete some that no longer exist.
71.347 - */
71.348 -void purple_prefs_update_old(void);
71.349 -
71.350 -/*@}*/
71.351 -
71.352 -#ifdef __cplusplus
71.353 -}
71.354 -#endif
71.355 -
71.356 -#endif /* _PURPLE_PREFS_H_ */
72.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/presence.h Sun Jun 21 22:04:11 2009 -0400
72.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
72.3 @@ -1,38 +0,0 @@
72.4 -/**
72.5 - * @file presence.h Presence
72.6 - *
72.7 - * purple
72.8 - *
72.9 - * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
72.10 - *
72.11 - * This program is free software; you can redistribute it and/or modify
72.12 - * it under the terms of the GNU General Public License as published by
72.13 - * the Free Software Foundation; either version 2 of the License, or
72.14 - * (at your option) any later version.
72.15 - *
72.16 - * This program is distributed in the hope that it will be useful,
72.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
72.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
72.19 - * GNU General Public License for more details.
72.20 - *
72.21 - * You should have received a copy of the GNU General Public License
72.22 - * along with this program; if not, write to the Free Software
72.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
72.24 - */
72.25 -#ifndef _PURPLE_JABBER_PRESENCE_H_
72.26 -#define _PURPLE_JABBER_PRESENCE_H_
72.27 -
72.28 -#include "buddy.h"
72.29 -#include "jabber.h"
72.30 -#include "xmlnode.h"
72.31 -
72.32 -void jabber_presence_send(PurpleAccount *account, PurpleStatus *status);
72.33 -xmlnode *jabber_presence_create(JabberBuddyState state, const char *msg, int priority); /* DEPRECATED */
72.34 -xmlnode *jabber_presence_create_js(JabberStream *js, JabberBuddyState state, const char *msg, int priority);
72.35 -void jabber_presence_parse(JabberStream *js, xmlnode *packet);
72.36 -void jabber_presence_subscription_set(JabberStream *js, const char *who,
72.37 - const char *type);
72.38 -void jabber_presence_fake_to_self(JabberStream *js, const PurpleStatus *status);
72.39 -void purple_status_to_jabber(const PurpleStatus *status, JabberBuddyState *state, char **msg, int *priority);
72.40 -
72.41 -#endif /* _PURPLE_JABBER_PRESENCE_H_ */
73.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/privacy.h Sun Jun 21 22:04:11 2009 -0400
73.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
73.3 @@ -1,194 +0,0 @@
73.4 -/**
73.5 - * @file privacy.h Privacy API
73.6 - * @ingroup core
73.7 - */
73.8 -
73.9 -/* purple
73.10 - *
73.11 - * Purple is the legal property of its developers, whose names are too numerous
73.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
73.13 - * source distribution.
73.14 - *
73.15 - * This program is free software; you can redistribute it and/or modify
73.16 - * it under the terms of the GNU General Public License as published by
73.17 - * the Free Software Foundation; either version 2 of the License, or
73.18 - * (at your option) any later version.
73.19 - *
73.20 - * This program is distributed in the hope that it will be useful,
73.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
73.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
73.23 - * GNU General Public License for more details.
73.24 - *
73.25 - * You should have received a copy of the GNU General Public License
73.26 - * along with this program; if not, write to the Free Software
73.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
73.28 - */
73.29 -#ifndef _PURPLE_PRIVACY_H_
73.30 -#define _PURPLE_PRIVACY_H_
73.31 -
73.32 -#include "account.h"
73.33 -
73.34 -/**
73.35 - * Privacy data types.
73.36 - */
73.37 -typedef enum _PurplePrivacyType
73.38 -{
73.39 - PURPLE_PRIVACY_ALLOW_ALL = 1,
73.40 - PURPLE_PRIVACY_DENY_ALL,
73.41 - PURPLE_PRIVACY_ALLOW_USERS,
73.42 - PURPLE_PRIVACY_DENY_USERS,
73.43 - PURPLE_PRIVACY_ALLOW_BUDDYLIST
73.44 -} PurplePrivacyType;
73.45 -
73.46 -#ifdef __cplusplus
73.47 -extern "C" {
73.48 -#endif
73.49 -
73.50 -/**
73.51 - * Privacy core/UI operations.
73.52 - */
73.53 -typedef struct
73.54 -{
73.55 - void (*permit_added)(PurpleAccount *account, const char *name);
73.56 - void (*permit_removed)(PurpleAccount *account, const char *name);
73.57 - void (*deny_added)(PurpleAccount *account, const char *name);
73.58 - void (*deny_removed)(PurpleAccount *account, const char *name);
73.59 -
73.60 - void (*_purple_reserved1)(void);
73.61 - void (*_purple_reserved2)(void);
73.62 - void (*_purple_reserved3)(void);
73.63 - void (*_purple_reserved4)(void);
73.64 -} PurplePrivacyUiOps;
73.65 -
73.66 -/**
73.67 - * Adds a user to the account's permit list.
73.68 - *
73.69 - * @param account The account.
73.70 - * @param name The name of the user to add to the list.
73.71 - * @param local_only If TRUE, only the local list is updated, and not
73.72 - * the server.
73.73 - *
73.74 - * @return TRUE if the user was added successfully, or @c FALSE otherwise.
73.75 - */
73.76 -gboolean purple_privacy_permit_add(PurpleAccount *account, const char *name,
73.77 - gboolean local_only);
73.78 -
73.79 -/**
73.80 - * Removes a user from the account's permit list.
73.81 - *
73.82 - * @param account The account.
73.83 - * @param name The name of the user to add to the list.
73.84 - * @param local_only If TRUE, only the local list is updated, and not
73.85 - * the server.
73.86 - *
73.87 - * @return TRUE if the user was removed successfully, or @c FALSE otherwise.
73.88 - */
73.89 -gboolean purple_privacy_permit_remove(PurpleAccount *account, const char *name,
73.90 - gboolean local_only);
73.91 -
73.92 -/**
73.93 - * Adds a user to the account's deny list.
73.94 - *
73.95 - * @param account The account.
73.96 - * @param name The name of the user to add to the list.
73.97 - * @param local_only If TRUE, only the local list is updated, and not
73.98 - * the server.
73.99 - *
73.100 - * @return TRUE if the user was added successfully, or @c FALSE otherwise.
73.101 - */
73.102 -gboolean purple_privacy_deny_add(PurpleAccount *account, const char *name,
73.103 - gboolean local_only);
73.104 -
73.105 -/**
73.106 - * Removes a user from the account's deny list.
73.107 - *
73.108 - * @param account The account.
73.109 - * @param name The name of the user to add to the list.
73.110 - * @param local_only If TRUE, only the local list is updated, and not
73.111 - * the server.
73.112 - *
73.113 - * @return TRUE if the user was removed successfully, or @c FALSE otherwise.
73.114 - */
73.115 -gboolean purple_privacy_deny_remove(PurpleAccount *account, const char *name,
73.116 - gboolean local_only);
73.117 -
73.118 -/**
73.119 - * Allow a user to send messages. If current privacy setting for the account is:
73.120 - * PURPLE_PRIVACY_ALLOW_USERS: The user is added to the allow-list.
73.121 - * PURPLE_PRIVACY_DENY_USERS : The user is removed from the deny-list.
73.122 - * PURPLE_PRIVACY_ALLOW_ALL : No changes made.
73.123 - * PURPLE_PRIVACY_DENY_ALL : The privacy setting is changed to
73.124 - * PURPLE_PRIVACY_ALLOW_USERS and the user
73.125 - * is added to the allow-list.
73.126 - * PURPLE_PRIVACY_ALLOW_BUDDYLIST: No changes made if the user is already in
73.127 - * the buddy-list. Otherwise the setting is
73.128 - * changed to PURPLE_PRIVACY_ALLOW_USERS, all the
73.129 - * buddies are added to the allow-list, and the
73.130 - * user is also added to the allow-list.
73.131 - *
73.132 - * @param account The account.
73.133 - * @param who The name of the user.
73.134 - * @param local Whether the change is local-only.
73.135 - * @param restore Should the previous allow/deny list be restored if the
73.136 - * privacy setting is changed.
73.137 - */
73.138 -void purple_privacy_allow(PurpleAccount *account, const char *who, gboolean local,
73.139 - gboolean restore);
73.140 -
73.141 -/**
73.142 - * Block messages from a user. If current privacy setting for the account is:
73.143 - * PURPLE_PRIVACY_ALLOW_USERS: The user is removed from the allow-list.
73.144 - * PURPLE_PRIVACY_DENY_USERS : The user is added to the deny-list.
73.145 - * PURPLE_PRIVACY_DENY_ALL : No changes made.
73.146 - * PURPLE_PRIVACY_ALLOW_ALL : The privacy setting is changed to
73.147 - * PURPLE_PRIVACY_DENY_USERS and the user is
73.148 - * added to the deny-list.
73.149 - * PURPLE_PRIVACY_ALLOW_BUDDYLIST: If the user is not in the buddy-list,
73.150 - * then no changes made. Otherwise, the setting
73.151 - * is changed to PURPLE_PRIVACY_ALLOW_USERS, all
73.152 - * the buddies are added to the allow-list, and
73.153 - * this user is removed from the list.
73.154 - *
73.155 - * @param account The account.
73.156 - * @param who The name of the user.
73.157 - * @param local Whether the change is local-only.
73.158 - * @param restore Should the previous allow/deny list be restored if the
73.159 - * privacy setting is changed.
73.160 - */
73.161 -void purple_privacy_deny(PurpleAccount *account, const char *who, gboolean local,
73.162 - gboolean restore);
73.163 -
73.164 -/**
73.165 - * Check the privacy-setting for a user.
73.166 - *
73.167 - * @param account The account.
73.168 - * @param who The name of the user.
73.169 - *
73.170 - * @return @c FALSE if the specified account's privacy settings block the user or @c TRUE otherwise. The meaning of "block" is protocol-dependent and generally relates to status and/or sending of messages.
73.171 - */
73.172 -gboolean purple_privacy_check(PurpleAccount *account, const char *who);
73.173 -
73.174 -/**
73.175 - * Sets the UI operations structure for the privacy subsystem.
73.176 - *
73.177 - * @param ops The UI operations structure.
73.178 - */
73.179 -void purple_privacy_set_ui_ops(PurplePrivacyUiOps *ops);
73.180 -
73.181 -/**
73.182 - * Returns the UI operations structure for the privacy subsystem.
73.183 - *
73.184 - * @return The UI operations structure.
73.185 - */
73.186 -PurplePrivacyUiOps *purple_privacy_get_ui_ops(void);
73.187 -
73.188 -/**
73.189 - * Initializes the privacy subsystem.
73.190 - */
73.191 -void purple_privacy_init(void);
73.192 -
73.193 -#ifdef __cplusplus
73.194 -}
73.195 -#endif
73.196 -
73.197 -#endif /* _PURPLE_PRIVACY_H_ */
74.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/proxy.h Sun Jun 21 22:04:11 2009 -0400
74.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
74.3 @@ -1,301 +0,0 @@
74.4 -/**
74.5 - * @file proxy.h Proxy API
74.6 - * @ingroup core
74.7 - */
74.8 -
74.9 -/* purple
74.10 - *
74.11 - * Purple is the legal property of its developers, whose names are too numerous
74.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
74.13 - * source distribution.
74.14 - *
74.15 - * This program is free software; you can redistribute it and/or modify
74.16 - * it under the terms of the GNU General Public License as published by
74.17 - * the Free Software Foundation; either version 2 of the License, or
74.18 - * (at your option) any later version.
74.19 - *
74.20 - * This program is distributed in the hope that it will be useful,
74.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
74.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
74.23 - * GNU General Public License for more details.
74.24 - *
74.25 - * You should have received a copy of the GNU General Public License
74.26 - * along with this program; if not, write to the Free Software
74.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
74.28 - */
74.29 -#ifndef _PURPLE_PROXY_H_
74.30 -#define _PURPLE_PROXY_H_
74.31 -
74.32 -#include <glib.h>
74.33 -#include "eventloop.h"
74.34 -
74.35 -/**
74.36 - * A type of proxy connection.
74.37 - */
74.38 -typedef enum
74.39 -{
74.40 - PURPLE_PROXY_USE_GLOBAL = -1, /**< Use the global proxy information. */
74.41 - PURPLE_PROXY_NONE = 0, /**< No proxy. */
74.42 - PURPLE_PROXY_HTTP, /**< HTTP proxy. */
74.43 - PURPLE_PROXY_SOCKS4, /**< SOCKS 4 proxy. */
74.44 - PURPLE_PROXY_SOCKS5, /**< SOCKS 5 proxy. */
74.45 - PURPLE_PROXY_USE_ENVVAR /**< Use environmental settings. */
74.46 -
74.47 -} PurpleProxyType;
74.48 -
74.49 -/**
74.50 - * Information on proxy settings.
74.51 - */
74.52 -typedef struct
74.53 -{
74.54 - PurpleProxyType type; /**< The proxy type. */
74.55 -
74.56 - char *host; /**< The host. */
74.57 - int port; /**< The port number. */
74.58 - char *username; /**< The username. */
74.59 - char *password; /**< The password. */
74.60 -
74.61 -} PurpleProxyInfo;
74.62 -
74.63 -typedef struct _PurpleProxyConnectData PurpleProxyConnectData;
74.64 -
74.65 -typedef void (*PurpleProxyConnectFunction)(gpointer data, gint source, const gchar *error_message);
74.66 -
74.67 -
74.68 -#include "account.h"
74.69 -
74.70 -#ifdef __cplusplus
74.71 -extern "C" {
74.72 -#endif
74.73 -
74.74 -/**************************************************************************/
74.75 -/** @name Proxy structure API */
74.76 -/**************************************************************************/
74.77 -/*@{*/
74.78 -
74.79 -/**
74.80 - * Creates a proxy information structure.
74.81 - *
74.82 - * @return The proxy information structure.
74.83 - */
74.84 -PurpleProxyInfo *purple_proxy_info_new(void);
74.85 -
74.86 -/**
74.87 - * Destroys a proxy information structure.
74.88 - *
74.89 - * @param info The proxy information structure to destroy.
74.90 - */
74.91 -void purple_proxy_info_destroy(PurpleProxyInfo *info);
74.92 -
74.93 -/**
74.94 - * Sets the type of proxy.
74.95 - *
74.96 - * @param info The proxy information.
74.97 - * @param type The proxy type.
74.98 - */
74.99 -void purple_proxy_info_set_type(PurpleProxyInfo *info, PurpleProxyType type);
74.100 -
74.101 -/**
74.102 - * Sets the proxy host.
74.103 - *
74.104 - * @param info The proxy information.
74.105 - * @param host The host.
74.106 - */
74.107 -void purple_proxy_info_set_host(PurpleProxyInfo *info, const char *host);
74.108 -
74.109 -/**
74.110 - * Sets the proxy port.
74.111 - *
74.112 - * @param info The proxy information.
74.113 - * @param port The port.
74.114 - */
74.115 -void purple_proxy_info_set_port(PurpleProxyInfo *info, int port);
74.116 -
74.117 -/**
74.118 - * Sets the proxy username.
74.119 - *
74.120 - * @param info The proxy information.
74.121 - * @param username The username.
74.122 - */
74.123 -void purple_proxy_info_set_username(PurpleProxyInfo *info, const char *username);
74.124 -
74.125 -/**
74.126 - * Sets the proxy password.
74.127 - *
74.128 - * @param info The proxy information.
74.129 - * @param password The password.
74.130 - */
74.131 -void purple_proxy_info_set_password(PurpleProxyInfo *info, const char *password);
74.132 -
74.133 -/**
74.134 - * Returns the proxy's type.
74.135 - *
74.136 - * @param info The proxy information.
74.137 - *
74.138 - * @return The type.
74.139 - */
74.140 -PurpleProxyType purple_proxy_info_get_type(const PurpleProxyInfo *info);
74.141 -
74.142 -/**
74.143 - * Returns the proxy's host.
74.144 - *
74.145 - * @param info The proxy information.
74.146 - *
74.147 - * @return The host.
74.148 - */
74.149 -const char *purple_proxy_info_get_host(const PurpleProxyInfo *info);
74.150 -
74.151 -/**
74.152 - * Returns the proxy's port.
74.153 - *
74.154 - * @param info The proxy information.
74.155 - *
74.156 - * @return The port.
74.157 - */
74.158 -int purple_proxy_info_get_port(const PurpleProxyInfo *info);
74.159 -
74.160 -/**
74.161 - * Returns the proxy's username.
74.162 - *
74.163 - * @param info The proxy information.
74.164 - *
74.165 - * @return The username.
74.166 - */
74.167 -const char *purple_proxy_info_get_username(const PurpleProxyInfo *info);
74.168 -
74.169 -/**
74.170 - * Returns the proxy's password.
74.171 - *
74.172 - * @param info The proxy information.
74.173 - *
74.174 - * @return The password.
74.175 - */
74.176 -const char *purple_proxy_info_get_password(const PurpleProxyInfo *info);
74.177 -
74.178 -/*@}*/
74.179 -
74.180 -/**************************************************************************/
74.181 -/** @name Global Proxy API */
74.182 -/**************************************************************************/
74.183 -/*@{*/
74.184 -
74.185 -/**
74.186 - * Returns purple's global proxy information.
74.187 - *
74.188 - * @return The global proxy information.
74.189 - */
74.190 -PurpleProxyInfo *purple_global_proxy_get_info(void);
74.191 -
74.192 -/*@}*/
74.193 -
74.194 -/**************************************************************************/
74.195 -/** @name Proxy API */
74.196 -/**************************************************************************/
74.197 -/*@{*/
74.198 -
74.199 -/**
74.200 - * Returns the proxy subsystem handle.
74.201 - *
74.202 - * @return The proxy subsystem handle.
74.203 - */
74.204 -void *purple_proxy_get_handle(void);
74.205 -
74.206 -/**
74.207 - * Initializes the proxy subsystem.
74.208 - */
74.209 -void purple_proxy_init(void);
74.210 -
74.211 -/**
74.212 - * Uninitializes the proxy subsystem.
74.213 - */
74.214 -void purple_proxy_uninit(void);
74.215 -
74.216 -/**
74.217 - * Returns configuration of a proxy.
74.218 - *
74.219 - * @param account The account for which the configuration is needed.
74.220 - *
74.221 - * @return The configuration of a proxy.
74.222 - */
74.223 -PurpleProxyInfo *purple_proxy_get_setup(PurpleAccount *account);
74.224 -
74.225 -/**
74.226 - * Makes a connection to the specified host and port. Note that this
74.227 - * function name can be misleading--although it is called "proxy
74.228 - * connect," it is used for establishing any outgoing TCP connection,
74.229 - * whether through a proxy or not.
74.230 - *
74.231 - * @param handle A handle that should be associated with this
74.232 - * connection attempt. The handle can be used
74.233 - * to cancel the connection attempt using the
74.234 - * purple_proxy_connect_cancel_with_handle()
74.235 - * function.
74.236 - * @param account The account making the connection.
74.237 - * @param host The destination host.
74.238 - * @param port The destination port.
74.239 - * @param connect_cb The function to call when the connection is
74.240 - * established. If the connection failed then
74.241 - * fd will be -1 and error message will be set
74.242 - * to something descriptive (hopefully).
74.243 - * @param data User-defined data.
74.244 - *
74.245 - * @return NULL if there was an error, or a reference to an
74.246 - * opaque data structure that can be used to cancel
74.247 - * the pending connection, if needed.
74.248 - */
74.249 -PurpleProxyConnectData *purple_proxy_connect(void *handle,
74.250 - PurpleAccount *account,
74.251 - const char *host, int port,
74.252 - PurpleProxyConnectFunction connect_cb, gpointer data);
74.253 -
74.254 -/**
74.255 - * Makes a connection through a SOCKS5 proxy.
74.256 - *
74.257 - * @param handle A handle that should be associated with this
74.258 - * connection attempt. The handle can be used
74.259 - * to cancel the connection attempt using the
74.260 - * purple_proxy_connect_cancel_with_handle()
74.261 - * function.
74.262 - * @param gpi The PurpleProxyInfo specifying the proxy settings
74.263 - * @param host The destination host.
74.264 - * @param port The destination port.
74.265 - * @param connect_cb The function to call when the connection is
74.266 - * established. If the connection failed then
74.267 - * fd will be -1 and error message will be set
74.268 - * to something descriptive (hopefully).
74.269 - * @param data User-defined data.
74.270 - *
74.271 - * @return NULL if there was an error, or a reference to an
74.272 - * opaque data structure that can be used to cancel
74.273 - * the pending connection, if needed.
74.274 - */
74.275 -PurpleProxyConnectData *purple_proxy_connect_socks5(void *handle,
74.276 - PurpleProxyInfo *gpi,
74.277 - const char *host, int port,
74.278 - PurpleProxyConnectFunction connect_cb, gpointer data);
74.279 -
74.280 -/**
74.281 - * Cancel an in-progress connection attempt. This should be called
74.282 - * by the PRPL if the user disables an account while it is still
74.283 - * performing the initial sign on. Or when establishing a file
74.284 - * transfer, if we attempt to connect to a remote user but they
74.285 - * are behind a firewall then the PRPL can cancel the connection
74.286 - * attempt early rather than just letting the OS's TCP/IP stack
74.287 - * time-out the connection.
74.288 - */
74.289 -void purple_proxy_connect_cancel(PurpleProxyConnectData *connect_data);
74.290 -
74.291 -/*
74.292 - * Closes all proxy connections registered with the specified handle.
74.293 - *
74.294 - * @param handle The handle.
74.295 - */
74.296 -void purple_proxy_connect_cancel_with_handle(void *handle);
74.297 -
74.298 -/*@}*/
74.299 -
74.300 -#ifdef __cplusplus
74.301 -}
74.302 -#endif
74.303 -
74.304 -#endif /* _PURPLE_PROXY_H_ */
75.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/prpl.h Sun Jun 21 22:04:11 2009 -0400
75.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
75.3 @@ -1,761 +0,0 @@
75.4 -/**
75.5 - * @file prpl.h Protocol Plugin functions
75.6 - * @ingroup core
75.7 - */
75.8 -
75.9 -/* purple
75.10 - *
75.11 - * Purple is the legal property of its developers, whose names are too numerous
75.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
75.13 - * source distribution.
75.14 - *
75.15 - * This program is free software; you can redistribute it and/or modify
75.16 - * it under the terms of the GNU General Public License as published by
75.17 - * the Free Software Foundation; either version 2 of the License, or
75.18 - * (at your option) any later version.
75.19 - *
75.20 - * This program is distributed in the hope that it will be useful,
75.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
75.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
75.23 - * GNU General Public License for more details.
75.24 - *
75.25 - * You should have received a copy of the GNU General Public License
75.26 - * along with this program; if not, write to the Free Software
75.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
75.28 - */
75.29 -
75.30 -/* this file should be all that prpls need to include. therefore, by including
75.31 - * this file, they should get glib, proxy, purple_connection, prpl, etc. */
75.32 -
75.33 -#ifndef _PURPLE_PRPL_H_
75.34 -#define _PURPLE_PRPL_H_
75.35 -
75.36 -typedef struct _PurplePluginProtocolInfo PurplePluginProtocolInfo;
75.37 -/** @copydoc _PurpleAttentionType */
75.38 -typedef struct _PurpleAttentionType PurpleAttentionType;
75.39 -
75.40 -/**************************************************************************/
75.41 -/** @name Basic Protocol Information */
75.42 -/**************************************************************************/
75.43 -
75.44 -typedef enum {
75.45 - PURPLE_ICON_SCALE_DISPLAY = 0x01, /**< We scale the icon when we display it */
75.46 - PURPLE_ICON_SCALE_SEND = 0x02 /**< We scale the icon before we send it to the server */
75.47 -} PurpleIconScaleRules;
75.48 -
75.49 -
75.50 -/**
75.51 - * A description of a Buddy Icon specification. This tells Purple what kind of image file
75.52 - * it should give this prpl, and what kind of image file it should expect back.
75.53 - * Dimensions less than 1 should be ignored and the image not scaled.
75.54 - */
75.55 -typedef struct _PurpleBuddyIconSpec PurpleBuddyIconSpec;
75.56 -
75.57 -/**
75.58 - * This \#define exists just to make it easier to fill out the buddy icon
75.59 - * field in the prpl info struct for protocols that couldn't care less.
75.60 - */
75.61 -#define NO_BUDDY_ICONS {NULL, 0, 0, 0, 0, 0, 0}
75.62 -
75.63 -#ifdef HAVE_UNISTD_H
75.64 -#include <unistd.h>
75.65 -#endif
75.66 -
75.67 -#include "blist.h"
75.68 -#include "conversation.h"
75.69 -#include "ft.h"
75.70 -#include "imgstore.h"
75.71 -#include "notify.h"
75.72 -#include "proxy.h"
75.73 -#include "plugin.h"
75.74 -#include "roomlist.h"
75.75 -#include "status.h"
75.76 -#include "whiteboard.h"
75.77 -
75.78 -
75.79 -/** @copydoc PurpleBuddyIconSpec */
75.80 -struct _PurpleBuddyIconSpec {
75.81 - /** This is a comma-delimited list of image formats or @c NULL if icons
75.82 - * are not supported. Neither the core nor the prpl will actually
75.83 - * check to see if the data it's given matches this; it's entirely up
75.84 - * to the UI to do what it wants
75.85 - */
75.86 - char *format;
75.87 -
75.88 - int min_width; /**< Minimum width of this icon */
75.89 - int min_height; /**< Minimum height of this icon */
75.90 - int max_width; /**< Maximum width of this icon */
75.91 - int max_height; /**< Maximum height of this icon */
75.92 - size_t max_filesize; /**< Maximum size in bytes */
75.93 - PurpleIconScaleRules scale_rules; /**< How to stretch this icon */
75.94 -};
75.95 -
75.96 -struct proto_chat_entry {
75.97 - const char *label;
75.98 - const char *identifier;
75.99 - gboolean required;
75.100 - gboolean is_int;
75.101 - int min;
75.102 - int max;
75.103 - gboolean secret;
75.104 -};
75.105 -
75.106 -/** Represents "nudges" and "buzzes" that you may send to a buddy to attract
75.107 - * their attention (or vice-versa).
75.108 - */
75.109 -struct _PurpleAttentionType
75.110 -{
75.111 - const char *name; /**< Shown in GUI elements */
75.112 - const char *incoming_description; /**< Shown when sent */
75.113 - const char *outgoing_description; /**< Shown when receied */
75.114 - const char *icon_name; /**< Icon to display (optional) */
75.115 - const char *unlocalized_name; /**< Unlocalized name for UIs needing it */
75.116 -
75.117 - /* Reserved fields for future purposes */
75.118 - gpointer _reserved2;
75.119 - gpointer _reserved3;
75.120 - gpointer _reserved4;
75.121 -};
75.122 -
75.123 -/**
75.124 - * Protocol options
75.125 - *
75.126 - * These should all be stuff that some plugins can do and others can't.
75.127 - */
75.128 -typedef enum
75.129 -{
75.130 - /**
75.131 - * Use a unique name, not an alias, for chat rooms.
75.132 - *
75.133 - * XMPP lets you choose what name you want for chat.
75.134 - * So it shouldn't be pulling the alias for when you're in chat;
75.135 - * it gets annoying.
75.136 - */
75.137 - OPT_PROTO_UNIQUE_CHATNAME = 0x00000004,
75.138 -
75.139 - /**
75.140 - * Chat rooms have topics.
75.141 - *
75.142 - * IRC and XMPP support this.
75.143 - */
75.144 - OPT_PROTO_CHAT_TOPIC = 0x00000008,
75.145 -
75.146 - /**
75.147 - * Don't require passwords for sign-in.
75.148 - *
75.149 - * Zephyr doesn't require passwords, so there's no
75.150 - * need for a password prompt.
75.151 - */
75.152 - OPT_PROTO_NO_PASSWORD = 0x00000010,
75.153 -
75.154 - /**
75.155 - * Notify on new mail.
75.156 - *
75.157 - * MSN and Yahoo notify you when you have new mail.
75.158 - */
75.159 - OPT_PROTO_MAIL_CHECK = 0x00000020,
75.160 -
75.161 - /**
75.162 - * Images in IMs.
75.163 - *
75.164 - * Oscar lets you send images in direct IMs.
75.165 - */
75.166 - OPT_PROTO_IM_IMAGE = 0x00000040,
75.167 -
75.168 - /**
75.169 - * Allow passwords to be optional.
75.170 - *
75.171 - * Passwords in IRC are optional, and are needed for certain
75.172 - * functionality.
75.173 - */
75.174 - OPT_PROTO_PASSWORD_OPTIONAL = 0x00000080,
75.175 -
75.176 - /**
75.177 - * Allows font size to be specified in sane point size
75.178 - *
75.179 - * Probably just XMPP and Y!M
75.180 - */
75.181 - OPT_PROTO_USE_POINTSIZE = 0x00000100,
75.182 -
75.183 - /**
75.184 - * Set the Register button active when screenname is not given.
75.185 - *
75.186 - * Gadu-Gadu doesn't need a screenname to register new account.
75.187 - */
75.188 - OPT_PROTO_REGISTER_NOSCREENNAME = 0x00000200,
75.189 -
75.190 - /**
75.191 - * Indicates that slash commands are native to this protocol.
75.192 - * Used as a hint that unknown commands should not be sent as messages.
75.193 - * @since 2.1.0
75.194 - */
75.195 - OPT_PROTO_SLASH_COMMANDS_NATIVE = 0x00000400
75.196 -
75.197 -} PurpleProtocolOptions;
75.198 -
75.199 -/**
75.200 - * A protocol plugin information structure.
75.201 - *
75.202 - * Every protocol plugin initializes this structure. It is the gateway
75.203 - * between purple and the protocol plugin. Many of these callbacks can be
75.204 - * NULL. If a callback must be implemented, it has a comment indicating so.
75.205 - */
75.206 -struct _PurplePluginProtocolInfo
75.207 -{
75.208 - PurpleProtocolOptions options; /**< Protocol options. */
75.209 -
75.210 - GList *user_splits; /**< A GList of PurpleAccountUserSplit */
75.211 - GList *protocol_options; /**< A GList of PurpleAccountOption */
75.212 -
75.213 - PurpleBuddyIconSpec icon_spec; /**< The icon spec. */
75.214 -
75.215 - /**
75.216 - * Returns the base icon name for the given buddy and account.
75.217 - * If buddy is NULL and the account is non-NULL, it will return the
75.218 - * name to use for the account's icon. If both are NULL, it will
75.219 - * return the name to use for the protocol's icon.
75.220 - *
75.221 - * This must be implemented.
75.222 - */
75.223 - const char *(*list_icon)(PurpleAccount *account, PurpleBuddy *buddy);
75.224 -
75.225 - /**
75.226 - * Fills the four char**'s with string identifiers for "emblems"
75.227 - * that the UI will interpret and display as relevant
75.228 - */
75.229 - const char *(*list_emblem)(PurpleBuddy *buddy);
75.230 -
75.231 - /**
75.232 - * Gets a short string representing this buddy's status. This will
75.233 - * be shown on the buddy list.
75.234 - */
75.235 - char *(*status_text)(PurpleBuddy *buddy);
75.236 -
75.237 - /**
75.238 - * Allows the prpl to add text to a buddy's tooltip.
75.239 - */
75.240 - void (*tooltip_text)(PurpleBuddy *buddy, PurpleNotifyUserInfo *user_info, gboolean full);
75.241 -
75.242 - /**
75.243 - * Returns a list of #PurpleStatusType which exist for this account;
75.244 - * this must be implemented, and must add at least the offline and
75.245 - * online states.
75.246 - */
75.247 - GList *(*status_types)(PurpleAccount *account);
75.248 -
75.249 - /**
75.250 - * Returns a list of #PurpleMenuAction structs, which represent extra
75.251 - * actions to be shown in (for example) the right-click menu for @a
75.252 - * node.
75.253 - */
75.254 - GList *(*blist_node_menu)(PurpleBlistNode *node);
75.255 - GList *(*chat_info)(PurpleConnection *);
75.256 - GHashTable *(*chat_info_defaults)(PurpleConnection *, const char *chat_name);
75.257 -
75.258 - /* All the server-related functions */
75.259 -
75.260 - /** This must be implemented. */
75.261 - void (*login)(PurpleAccount *);
75.262 -
75.263 - /** This must be implemented. */
75.264 - void (*close)(PurpleConnection *);
75.265 -
75.266 - /**
75.267 - * This PRPL function should return a positive value on success.
75.268 - * If the message is too big to be sent, return -E2BIG. If
75.269 - * the account is not connected, return -ENOTCONN. If the
75.270 - * PRPL is unable to send the message for another reason, return
75.271 - * some other negative value. You can use one of the valid
75.272 - * errno values, or just big something. If the message should
75.273 - * not be echoed to the conversation window, return 0.
75.274 - */
75.275 - int (*send_im)(PurpleConnection *, const char *who,
75.276 - const char *message,
75.277 - PurpleMessageFlags flags);
75.278 -
75.279 - void (*set_info)(PurpleConnection *, const char *info);
75.280 -
75.281 - /**
75.282 - * @return If this protocol requires the PURPLE_TYPING message to
75.283 - * be sent repeatedly to signify that the user is still
75.284 - * typing, then the PRPL should return the number of
75.285 - * seconds to wait before sending a subsequent notification.
75.286 - * Otherwise the PRPL should return 0.
75.287 - */
75.288 - unsigned int (*send_typing)(PurpleConnection *, const char *name, PurpleTypingState state);
75.289 -
75.290 - /**
75.291 - * Should arrange for purple_notify_userinfo() to be called with
75.292 - * @a who's user info.
75.293 - */
75.294 - void (*get_info)(PurpleConnection *, const char *who);
75.295 - void (*set_status)(PurpleAccount *account, PurpleStatus *status);
75.296 -
75.297 - void (*set_idle)(PurpleConnection *, int idletime);
75.298 - void (*change_passwd)(PurpleConnection *, const char *old_pass,
75.299 - const char *new_pass);
75.300 - void (*add_buddy)(PurpleConnection *, PurpleBuddy *buddy, PurpleGroup *group);
75.301 - void (*add_buddies)(PurpleConnection *, GList *buddies, GList *groups);
75.302 - void (*remove_buddy)(PurpleConnection *, PurpleBuddy *buddy, PurpleGroup *group);
75.303 - void (*remove_buddies)(PurpleConnection *, GList *buddies, GList *groups);
75.304 - void (*add_permit)(PurpleConnection *, const char *name);
75.305 - void (*add_deny)(PurpleConnection *, const char *name);
75.306 - void (*rem_permit)(PurpleConnection *, const char *name);
75.307 - void (*rem_deny)(PurpleConnection *, const char *name);
75.308 - void (*set_permit_deny)(PurpleConnection *);
75.309 - void (*join_chat)(PurpleConnection *, GHashTable *components);
75.310 - void (*reject_chat)(PurpleConnection *, GHashTable *components);
75.311 - char *(*get_chat_name)(GHashTable *components);
75.312 - void (*chat_invite)(PurpleConnection *, int id,
75.313 - const char *message, const char *who);
75.314 - void (*chat_leave)(PurpleConnection *, int id);
75.315 - void (*chat_whisper)(PurpleConnection *, int id,
75.316 - const char *who, const char *message);
75.317 - int (*chat_send)(PurpleConnection *, int id, const char *message, PurpleMessageFlags flags);
75.318 -
75.319 - /** If implemented, this will be called regularly for this prpl's
75.320 - * active connections. You'd want to do this if you need to repeatedly
75.321 - * send some kind of keepalive packet to the server to avoid being
75.322 - * disconnected. ("Regularly" is defined by
75.323 - * <code>KEEPALIVE_INTERVAL</code> in <tt>libpurple/connection.c</tt>.)
75.324 - */
75.325 - void (*keepalive)(PurpleConnection *);
75.326 -
75.327 - /** new user registration */
75.328 - void (*register_user)(PurpleAccount *);
75.329 -
75.330 - /**
75.331 - * @deprecated Use #PurplePluginProtocolInfo.get_info instead.
75.332 - */
75.333 - void (*get_cb_info)(PurpleConnection *, int, const char *who);
75.334 - /**
75.335 - * @deprecated Use #PurplePluginProtocolInfo.get_cb_real_name and
75.336 - * #PurplePluginProtocolInfo.status_text instead.
75.337 - */
75.338 - void (*get_cb_away)(PurpleConnection *, int, const char *who);
75.339 -
75.340 - /** save/store buddy's alias on server list/roster */
75.341 - void (*alias_buddy)(PurpleConnection *, const char *who,
75.342 - const char *alias);
75.343 -
75.344 - /** change a buddy's group on a server list/roster */
75.345 - void (*group_buddy)(PurpleConnection *, const char *who,
75.346 - const char *old_group, const char *new_group);
75.347 -
75.348 - /** rename a group on a server list/roster */
75.349 - void (*rename_group)(PurpleConnection *, const char *old_name,
75.350 - PurpleGroup *group, GList *moved_buddies);
75.351 -
75.352 - void (*buddy_free)(PurpleBuddy *);
75.353 -
75.354 - void (*convo_closed)(PurpleConnection *, const char *who);
75.355 -
75.356 - /**
75.357 - * Convert the username @a who to its canonical form. (For example,
75.358 - * AIM treats "fOo BaR" and "foobar" as the same user; this function
75.359 - * should return the same normalized string for both of those.)
75.360 - */
75.361 - const char *(*normalize)(const PurpleAccount *, const char *who);
75.362 -
75.363 - /**
75.364 - * Set the buddy icon for the given connection to @a img. The prpl
75.365 - * does NOT own a reference to @a img; if it needs one, it must
75.366 - * #purple_imgstore_ref(@a img) itself.
75.367 - */
75.368 - void (*set_buddy_icon)(PurpleConnection *, PurpleStoredImage *img);
75.369 -
75.370 - void (*remove_group)(PurpleConnection *gc, PurpleGroup *group);
75.371 -
75.372 - /** Gets the real name of a participant in a chat. For example, on
75.373 - * XMPP this turns a chat room nick <tt>foo</tt> into
75.374 - * <tt>room\@server/foo</tt>
75.375 - * @param gc the connection on which the room is.
75.376 - * @param id the ID of the chat room.
75.377 - * @param who the nickname of the chat participant.
75.378 - * @return the real name of the participant. This string must be
75.379 - * freed by the caller.
75.380 - */
75.381 - char *(*get_cb_real_name)(PurpleConnection *gc, int id, const char *who);
75.382 -
75.383 - void (*set_chat_topic)(PurpleConnection *gc, int id, const char *topic);
75.384 -
75.385 - PurpleChat *(*find_blist_chat)(PurpleAccount *account, const char *name);
75.386 -
75.387 - /* room listing prpl callbacks */
75.388 - PurpleRoomlist *(*roomlist_get_list)(PurpleConnection *gc);
75.389 - void (*roomlist_cancel)(PurpleRoomlist *list);
75.390 - void (*roomlist_expand_category)(PurpleRoomlist *list, PurpleRoomlistRoom *category);
75.391 -
75.392 - /* file transfer callbacks */
75.393 - gboolean (*can_receive_file)(PurpleConnection *, const char *who);
75.394 - void (*send_file)(PurpleConnection *, const char *who, const char *filename);
75.395 - PurpleXfer *(*new_xfer)(PurpleConnection *, const char *who);
75.396 -
75.397 - /** Checks whether offline messages to @a buddy are supported.
75.398 - * @return @c TRUE if @a buddy can be sent messages while they are
75.399 - * offline, or @c FALSE if not.
75.400 - */
75.401 - gboolean (*offline_message)(const PurpleBuddy *buddy);
75.402 -
75.403 - PurpleWhiteboardPrplOps *whiteboard_prpl_ops;
75.404 -
75.405 - /** For use in plugins that may understand the underlying protocol */
75.406 - int (*send_raw)(PurpleConnection *gc, const char *buf, int len);
75.407 -
75.408 - /* room list serialize */
75.409 - char *(*roomlist_room_serialize)(PurpleRoomlistRoom *room);
75.410 -
75.411 - /** Remove the user from the server. The account can either be
75.412 - * connected or disconnected. After the removal is finished, the
75.413 - * connection will stay open and has to be closed!
75.414 - */
75.415 - /* This is here rather than next to register_user for API compatibility
75.416 - * reasons.
75.417 - */
75.418 - void (*unregister_user)(PurpleAccount *, PurpleAccountUnregistrationCb cb, void *user_data);
75.419 -
75.420 - /* Attention API for sending & receiving zaps/nudges/buzzes etc. */
75.421 - gboolean (*send_attention)(PurpleConnection *gc, const char *username, guint type);
75.422 - GList *(*get_attention_types)(PurpleAccount *acct);
75.423 -
75.424 - /**
75.425 - * The size of the PurplePluginProtocolInfo. This should always be sizeof(PurplePluginProtocolInfo).
75.426 - * This allows adding more functions to this struct without requiring a major version bump.
75.427 - */
75.428 - unsigned long struct_size;
75.429 -
75.430 - /* NOTE:
75.431 - * If more functions are added, they should accessed using the following syntax:
75.432 - *
75.433 - * if (PURPLE_PROTOCOL_PLUGIN_HAS_FUNC(prpl, new_function))
75.434 - * prpl->new_function(...);
75.435 - *
75.436 - * instead of
75.437 - *
75.438 - * if (prpl->new_function != NULL)
75.439 - * prpl->new_function(...);
75.440 - *
75.441 - * The PURPLE_PROTOCOL_PLUGIN_HAS_FUNC macro can be used for the older member
75.442 - * functions (e.g. login, send_im etc.) too.
75.443 - */
75.444 -
75.445 - /** This allows protocols to specify additional strings to be used for
75.446 - * various purposes. The idea is to stuff a bunch of strings in this hash
75.447 - * table instead of expanding the struct for every addition. This hash
75.448 - * table is allocated every call and MUST be unrefed by the caller.
75.449 - *
75.450 - * @param account The account to specify. This can be NULL.
75.451 - * @return The protocol's string hash table. The hash table should be
75.452 - * destroyed by the caller when it's no longer needed.
75.453 - */
75.454 - GHashTable *(*get_account_text_table)(PurpleAccount *account);
75.455 -};
75.456 -
75.457 -#define PURPLE_PROTOCOL_PLUGIN_HAS_FUNC(prpl, member) \
75.458 - (((G_STRUCT_OFFSET(PurplePluginProtocolInfo, member) < G_STRUCT_OFFSET(PurplePluginProtocolInfo, struct_size)) \
75.459 - || (G_STRUCT_OFFSET(PurplePluginProtocolInfo, member) < prpl->struct_size)) && \
75.460 - prpl->member != NULL)
75.461 -
75.462 -
75.463 -#define PURPLE_IS_PROTOCOL_PLUGIN(plugin) \
75.464 - ((plugin)->info->type == PURPLE_PLUGIN_PROTOCOL)
75.465 -
75.466 -#define PURPLE_PLUGIN_PROTOCOL_INFO(plugin) \
75.467 - ((PurplePluginProtocolInfo *)(plugin)->info->extra_info)
75.468 -
75.469 -#ifdef __cplusplus
75.470 -extern "C" {
75.471 -#endif
75.472 -
75.473 -/**************************************************************************/
75.474 -/** @name Attention Type API */
75.475 -/**************************************************************************/
75.476 -/*@{*/
75.477 -
75.478 -/**
75.479 - * Creates a new #PurpleAttentionType object and sets its mandatory parameters.
75.480 - *
75.481 - * @param ulname A non-localized string that can be used by UIs in need of such
75.482 - * non-localized strings. This should be the same as @a name,
75.483 - * without localization.
75.484 - * @param name A localized string that the UI may display for the event. This
75.485 - * should be the same string as @a ulname, with localization.
75.486 - * @param inc_desc A localized description shown when the event is received.
75.487 - * @param out_desc A localized description shown when the event is sent.
75.488 - * @return A pointer to the new object.
75.489 - * @since 2.4.0
75.490 - */
75.491 -PurpleAttentionType *purple_attention_type_new(const char *ulname, const char *name,
75.492 - const char *inc_desc, const char *out_desc);
75.493 -
75.494 -/**
75.495 - * Sets the displayed name of the attention-demanding event.
75.496 - *
75.497 - * @param type The attention type.
75.498 - * @param name The localized name that will be displayed by UIs. This should be
75.499 - * the same string given as the unlocalized name, but with
75.500 - * localization.
75.501 - * @since 2.4.0
75.502 - */
75.503 -void purple_attention_type_set_name(PurpleAttentionType *type, const char *name);
75.504 -
75.505 -/**
75.506 - * Sets the description of the attention-demanding event shown in conversations
75.507 - * when the event is received.
75.508 - *
75.509 - * @param type The attention type.
75.510 - * @param desc The localized description for incoming events.
75.511 - * @since 2.4.0
75.512 - */
75.513 -void purple_attention_type_set_incoming_desc(PurpleAttentionType *type, const char *desc);
75.514 -
75.515 -/**
75.516 - * Sets the description of the attention-demanding event shown in conversations
75.517 - * when the event is sent.
75.518 - *
75.519 - * @param type The attention type.
75.520 - * @param desc The localized description for outgoing events.
75.521 - * @since 2.4.0
75.522 - */
75.523 -void purple_attention_type_set_outgoing_desc(PurpleAttentionType *type, const char *desc);
75.524 -
75.525 -/**
75.526 - * Sets the name of the icon to display for the attention event; this is optional.
75.527 - *
75.528 - * @param type The attention type.
75.529 - * @param name The icon's name.
75.530 - * @note Icons are optional for attention events.
75.531 - * @since 2.4.0
75.532 - */
75.533 -void purple_attention_type_set_icon_name(PurpleAttentionType *type, const char *name);
75.534 -
75.535 -/**
75.536 - * Sets the unlocalized name of the attention event; some UIs may need this,
75.537 - * thus it is required.
75.538 - *
75.539 - * @param type The attention type.
75.540 - * @param ulname The unlocalized name. This should be the same string given as
75.541 - * the localized name, but without localization.
75.542 - * @since 2.4.0
75.543 - */
75.544 -void purple_attention_type_set_unlocalized_name(PurpleAttentionType *type, const char *ulname);
75.545 -
75.546 -/**
75.547 - * Get the attention type's name as displayed by the UI.
75.548 - *
75.549 - * @param type The attention type.
75.550 - * @return The name.
75.551 - * @since 2.4.0
75.552 - */
75.553 -const char *purple_attention_type_get_name(const PurpleAttentionType *type);
75.554 -
75.555 -/**
75.556 - * Get the attention type's description shown when the event is received.
75.557 - *
75.558 - * @param type The attention type.
75.559 - * @return The description.
75.560 - * @since 2.4.0
75.561 - */
75.562 -const char *purple_attention_type_get_incoming_desc(const PurpleAttentionType *type);
75.563 -
75.564 -/**
75.565 - * Get the attention type's description shown when the event is sent.
75.566 - *
75.567 - * @param type The attention type.
75.568 - * @return The description.
75.569 - * @since 2.4.0
75.570 - */
75.571 -const char *purple_attention_type_get_outgoing_desc(const PurpleAttentionType *type);
75.572 -
75.573 -/**
75.574 - * Get the attention type's icon name.
75.575 - *
75.576 - * @param type The attention type.
75.577 - * @return The icon name or @c NULL if unset/empty.
75.578 - * @note Icons are optional for attention events.
75.579 - * @since 2.4.0
75.580 - */
75.581 -const char *purple_attention_type_get_icon_name(const PurpleAttentionType *type);
75.582 -
75.583 -/**
75.584 - * Get the attention type's unlocalized name; this is useful for some UIs.
75.585 - *
75.586 - * @param type The attention type
75.587 - * @return The unlocalized name.
75.588 - * @since 2.4.0
75.589 - */
75.590 -const char *purple_attention_type_get_unlocalized_name(const PurpleAttentionType *type);
75.591 -
75.592 -/*@}*/
75.593 -
75.594 -/**************************************************************************/
75.595 -/** @name Protocol Plugin API */
75.596 -/**************************************************************************/
75.597 -/*@{*/
75.598 -
75.599 -/**
75.600 - * Notifies Purple that an account's idle state and time have changed.
75.601 - *
75.602 - * This is meant to be called from protocol plugins.
75.603 - *
75.604 - * @param account The account.
75.605 - * @param idle The user's idle state.
75.606 - * @param idle_time The user's idle time.
75.607 - */
75.608 -void purple_prpl_got_account_idle(PurpleAccount *account, gboolean idle,
75.609 - time_t idle_time);
75.610 -
75.611 -/**
75.612 - * Notifies Purple of an account's log-in time.
75.613 - *
75.614 - * This is meant to be called from protocol plugins.
75.615 - *
75.616 - * @param account The account the user is on.
75.617 - * @param login_time The user's log-in time.
75.618 - */
75.619 -void purple_prpl_got_account_login_time(PurpleAccount *account, time_t login_time);
75.620 -
75.621 -/**
75.622 - * Notifies Purple that an account's status has changed.
75.623 - *
75.624 - * This is meant to be called from protocol plugins.
75.625 - *
75.626 - * @param account The account the user is on.
75.627 - * @param status_id The status ID.
75.628 - * @param ... A NULL-terminated list of attribute IDs and values,
75.629 - * beginning with the value for @a attr_id.
75.630 - */
75.631 -void purple_prpl_got_account_status(PurpleAccount *account,
75.632 - const char *status_id, ...) G_GNUC_NULL_TERMINATED;
75.633 -/**
75.634 - * Notifies Purple that a user's idle state and time have changed.
75.635 - *
75.636 - * This is meant to be called from protocol plugins.
75.637 - *
75.638 - * @param account The account the user is on.
75.639 - * @param name The screen name of the user.
75.640 - * @param idle The user's idle state.
75.641 - * @param idle_time The user's idle time. This is the time at
75.642 - * which the user became idle, in seconds since
75.643 - * the epoch. If the PRPL does not know this value
75.644 - * then it should pass 0.
75.645 - */
75.646 -void purple_prpl_got_user_idle(PurpleAccount *account, const char *name,
75.647 - gboolean idle, time_t idle_time);
75.648 -
75.649 -/**
75.650 - * Notifies Purple of a user's log-in time.
75.651 - *
75.652 - * This is meant to be called from protocol plugins.
75.653 - *
75.654 - * @param account The account the user is on.
75.655 - * @param name The screen name of the user.
75.656 - * @param login_time The user's log-in time.
75.657 - */
75.658 -void purple_prpl_got_user_login_time(PurpleAccount *account, const char *name,
75.659 - time_t login_time);
75.660 -
75.661 -/**
75.662 - * Notifies Purple that a user's status has been activated.
75.663 - *
75.664 - * This is meant to be called from protocol plugins.
75.665 - *
75.666 - * @param account The account the user is on.
75.667 - * @param name The screen name of the user.
75.668 - * @param status_id The status ID.
75.669 - * @param ... A NULL-terminated list of attribute IDs and values,
75.670 - * beginning with the value for @a attr_id.
75.671 - */
75.672 -void purple_prpl_got_user_status(PurpleAccount *account, const char *name,
75.673 - const char *status_id, ...) G_GNUC_NULL_TERMINATED;
75.674 -
75.675 -/**
75.676 - * Notifies libpurple that a user's status has been deactivated
75.677 - *
75.678 - * This is meant to be called from protocol plugins.
75.679 - *
75.680 - * @param account The account the user is on.
75.681 - * @param name The screen name of the user.
75.682 - * @param status_id The status ID.
75.683 - */
75.684 -void purple_prpl_got_user_status_deactive(PurpleAccount *account, const char *name,
75.685 - const char *status_id);
75.686 -
75.687 -/**
75.688 - * Informs the server that an account's status changed.
75.689 - *
75.690 - * @param account The account the user is on.
75.691 - * @param old_status The previous status.
75.692 - * @param new_status The status that was activated, or deactivated
75.693 - * (in the case of independent statuses).
75.694 - */
75.695 -void purple_prpl_change_account_status(PurpleAccount *account,
75.696 - PurpleStatus *old_status,
75.697 - PurpleStatus *new_status);
75.698 -
75.699 -/**
75.700 - * Retrieves the list of stock status types from a prpl.
75.701 - *
75.702 - * @param account The account the user is on.
75.703 - * @param presence The presence for which we're going to get statuses
75.704 - *
75.705 - * @return List of statuses
75.706 - */
75.707 -GList *purple_prpl_get_statuses(PurpleAccount *account, PurplePresence *presence);
75.708 -
75.709 -/** Send an attention request message.
75.710 - *
75.711 - * @param gc The connection to send the message on.
75.712 - * @param who Whose attention to request.
75.713 - * @param type_code An index into the prpl's attention_types list determining the type
75.714 - * of the attention request command to send. 0 if prpl only defines one
75.715 - * (for example, Yahoo and MSN), but some protocols define more (MySpaceIM).
75.716 - *
75.717 - * Note that you can't send arbitrary PurpleAttentionType's, because there is
75.718 - * only a fixed set of attention commands.
75.719 - * @since 2.5.0
75.720 - */
75.721 -void purple_prpl_send_attention(PurpleConnection *gc, const char *who, guint type_code);
75.722 -
75.723 -/** Process an incoming attention message.
75.724 - *
75.725 - * @param gc The connection that received the attention message.
75.726 - * @param who Who requested your attention.
75.727 - * @param type_code An index into the prpl's attention_types list determining the type
75.728 - * of the attention request command to send.
75.729 - * @since 2.5.0
75.730 - */
75.731 -void purple_prpl_got_attention(PurpleConnection *gc, const char *who, guint type_code);
75.732 -
75.733 -/** Process an incoming attention message in a chat.
75.734 - *
75.735 - * @param gc The connection that received the attention message.
75.736 - * @param id The chat id.
75.737 - * @param who Who requested your attention.
75.738 - * @param type_code An index into the prpl's attention_types list determining the type
75.739 - * of the attention request command to send.
75.740 - * @since 2.5.0
75.741 - */
75.742 -void purple_prpl_got_attention_in_chat(PurpleConnection *gc, int id, const char *who, guint type_code);
75.743 -
75.744 -/*@}*/
75.745 -
75.746 -/**************************************************************************/
75.747 -/** @name Protocol Plugin Subsystem API */
75.748 -/**************************************************************************/
75.749 -/*@{*/
75.750 -
75.751 -/**
75.752 - * Finds a protocol plugin structure of the specified type.
75.753 - *
75.754 - * @param id The protocol plugin;
75.755 - */
75.756 -PurplePlugin *purple_find_prpl(const char *id);
75.757 -
75.758 -/*@}*/
75.759 -
75.760 -#ifdef __cplusplus
75.761 -}
75.762 -#endif
75.763 -
75.764 -#endif /* _PRPL_H_ */
76.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/purple.h Sun Jun 21 22:04:11 2009 -0400
76.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
76.3 @@ -1,97 +0,0 @@
76.4 -/**
76.5 - * @file purple.h Header files and defines
76.6 - * This file contains all the necessary preprocessor directives to include
76.7 - * libpurple's headers and other preprocessor directives required for plugins
76.8 - * or UIs to build. Including this file eliminates the need to directly
76.9 - * include any other libpurple files.
76.10 - *
76.11 - * @ingroup core libpurple
76.12 - * @since 2.3.0
76.13 - */
76.14 -
76.15 -/* purple
76.16 - *
76.17 - * Purple is the legal property of its developers, whose names are too numerous
76.18 - * to list here. Please refer to the COPYRIGHT file distributed with this
76.19 - * source distribution.
76.20 - *
76.21 - * This program is free software; you can redistribute it and/or modify
76.22 - * it under the terms of the GNU General Public License as published by
76.23 - * the Free Software Foundation; either version 2 of the License, or
76.24 - * (at your option) any later version.
76.25 - *
76.26 - * This program is distributed in the hope that it will be useful,
76.27 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
76.28 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
76.29 - * GNU General Public License for more details.
76.30 - *
76.31 - * You should have received a copy of the GNU General Public License
76.32 - * along with this program; if not, write to the Free Software
76.33 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
76.34 - */
76.35 -
76.36 -#ifndef _PURPLE_PURPLE_H_
76.37 -#define _PURPLE_PURPLE_H_
76.38 -
76.39 -#include <glib.h>
76.40 -
76.41 -#ifndef G_GNUC_NULL_TERMINATED
76.42 -# if __GNUC__ >= 4
76.43 -# define G_GNUC_NULL_TERMINATED __attribute__((__sentinel__))
76.44 -# else
76.45 -# define G_GNUC_NULL_TERMINATED
76.46 -# endif
76.47 -#endif
76.48 -
76.49 -#undef PURPLE_PLUGINS
76.50 -
76.51 -#include <account.h>
76.52 -#include <accountopt.h>
76.53 -#include <blist.h>
76.54 -#include <buddyicon.h>
76.55 -#include <certificate.h>
76.56 -#include <cipher.h>
76.57 -#include <circbuffer.h>
76.58 -#include <cmds.h>
76.59 -#include <connection.h>
76.60 -#include <conversation.h>
76.61 -#include <core.h>
76.62 -#include <debug.h>
76.63 -#include <desktopitem.h>
76.64 -#include <dnsquery.h>
76.65 -#include <dnssrv.h>
76.66 -#include <eventloop.h>
76.67 -#include <ft.h>
76.68 -#include <idle.h>
76.69 -#include <imgstore.h>
76.70 -#include <log.h>
76.71 -#include <mime.h>
76.72 -#include <nat-pmp.h>
76.73 -#include <network.h>
76.74 -#include <ntlm.h>
76.75 -#include <notify.h>
76.76 -#include <plugin.h>
76.77 -#include <pluginpref.h>
76.78 -#include <pounce.h>
76.79 -#include <prefs.h>
76.80 -#include <privacy.h>
76.81 -#include <proxy.h>
76.82 -#include <prpl.h>
76.83 -#include <request.h>
76.84 -#include <roomlist.h>
76.85 -#include <savedstatuses.h>
76.86 -#include <server.h>
76.87 -#include <signals.h>
76.88 -#include <status.h>
76.89 -#include <stringref.h>
76.90 -#include <stun.h>
76.91 -#include <sound.h>
76.92 -#include <sslconn.h>
76.93 -#include <upnp.h>
76.94 -#include <util.h>
76.95 -#include <value.h>
76.96 -#include <version.h>
76.97 -#include <xmlnode.h>
76.98 -#include <whiteboard.h>
76.99 -
76.100 -#endif
77.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/request.h Sun Jun 21 22:04:11 2009 -0400
77.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
77.3 @@ -1,1498 +0,0 @@
77.4 -/**
77.5 - * @file request.h Request API
77.6 - * @ingroup core
77.7 - */
77.8 -
77.9 -/* purple
77.10 - *
77.11 - * Purple is the legal property of its developers, whose names are too numerous
77.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
77.13 - * source distribution.
77.14 - *
77.15 - * This program is free software; you can redistribute it and/or modify
77.16 - * it under the terms of the GNU General Public License as published by
77.17 - * the Free Software Foundation; either version 2 of the License, or
77.18 - * (at your option) any later version.
77.19 - *
77.20 - * This program is distributed in the hope that it will be useful,
77.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
77.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
77.23 - * GNU General Public License for more details.
77.24 - *
77.25 - * You should have received a copy of the GNU General Public License
77.26 - * along with this program; if not, write to the Free Software
77.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
77.28 - */
77.29 -#ifndef _PURPLE_REQUEST_H_
77.30 -#define _PURPLE_REQUEST_H_
77.31 -
77.32 -#include <stdlib.h>
77.33 -#include <glib-object.h>
77.34 -#include <glib.h>
77.35 -
77.36 -#include "account.h"
77.37 -
77.38 -#define PURPLE_DEFAULT_ACTION_NONE -1
77.39 -
77.40 -/**
77.41 - * Request types.
77.42 - */
77.43 -typedef enum
77.44 -{
77.45 - PURPLE_REQUEST_INPUT = 0, /**< Text input request. */
77.46 - PURPLE_REQUEST_CHOICE, /**< Multiple-choice request. */
77.47 - PURPLE_REQUEST_ACTION, /**< Action request. */
77.48 - PURPLE_REQUEST_FIELDS, /**< Multiple fields request. */
77.49 - PURPLE_REQUEST_FILE, /**< File open or save request. */
77.50 - PURPLE_REQUEST_FOLDER /**< Folder selection request. */
77.51 -
77.52 -} PurpleRequestType;
77.53 -
77.54 -/**
77.55 - * A type of field.
77.56 - */
77.57 -typedef enum
77.58 -{
77.59 - PURPLE_REQUEST_FIELD_NONE,
77.60 - PURPLE_REQUEST_FIELD_STRING,
77.61 - PURPLE_REQUEST_FIELD_INTEGER,
77.62 - PURPLE_REQUEST_FIELD_BOOLEAN,
77.63 - PURPLE_REQUEST_FIELD_CHOICE,
77.64 - PURPLE_REQUEST_FIELD_LIST,
77.65 - PURPLE_REQUEST_FIELD_LABEL,
77.66 - PURPLE_REQUEST_FIELD_IMAGE,
77.67 - PURPLE_REQUEST_FIELD_ACCOUNT
77.68 -
77.69 -} PurpleRequestFieldType;
77.70 -
77.71 -/**
77.72 - * Multiple fields request data.
77.73 - */
77.74 -typedef struct
77.75 -{
77.76 - GList *groups;
77.77 -
77.78 - GHashTable *fields;
77.79 -
77.80 - GList *required_fields;
77.81 -
77.82 - void *ui_data;
77.83 -
77.84 -} PurpleRequestFields;
77.85 -
77.86 -/**
77.87 - * A group of fields with a title.
77.88 - */
77.89 -typedef struct
77.90 -{
77.91 - PurpleRequestFields *fields_list;
77.92 -
77.93 - char *title;
77.94 -
77.95 - GList *fields;
77.96 -
77.97 -} PurpleRequestFieldGroup;
77.98 -
77.99 -/**
77.100 - * A request field.
77.101 - */
77.102 -typedef struct
77.103 -{
77.104 - PurpleRequestFieldType type;
77.105 - PurpleRequestFieldGroup *group;
77.106 -
77.107 - char *id;
77.108 - char *label;
77.109 - char *type_hint;
77.110 -
77.111 - gboolean visible;
77.112 - gboolean required;
77.113 -
77.114 - union
77.115 - {
77.116 - struct
77.117 - {
77.118 - gboolean multiline;
77.119 - gboolean masked;
77.120 - gboolean editable;
77.121 - char *default_value;
77.122 - char *value;
77.123 -
77.124 - } string;
77.125 -
77.126 - struct
77.127 - {
77.128 - int default_value;
77.129 - int value;
77.130 -
77.131 - } integer;
77.132 -
77.133 - struct
77.134 - {
77.135 - gboolean default_value;
77.136 - gboolean value;
77.137 -
77.138 - } boolean;
77.139 -
77.140 - struct
77.141 - {
77.142 - int default_value;
77.143 - int value;
77.144 -
77.145 - GList *labels;
77.146 -
77.147 - } choice;
77.148 -
77.149 - struct
77.150 - {
77.151 - GList *items;
77.152 - GHashTable *item_data;
77.153 - GList *selected;
77.154 - GHashTable *selected_table;
77.155 -
77.156 - gboolean multiple_selection;
77.157 -
77.158 - } list;
77.159 -
77.160 - struct
77.161 - {
77.162 - PurpleAccount *default_account;
77.163 - PurpleAccount *account;
77.164 - gboolean show_all;
77.165 -
77.166 - PurpleFilterAccountFunc filter_func;
77.167 -
77.168 - } account;
77.169 -
77.170 - struct
77.171 - {
77.172 - unsigned int scale_x;
77.173 - unsigned int scale_y;
77.174 - const char *buffer;
77.175 - gsize size;
77.176 - } image;
77.177 -
77.178 - } u;
77.179 -
77.180 - void *ui_data;
77.181 -
77.182 -} PurpleRequestField;
77.183 -
77.184 -/**
77.185 - * Request UI operations.
77.186 - */
77.187 -typedef struct
77.188 -{
77.189 - /** @see purple_request_input(). */
77.190 - void *(*request_input)(const char *title, const char *primary,
77.191 - const char *secondary, const char *default_value,
77.192 - gboolean multiline, gboolean masked, gchar *hint,
77.193 - const char *ok_text, GCallback ok_cb,
77.194 - const char *cancel_text, GCallback cancel_cb,
77.195 - PurpleAccount *account, const char *who,
77.196 - PurpleConversation *conv, void *user_data);
77.197 -
77.198 - /** @see purple_request_choice_varg(). */
77.199 - void *(*request_choice)(const char *title, const char *primary,
77.200 - const char *secondary, int default_value,
77.201 - const char *ok_text, GCallback ok_cb,
77.202 - const char *cancel_text, GCallback cancel_cb,
77.203 - PurpleAccount *account, const char *who,
77.204 - PurpleConversation *conv, void *user_data,
77.205 - va_list choices);
77.206 -
77.207 - /** @see purple_request_action_varg(). */
77.208 - void *(*request_action)(const char *title, const char *primary,
77.209 - const char *secondary, int default_action,
77.210 - PurpleAccount *account, const char *who,
77.211 - PurpleConversation *conv, void *user_data,
77.212 - size_t action_count, va_list actions);
77.213 -
77.214 - /** @see purple_request_fields(). */
77.215 - void *(*request_fields)(const char *title, const char *primary,
77.216 - const char *secondary, PurpleRequestFields *fields,
77.217 - const char *ok_text, GCallback ok_cb,
77.218 - const char *cancel_text, GCallback cancel_cb,
77.219 - PurpleAccount *account, const char *who,
77.220 - PurpleConversation *conv, void *user_data);
77.221 -
77.222 - /** @see purple_request_file(). */
77.223 - void *(*request_file)(const char *title, const char *filename,
77.224 - gboolean savedialog, GCallback ok_cb,
77.225 - GCallback cancel_cb, PurpleAccount *account,
77.226 - const char *who, PurpleConversation *conv,
77.227 - void *user_data);
77.228 -
77.229 - void (*close_request)(PurpleRequestType type, void *ui_handle);
77.230 -
77.231 - /** @see purple_request_folder(). */
77.232 - void *(*request_folder)(const char *title, const char *dirname,
77.233 - GCallback ok_cb, GCallback cancel_cb,
77.234 - PurpleAccount *account, const char *who,
77.235 - PurpleConversation *conv, void *user_data);
77.236 -
77.237 - void (*_purple_reserved1)(void);
77.238 - void (*_purple_reserved2)(void);
77.239 - void (*_purple_reserved3)(void);
77.240 - void (*_purple_reserved4)(void);
77.241 -} PurpleRequestUiOps;
77.242 -
77.243 -typedef void (*PurpleRequestInputCb)(void *, const char *);
77.244 -
77.245 -/** The type of callbacks passed to purple_request_action(). The first
77.246 - * argument is the @a user_data parameter; the second is the index in the list
77.247 - * of actions of the one chosen.
77.248 - */
77.249 -typedef void (*PurpleRequestActionCb)(void *, int);
77.250 -typedef void (*PurpleRequestChoiceCb)(void *, int);
77.251 -typedef void (*PurpleRequestFieldsCb)(void *, PurpleRequestFields *fields);
77.252 -typedef void (*PurpleRequestFileCb)(void *, const char *filename);
77.253 -
77.254 -#ifdef __cplusplus
77.255 -extern "C" {
77.256 -#endif
77.257 -
77.258 -/**************************************************************************/
77.259 -/** @name Field List API */
77.260 -/**************************************************************************/
77.261 -/*@{*/
77.262 -
77.263 -/**
77.264 - * Creates a list of fields to pass to purple_request_fields().
77.265 - *
77.266 - * @return A PurpleRequestFields structure.
77.267 - */
77.268 -PurpleRequestFields *purple_request_fields_new(void);
77.269 -
77.270 -/**
77.271 - * Destroys a list of fields.
77.272 - *
77.273 - * @param fields The list of fields to destroy.
77.274 - */
77.275 -void purple_request_fields_destroy(PurpleRequestFields *fields);
77.276 -
77.277 -/**
77.278 - * Adds a group of fields to the list.
77.279 - *
77.280 - * @param fields The fields list.
77.281 - * @param group The group to add.
77.282 - */
77.283 -void purple_request_fields_add_group(PurpleRequestFields *fields,
77.284 - PurpleRequestFieldGroup *group);
77.285 -
77.286 -/**
77.287 - * Returns a list of all groups in a field list.
77.288 - *
77.289 - * @param fields The fields list.
77.290 - *
77.291 - * @constreturn A list of groups.
77.292 - */
77.293 -GList *purple_request_fields_get_groups(const PurpleRequestFields *fields);
77.294 -
77.295 -/**
77.296 - * Returns whether or not the field with the specified ID exists.
77.297 - *
77.298 - * @param fields The fields list.
77.299 - * @param id The ID of the field.
77.300 - *
77.301 - * @return TRUE if the field exists, or FALSE.
77.302 - */
77.303 -gboolean purple_request_fields_exists(const PurpleRequestFields *fields,
77.304 - const char *id);
77.305 -
77.306 -/**
77.307 - * Returns a list of all required fields.
77.308 - *
77.309 - * @param fields The fields list.
77.310 - *
77.311 - * @constreturn The list of required fields.
77.312 - */
77.313 -GList *purple_request_fields_get_required(const PurpleRequestFields *fields);
77.314 -
77.315 -/**
77.316 - * Returns whether or not a field with the specified ID is required.
77.317 - *
77.318 - * @param fields The fields list.
77.319 - * @param id The field ID.
77.320 - *
77.321 - * @return TRUE if the specified field is required, or FALSE.
77.322 - */
77.323 -gboolean purple_request_fields_is_field_required(const PurpleRequestFields *fields,
77.324 - const char *id);
77.325 -
77.326 -/**
77.327 - * Returns whether or not all required fields have values.
77.328 - *
77.329 - * @param fields The fields list.
77.330 - *
77.331 - * @return TRUE if all required fields have values, or FALSE.
77.332 - */
77.333 -gboolean purple_request_fields_all_required_filled(
77.334 - const PurpleRequestFields *fields);
77.335 -
77.336 -/**
77.337 - * Return the field with the specified ID.
77.338 - *
77.339 - * @param fields The fields list.
77.340 - * @param id The ID of the field.
77.341 - *
77.342 - * @return The field, if found.
77.343 - */
77.344 -PurpleRequestField *purple_request_fields_get_field(
77.345 - const PurpleRequestFields *fields, const char *id);
77.346 -
77.347 -/**
77.348 - * Returns the string value of a field with the specified ID.
77.349 - *
77.350 - * @param fields The fields list.
77.351 - * @param id The ID of the field.
77.352 - *
77.353 - * @return The string value, if found, or @c NULL otherwise.
77.354 - */
77.355 -const char *purple_request_fields_get_string(const PurpleRequestFields *fields,
77.356 - const char *id);
77.357 -
77.358 -/**
77.359 - * Returns the integer value of a field with the specified ID.
77.360 - *
77.361 - * @param fields The fields list.
77.362 - * @param id The ID of the field.
77.363 - *
77.364 - * @return The integer value, if found, or 0 otherwise.
77.365 - */
77.366 -int purple_request_fields_get_integer(const PurpleRequestFields *fields,
77.367 - const char *id);
77.368 -
77.369 -/**
77.370 - * Returns the boolean value of a field with the specified ID.
77.371 - *
77.372 - * @param fields The fields list.
77.373 - * @param id The ID of the field.
77.374 - *
77.375 - * @return The boolean value, if found, or @c FALSE otherwise.
77.376 - */
77.377 -gboolean purple_request_fields_get_bool(const PurpleRequestFields *fields,
77.378 - const char *id);
77.379 -
77.380 -/**
77.381 - * Returns the choice index of a field with the specified ID.
77.382 - *
77.383 - * @param fields The fields list.
77.384 - * @param id The ID of the field.
77.385 - *
77.386 - * @return The choice index, if found, or -1 otherwise.
77.387 - */
77.388 -int purple_request_fields_get_choice(const PurpleRequestFields *fields,
77.389 - const char *id);
77.390 -
77.391 -/**
77.392 - * Returns the account of a field with the specified ID.
77.393 - *
77.394 - * @param fields The fields list.
77.395 - * @param id The ID of the field.
77.396 - *
77.397 - * @return The account value, if found, or NULL otherwise.
77.398 - */
77.399 -PurpleAccount *purple_request_fields_get_account(const PurpleRequestFields *fields,
77.400 - const char *id);
77.401 -
77.402 -/*@}*/
77.403 -
77.404 -/**************************************************************************/
77.405 -/** @name Fields Group API */
77.406 -/**************************************************************************/
77.407 -/*@{*/
77.408 -
77.409 -/**
77.410 - * Creates a fields group with an optional title.
77.411 - *
77.412 - * @param title The optional title to give the group.
77.413 - *
77.414 - * @return A new fields group
77.415 - */
77.416 -PurpleRequestFieldGroup *purple_request_field_group_new(const char *title);
77.417 -
77.418 -/**
77.419 - * Destroys a fields group.
77.420 - *
77.421 - * @param group The group to destroy.
77.422 - */
77.423 -void purple_request_field_group_destroy(PurpleRequestFieldGroup *group);
77.424 -
77.425 -/**
77.426 - * Adds a field to the group.
77.427 - *
77.428 - * @param group The group to add the field to.
77.429 - * @param field The field to add to the group.
77.430 - */
77.431 -void purple_request_field_group_add_field(PurpleRequestFieldGroup *group,
77.432 - PurpleRequestField *field);
77.433 -
77.434 -/**
77.435 - * Returns the title of a fields group.
77.436 - *
77.437 - * @param group The group.
77.438 - *
77.439 - * @return The title, if set.
77.440 - */
77.441 -const char *purple_request_field_group_get_title(
77.442 - const PurpleRequestFieldGroup *group);
77.443 -
77.444 -/**
77.445 - * Returns a list of all fields in a group.
77.446 - *
77.447 - * @param group The group.
77.448 - *
77.449 - * @constreturn The list of fields in the group.
77.450 - */
77.451 -GList *purple_request_field_group_get_fields(
77.452 - const PurpleRequestFieldGroup *group);
77.453 -
77.454 -/*@}*/
77.455 -
77.456 -/**************************************************************************/
77.457 -/** @name Field API */
77.458 -/**************************************************************************/
77.459 -/*@{*/
77.460 -
77.461 -/**
77.462 - * Creates a field of the specified type.
77.463 - *
77.464 - * @param id The field ID.
77.465 - * @param text The text label of the field.
77.466 - * @param type The type of field.
77.467 - *
77.468 - * @return The new field.
77.469 - */
77.470 -PurpleRequestField *purple_request_field_new(const char *id, const char *text,
77.471 - PurpleRequestFieldType type);
77.472 -
77.473 -/**
77.474 - * Destroys a field.
77.475 - *
77.476 - * @param field The field to destroy.
77.477 - */
77.478 -void purple_request_field_destroy(PurpleRequestField *field);
77.479 -
77.480 -/**
77.481 - * Sets the label text of a field.
77.482 - *
77.483 - * @param field The field.
77.484 - * @param label The text label.
77.485 - */
77.486 -void purple_request_field_set_label(PurpleRequestField *field, const char *label);
77.487 -
77.488 -/**
77.489 - * Sets whether or not a field is visible.
77.490 - *
77.491 - * @param field The field.
77.492 - * @param visible TRUE if visible, or FALSE if not.
77.493 - */
77.494 -void purple_request_field_set_visible(PurpleRequestField *field, gboolean visible);
77.495 -
77.496 -/**
77.497 - * Sets the type hint for the field.
77.498 - *
77.499 - * This is optionally used by the UIs to provide such features as
77.500 - * auto-completion for type hints like "account" and "screenname".
77.501 - *
77.502 - * @param field The field.
77.503 - * @param type_hint The type hint.
77.504 - */
77.505 -void purple_request_field_set_type_hint(PurpleRequestField *field,
77.506 - const char *type_hint);
77.507 -
77.508 -/**
77.509 - * Sets whether or not a field is required.
77.510 - *
77.511 - * @param field The field.
77.512 - * @param required TRUE if required, or FALSE.
77.513 - */
77.514 -void purple_request_field_set_required(PurpleRequestField *field,
77.515 - gboolean required);
77.516 -
77.517 -/**
77.518 - * Returns the type of a field.
77.519 - *
77.520 - * @param field The field.
77.521 - *
77.522 - * @return The field's type.
77.523 - */
77.524 -PurpleRequestFieldType purple_request_field_get_type(const PurpleRequestField *field);
77.525 -
77.526 -/**
77.527 - * Returns the ID of a field.
77.528 - *
77.529 - * @param field The field.
77.530 - *
77.531 - * @return The ID
77.532 - */
77.533 -const char *purple_request_field_get_id(const PurpleRequestField *field);
77.534 -
77.535 -/**
77.536 - * Returns the label text of a field.
77.537 - *
77.538 - * @param field The field.
77.539 - *
77.540 - * @return The label text.
77.541 - */
77.542 -const char *purple_request_field_get_label(const PurpleRequestField *field);
77.543 -
77.544 -/**
77.545 - * Returns whether or not a field is visible.
77.546 - *
77.547 - * @param field The field.
77.548 - *
77.549 - * @return TRUE if the field is visible. FALSE otherwise.
77.550 - */
77.551 -gboolean purple_request_field_is_visible(const PurpleRequestField *field);
77.552 -
77.553 -/**
77.554 - * Returns the field's type hint.
77.555 - *
77.556 - * @param field The field.
77.557 - *
77.558 - * @return The field's type hint.
77.559 - */
77.560 -const char *purple_request_field_get_type_hint(const PurpleRequestField *field);
77.561 -
77.562 -/**
77.563 - * Returns whether or not a field is required.
77.564 - *
77.565 - * @param field The field.
77.566 - *
77.567 - * @return TRUE if the field is required, or FALSE.
77.568 - */
77.569 -gboolean purple_request_field_is_required(const PurpleRequestField *field);
77.570 -
77.571 -/*@}*/
77.572 -
77.573 -/**************************************************************************/
77.574 -/** @name String Field API */
77.575 -/**************************************************************************/
77.576 -/*@{*/
77.577 -
77.578 -/**
77.579 - * Creates a string request field.
77.580 - *
77.581 - * @param id The field ID.
77.582 - * @param text The text label of the field.
77.583 - * @param default_value The optional default value.
77.584 - * @param multiline Whether or not this should be a multiline string.
77.585 - *
77.586 - * @return The new field.
77.587 - */
77.588 -PurpleRequestField *purple_request_field_string_new(const char *id,
77.589 - const char *text,
77.590 - const char *default_value,
77.591 - gboolean multiline);
77.592 -
77.593 -/**
77.594 - * Sets the default value in a string field.
77.595 - *
77.596 - * @param field The field.
77.597 - * @param default_value The default value.
77.598 - */
77.599 -void purple_request_field_string_set_default_value(PurpleRequestField *field,
77.600 - const char *default_value);
77.601 -
77.602 -/**
77.603 - * Sets the value in a string field.
77.604 - *
77.605 - * @param field The field.
77.606 - * @param value The value.
77.607 - */
77.608 -void purple_request_field_string_set_value(PurpleRequestField *field,
77.609 - const char *value);
77.610 -
77.611 -/**
77.612 - * Sets whether or not a string field is masked
77.613 - * (commonly used for password fields).
77.614 - *
77.615 - * @param field The field.
77.616 - * @param masked The masked value.
77.617 - */
77.618 -void purple_request_field_string_set_masked(PurpleRequestField *field,
77.619 - gboolean masked);
77.620 -
77.621 -/**
77.622 - * Sets whether or not a string field is editable.
77.623 - *
77.624 - * @param field The field.
77.625 - * @param editable The editable value.
77.626 - */
77.627 -void purple_request_field_string_set_editable(PurpleRequestField *field,
77.628 - gboolean editable);
77.629 -
77.630 -/**
77.631 - * Returns the default value in a string field.
77.632 - *
77.633 - * @param field The field.
77.634 - *
77.635 - * @return The default value.
77.636 - */
77.637 -const char *purple_request_field_string_get_default_value(
77.638 - const PurpleRequestField *field);
77.639 -
77.640 -/**
77.641 - * Returns the user-entered value in a string field.
77.642 - *
77.643 - * @param field The field.
77.644 - *
77.645 - * @return The value.
77.646 - */
77.647 -const char *purple_request_field_string_get_value(const PurpleRequestField *field);
77.648 -
77.649 -/**
77.650 - * Returns whether or not a string field is multi-line.
77.651 - *
77.652 - * @param field The field.
77.653 - *
77.654 - * @return @c TRUE if the field is mulit-line, or @c FALSE otherwise.
77.655 - */
77.656 -gboolean purple_request_field_string_is_multiline(const PurpleRequestField *field);
77.657 -
77.658 -/**
77.659 - * Returns whether or not a string field is masked.
77.660 - *
77.661 - * @param field The field.
77.662 - *
77.663 - * @return @c TRUE if the field is masked, or @c FALSE otherwise.
77.664 - */
77.665 -gboolean purple_request_field_string_is_masked(const PurpleRequestField *field);
77.666 -
77.667 -/**
77.668 - * Returns whether or not a string field is editable.
77.669 - *
77.670 - * @param field The field.
77.671 - *
77.672 - * @return @c TRUE if the field is editable, or @c FALSE otherwise.
77.673 - */
77.674 -gboolean purple_request_field_string_is_editable(const PurpleRequestField *field);
77.675 -
77.676 -/*@}*/
77.677 -
77.678 -/**************************************************************************/
77.679 -/** @name Integer Field API */
77.680 -/**************************************************************************/
77.681 -/*@{*/
77.682 -
77.683 -/**
77.684 - * Creates an integer field.
77.685 - *
77.686 - * @param id The field ID.
77.687 - * @param text The text label of the field.
77.688 - * @param default_value The default value.
77.689 - *
77.690 - * @return The new field.
77.691 - */
77.692 -PurpleRequestField *purple_request_field_int_new(const char *id,
77.693 - const char *text,
77.694 - int default_value);
77.695 -
77.696 -/**
77.697 - * Sets the default value in an integer field.
77.698 - *
77.699 - * @param field The field.
77.700 - * @param default_value The default value.
77.701 - */
77.702 -void purple_request_field_int_set_default_value(PurpleRequestField *field,
77.703 - int default_value);
77.704 -
77.705 -/**
77.706 - * Sets the value in an integer field.
77.707 - *
77.708 - * @param field The field.
77.709 - * @param value The value.
77.710 - */
77.711 -void purple_request_field_int_set_value(PurpleRequestField *field, int value);
77.712 -
77.713 -/**
77.714 - * Returns the default value in an integer field.
77.715 - *
77.716 - * @param field The field.
77.717 - *
77.718 - * @return The default value.
77.719 - */
77.720 -int purple_request_field_int_get_default_value(const PurpleRequestField *field);
77.721 -
77.722 -/**
77.723 - * Returns the user-entered value in an integer field.
77.724 - *
77.725 - * @param field The field.
77.726 - *
77.727 - * @return The value.
77.728 - */
77.729 -int purple_request_field_int_get_value(const PurpleRequestField *field);
77.730 -
77.731 -/*@}*/
77.732 -
77.733 -/**************************************************************************/
77.734 -/** @name Boolean Field API */
77.735 -/**************************************************************************/
77.736 -/*@{*/
77.737 -
77.738 -/**
77.739 - * Creates a boolean field.
77.740 - *
77.741 - * This is often represented as a checkbox.
77.742 - *
77.743 - * @param id The field ID.
77.744 - * @param text The text label of the field.
77.745 - * @param default_value The default value.
77.746 - *
77.747 - * @return The new field.
77.748 - */
77.749 -PurpleRequestField *purple_request_field_bool_new(const char *id,
77.750 - const char *text,
77.751 - gboolean default_value);
77.752 -
77.753 -/**
77.754 - * Sets the default value in an boolean field.
77.755 - *
77.756 - * @param field The field.
77.757 - * @param default_value The default value.
77.758 - */
77.759 -void purple_request_field_bool_set_default_value(PurpleRequestField *field,
77.760 - gboolean default_value);
77.761 -
77.762 -/**
77.763 - * Sets the value in an boolean field.
77.764 - *
77.765 - * @param field The field.
77.766 - * @param value The value.
77.767 - */
77.768 -void purple_request_field_bool_set_value(PurpleRequestField *field,
77.769 - gboolean value);
77.770 -
77.771 -/**
77.772 - * Returns the default value in an boolean field.
77.773 - *
77.774 - * @param field The field.
77.775 - *
77.776 - * @return The default value.
77.777 - */
77.778 -gboolean purple_request_field_bool_get_default_value(
77.779 - const PurpleRequestField *field);
77.780 -
77.781 -/**
77.782 - * Returns the user-entered value in an boolean field.
77.783 - *
77.784 - * @param field The field.
77.785 - *
77.786 - * @return The value.
77.787 - */
77.788 -gboolean purple_request_field_bool_get_value(const PurpleRequestField *field);
77.789 -
77.790 -/*@}*/
77.791 -
77.792 -/**************************************************************************/
77.793 -/** @name Choice Field API */
77.794 -/**************************************************************************/
77.795 -/*@{*/
77.796 -
77.797 -/**
77.798 - * Creates a multiple choice field.
77.799 - *
77.800 - * This is often represented as a group of radio buttons.
77.801 - *
77.802 - * @param id The field ID.
77.803 - * @param text The optional label of the field.
77.804 - * @param default_value The default choice.
77.805 - *
77.806 - * @return The new field.
77.807 - */
77.808 -PurpleRequestField *purple_request_field_choice_new(const char *id,
77.809 - const char *text,
77.810 - int default_value);
77.811 -
77.812 -/**
77.813 - * Adds a choice to a multiple choice field.
77.814 - *
77.815 - * @param field The choice field.
77.816 - * @param label The choice label.
77.817 - */
77.818 -void purple_request_field_choice_add(PurpleRequestField *field,
77.819 - const char *label);
77.820 -
77.821 -/**
77.822 - * Sets the default value in an choice field.
77.823 - *
77.824 - * @param field The field.
77.825 - * @param default_value The default value.
77.826 - */
77.827 -void purple_request_field_choice_set_default_value(PurpleRequestField *field,
77.828 - int default_value);
77.829 -
77.830 -/**
77.831 - * Sets the value in an choice field.
77.832 - *
77.833 - * @param field The field.
77.834 - * @param value The value.
77.835 - */
77.836 -void purple_request_field_choice_set_value(PurpleRequestField *field, int value);
77.837 -
77.838 -/**
77.839 - * Returns the default value in an choice field.
77.840 - *
77.841 - * @param field The field.
77.842 - *
77.843 - * @return The default value.
77.844 - */
77.845 -int purple_request_field_choice_get_default_value(const PurpleRequestField *field);
77.846 -
77.847 -/**
77.848 - * Returns the user-entered value in an choice field.
77.849 - *
77.850 - * @param field The field.
77.851 - *
77.852 - * @return The value.
77.853 - */
77.854 -int purple_request_field_choice_get_value(const PurpleRequestField *field);
77.855 -
77.856 -/**
77.857 - * Returns a list of labels in a choice field.
77.858 - *
77.859 - * @param field The field.
77.860 - *
77.861 - * @constreturn The list of labels.
77.862 - */
77.863 -GList *purple_request_field_choice_get_labels(const PurpleRequestField *field);
77.864 -
77.865 -/*@}*/
77.866 -
77.867 -/**************************************************************************/
77.868 -/** @name List Field API */
77.869 -/**************************************************************************/
77.870 -/*@{*/
77.871 -
77.872 -/**
77.873 - * Creates a multiple list item field.
77.874 - *
77.875 - * @param id The field ID.
77.876 - * @param text The optional label of the field.
77.877 - *
77.878 - * @return The new field.
77.879 - */
77.880 -PurpleRequestField *purple_request_field_list_new(const char *id, const char *text);
77.881 -
77.882 -/**
77.883 - * Sets whether or not a list field allows multiple selection.
77.884 - *
77.885 - * @param field The list field.
77.886 - * @param multi_select TRUE if multiple selection is enabled,
77.887 - * or FALSE otherwise.
77.888 - */
77.889 -void purple_request_field_list_set_multi_select(PurpleRequestField *field,
77.890 - gboolean multi_select);
77.891 -
77.892 -/**
77.893 - * Returns whether or not a list field allows multiple selection.
77.894 - *
77.895 - * @param field The list field.
77.896 - *
77.897 - * @return TRUE if multiple selection is enabled, or FALSE otherwise.
77.898 - */
77.899 -gboolean purple_request_field_list_get_multi_select(
77.900 - const PurpleRequestField *field);
77.901 -
77.902 -/**
77.903 - * Returns the data for a particular item.
77.904 - *
77.905 - * @param field The list field.
77.906 - * @param text The item text.
77.907 - *
77.908 - * @return The data associated with the item.
77.909 - */
77.910 -void *purple_request_field_list_get_data(const PurpleRequestField *field,
77.911 - const char *text);
77.912 -
77.913 -/**
77.914 - * Adds an item to a list field.
77.915 - *
77.916 - * @param field The list field.
77.917 - * @param item The list item.
77.918 - * @param data The associated data.
77.919 - */
77.920 -void purple_request_field_list_add(PurpleRequestField *field,
77.921 - const char *item, void *data);
77.922 -
77.923 -/**
77.924 - * Adds a selected item to the list field.
77.925 - *
77.926 - * @param field The field.
77.927 - * @param item The item to add.
77.928 - */
77.929 -void purple_request_field_list_add_selected(PurpleRequestField *field,
77.930 - const char *item);
77.931 -
77.932 -/**
77.933 - * Clears the list of selected items in a list field.
77.934 - *
77.935 - * @param field The field.
77.936 - */
77.937 -void purple_request_field_list_clear_selected(PurpleRequestField *field);
77.938 -
77.939 -/**
77.940 - * Sets a list of selected items in a list field.
77.941 - *
77.942 - * @param field The field.
77.943 - * @param items The list of selected items, which is not modified or freed.
77.944 - */
77.945 -void purple_request_field_list_set_selected(PurpleRequestField *field,
77.946 - GList *items);
77.947 -
77.948 -/**
77.949 - * Returns whether or not a particular item is selected in a list field.
77.950 - *
77.951 - * @param field The field.
77.952 - * @param item The item.
77.953 - *
77.954 - * @return TRUE if the item is selected. FALSE otherwise.
77.955 - */
77.956 -gboolean purple_request_field_list_is_selected(const PurpleRequestField *field,
77.957 - const char *item);
77.958 -
77.959 -/**
77.960 - * Returns a list of selected items in a list field.
77.961 - *
77.962 - * To retrieve the data for each item, use
77.963 - * purple_request_field_list_get_data().
77.964 - *
77.965 - * @param field The field.
77.966 - *
77.967 - * @constreturn The list of selected items.
77.968 - */
77.969 -GList *purple_request_field_list_get_selected(
77.970 - const PurpleRequestField *field);
77.971 -
77.972 -/**
77.973 - * Returns a list of items in a list field.
77.974 - *
77.975 - * @param field The field.
77.976 - *
77.977 - * @constreturn The list of items.
77.978 - */
77.979 -GList *purple_request_field_list_get_items(const PurpleRequestField *field);
77.980 -
77.981 -/*@}*/
77.982 -
77.983 -/**************************************************************************/
77.984 -/** @name Label Field API */
77.985 -/**************************************************************************/
77.986 -/*@{*/
77.987 -
77.988 -/**
77.989 - * Creates a label field.
77.990 - *
77.991 - * @param id The field ID.
77.992 - * @param text The label of the field.
77.993 - *
77.994 - * @return The new field.
77.995 - */
77.996 -PurpleRequestField *purple_request_field_label_new(const char *id,
77.997 - const char *text);
77.998 -
77.999 -/*@}*/
77.1000 -
77.1001 -/**************************************************************************/
77.1002 -/** @name Image Field API */
77.1003 -/**************************************************************************/
77.1004 -/*@{*/
77.1005 -
77.1006 -/**
77.1007 - * Creates an image field.
77.1008 - *
77.1009 - * @param id The field ID.
77.1010 - * @param text The label of the field.
77.1011 - * @param buf The image data.
77.1012 - * @param size The size of the data in @a buffer.
77.1013 - *
77.1014 - * @return The new field.
77.1015 - */
77.1016 -PurpleRequestField *purple_request_field_image_new(const char *id, const char *text,
77.1017 - const char *buf, gsize size);
77.1018 -
77.1019 -/**
77.1020 - * Sets the scale factors of an image field.
77.1021 - *
77.1022 - * @param field The image field.
77.1023 - * @param x The x scale factor.
77.1024 - * @param y The y scale factor.
77.1025 - */
77.1026 -void purple_request_field_image_set_scale(PurpleRequestField *field, unsigned int x, unsigned int y);
77.1027 -
77.1028 -/**
77.1029 - * Returns pointer to the image.
77.1030 - *
77.1031 - * @param field The image field.
77.1032 - *
77.1033 - * @return Pointer to the image.
77.1034 - */
77.1035 -const char *purple_request_field_image_get_buffer(PurpleRequestField *field);
77.1036 -
77.1037 -/**
77.1038 - * Returns size (in bytes) of the image.
77.1039 - *
77.1040 - * @param field The image field.
77.1041 - *
77.1042 - * @return Size of the image.
77.1043 - */
77.1044 -gsize purple_request_field_image_get_size(PurpleRequestField *field);
77.1045 -
77.1046 -/**
77.1047 - * Returns X scale coefficient of the image.
77.1048 - *
77.1049 - * @param field The image field.
77.1050 - *
77.1051 - * @return X scale coefficient of the image.
77.1052 - */
77.1053 -unsigned int purple_request_field_image_get_scale_x(PurpleRequestField *field);
77.1054 -
77.1055 -/**
77.1056 - * Returns Y scale coefficient of the image.
77.1057 - *
77.1058 - * @param field The image field.
77.1059 - *
77.1060 - * @return Y scale coefficient of the image.
77.1061 - */
77.1062 -unsigned int purple_request_field_image_get_scale_y(PurpleRequestField *field);
77.1063 -
77.1064 -/*@}*/
77.1065 -
77.1066 -/**************************************************************************/
77.1067 -/** @name Account Field API */
77.1068 -/**************************************************************************/
77.1069 -/*@{*/
77.1070 -
77.1071 -/**
77.1072 - * Creates an account field.
77.1073 - *
77.1074 - * By default, this field will not show offline accounts.
77.1075 - *
77.1076 - * @param id The field ID.
77.1077 - * @param text The text label of the field.
77.1078 - * @param account The optional default account.
77.1079 - *
77.1080 - * @return The new field.
77.1081 - */
77.1082 -PurpleRequestField *purple_request_field_account_new(const char *id,
77.1083 - const char *text,
77.1084 - PurpleAccount *account);
77.1085 -
77.1086 -/**
77.1087 - * Sets the default account on an account field.
77.1088 - *
77.1089 - * @param field The account field.
77.1090 - * @param default_value The default account.
77.1091 - */
77.1092 -void purple_request_field_account_set_default_value(PurpleRequestField *field,
77.1093 - PurpleAccount *default_value);
77.1094 -
77.1095 -/**
77.1096 - * Sets the account in an account field.
77.1097 - *
77.1098 - * @param field The account field.
77.1099 - * @param value The account.
77.1100 - */
77.1101 -void purple_request_field_account_set_value(PurpleRequestField *field,
77.1102 - PurpleAccount *value);
77.1103 -
77.1104 -/**
77.1105 - * Sets whether or not to show all accounts in an account field.
77.1106 - *
77.1107 - * If TRUE, all accounts, online or offline, will be shown. If FALSE,
77.1108 - * only online accounts will be shown.
77.1109 - *
77.1110 - * @param field The account field.
77.1111 - * @param show_all Whether or not to show all accounts.
77.1112 - */
77.1113 -void purple_request_field_account_set_show_all(PurpleRequestField *field,
77.1114 - gboolean show_all);
77.1115 -
77.1116 -/**
77.1117 - * Sets the account filter function in an account field.
77.1118 - *
77.1119 - * This function will determine which accounts get displayed and which
77.1120 - * don't.
77.1121 - *
77.1122 - * @param field The account field.
77.1123 - * @param filter_func The account filter function.
77.1124 - */
77.1125 -void purple_request_field_account_set_filter(PurpleRequestField *field,
77.1126 - PurpleFilterAccountFunc filter_func);
77.1127 -
77.1128 -/**
77.1129 - * Returns the default account in an account field.
77.1130 - *
77.1131 - * @param field The field.
77.1132 - *
77.1133 - * @return The default account.
77.1134 - */
77.1135 -PurpleAccount *purple_request_field_account_get_default_value(
77.1136 - const PurpleRequestField *field);
77.1137 -
77.1138 -/**
77.1139 - * Returns the user-entered account in an account field.
77.1140 - *
77.1141 - * @param field The field.
77.1142 - *
77.1143 - * @return The user-entered account.
77.1144 - */
77.1145 -PurpleAccount *purple_request_field_account_get_value(
77.1146 - const PurpleRequestField *field);
77.1147 -
77.1148 -/**
77.1149 - * Returns whether or not to show all accounts in an account field.
77.1150 - *
77.1151 - * If TRUE, all accounts, online or offline, will be shown. If FALSE,
77.1152 - * only online accounts will be shown.
77.1153 - *
77.1154 - * @param field The account field.
77.1155 - * @return Whether or not to show all accounts.
77.1156 - */
77.1157 -gboolean purple_request_field_account_get_show_all(
77.1158 - const PurpleRequestField *field);
77.1159 -
77.1160 -/**
77.1161 - * Returns the account filter function in an account field.
77.1162 - *
77.1163 - * This function will determine which accounts get displayed and which
77.1164 - * don't.
77.1165 - *
77.1166 - * @param field The account field.
77.1167 - *
77.1168 - * @return The account filter function.
77.1169 - */
77.1170 -PurpleFilterAccountFunc purple_request_field_account_get_filter(
77.1171 - const PurpleRequestField *field);
77.1172 -
77.1173 -/*@}*/
77.1174 -
77.1175 -/**************************************************************************/
77.1176 -/** @name Request API */
77.1177 -/**************************************************************************/
77.1178 -/*@{*/
77.1179 -
77.1180 -/**
77.1181 - * Prompts the user for text input.
77.1182 - *
77.1183 - * @param handle The plugin or connection handle. For some
77.1184 - * things this is <em>extremely</em> important. The
77.1185 - * handle is used to programmatically close the request
77.1186 - * dialog when it is no longer needed. For PRPLs this
77.1187 - * is often a pointer to the #PurpleConnection
77.1188 - * instance. For plugins this should be a similar,
77.1189 - * unique memory location. This value is important
77.1190 - * because it allows a request to be closed with
77.1191 - * purple_request_close_with_handle() when, for
77.1192 - * example, you sign offline. If the request is
77.1193 - * <em>not</em> closed it is <strong>very</strong>
77.1194 - * likely to cause a crash whenever the callback
77.1195 - * handler functions are triggered.
77.1196 - * @param title The title of the message, or @c NULL if it should have
77.1197 - * no title.
77.1198 - * @param primary The main point of the message, or @c NULL if you're
77.1199 - * feeling enigmatic.
77.1200 - * @param secondary Secondary information, or @c NULL if there is none.
77.1201 - * @param default_value The default value.
77.1202 - * @param multiline @c TRUE if the inputted text can span multiple lines.
77.1203 - * @param masked @c TRUE if the inputted text should be masked in some
77.1204 - * way (such as by displaying characters as stars). This
77.1205 - * might be because the input is some kind of password.
77.1206 - * @param hint Optionally suggest how the input box should appear.
77.1207 - * Use "html", for example, to allow the user to enter
77.1208 - * HTML.
77.1209 - * @param ok_text The text for the @c OK button, which may not be @c NULL.
77.1210 - * @param ok_cb The callback for the @c OK button, which may not be @c
77.1211 - * NULL.
77.1212 - * @param cancel_text The text for the @c Cancel button, which may not be @c
77.1213 - * NULL.
77.1214 - * @param cancel_cb The callback for the @c Cancel button, which may be
77.1215 - * @c NULL.
77.1216 - * @param account The #PurpleAccount associated with this request, or @c
77.1217 - * NULL if none is.
77.1218 - * @param who The username of the buddy associated with this request,
77.1219 - * or @c NULL if none is.
77.1220 - * @param conv The #PurpleConversation associated with this request, or
77.1221 - * @c NULL if none is.
77.1222 - * @param user_data The data to pass to the callback.
77.1223 - *
77.1224 - * @return A UI-specific handle.
77.1225 - */
77.1226 -void *purple_request_input(void *handle, const char *title, const char *primary,
77.1227 - const char *secondary, const char *default_value, gboolean multiline,
77.1228 - gboolean masked, gchar *hint,
77.1229 - const char *ok_text, GCallback ok_cb,
77.1230 - const char *cancel_text, GCallback cancel_cb,
77.1231 - PurpleAccount *account, const char *who, PurpleConversation *conv,
77.1232 - void *user_data);
77.1233 -
77.1234 -/**
77.1235 - * Prompts the user for multiple-choice input.
77.1236 - *
77.1237 - * @param handle The plugin or connection handle. For some things this
77.1238 - * is <em>extremely</em> important. See the comments on
77.1239 - * purple_request_input().
77.1240 - * @param title The title of the message, or @c NULL if it should have
77.1241 - * no title.
77.1242 - * @param primary The main point of the message, or @c NULL if you're
77.1243 - * feeling enigmatic.
77.1244 - * @param secondary Secondary information, or @c NULL if there is none.
77.1245 - * @param default_value The default choice; this should be one of the values
77.1246 - * listed in the varargs.
77.1247 - * @param ok_text The text for the @c OK button, which may not be @c NULL.
77.1248 - * @param ok_cb The callback for the @c OK button, which may not be @c
77.1249 - * NULL.
77.1250 - * @param cancel_text The text for the @c Cancel button, which may not be @c
77.1251 - * NULL.
77.1252 - * @param cancel_cb The callback for the @c Cancel button, or @c NULL to
77.1253 - * do nothing.
77.1254 - * @param account The #PurpleAccount associated with this request, or @c
77.1255 - * NULL if none is.
77.1256 - * @param who The username of the buddy associated with this request,
77.1257 - * or @c NULL if none is.
77.1258 - * @param conv The #PurpleConversation associated with this request, or
77.1259 - * @c NULL if none is.
77.1260 - * @param user_data The data to pass to the callback.
77.1261 - * @param ... The choices, which should be pairs of <tt>char *</tt>
77.1262 - * descriptions and <tt>int</tt> values, terminated with a
77.1263 - * @c NULL parameter.
77.1264 - *
77.1265 - * @return A UI-specific handle.
77.1266 - */
77.1267 -void *purple_request_choice(void *handle, const char *title, const char *primary,
77.1268 - const char *secondary, int default_value,
77.1269 - const char *ok_text, GCallback ok_cb,
77.1270 - const char *cancel_text, GCallback cancel_cb,
77.1271 - PurpleAccount *account, const char *who, PurpleConversation *conv,
77.1272 - void *user_data, ...) G_GNUC_NULL_TERMINATED;
77.1273 -
77.1274 -/**
77.1275 - * <tt>va_list</tt> version of purple_request_choice(); see its documentation.
77.1276 - */
77.1277 -void *purple_request_choice_varg(void *handle, const char *title,
77.1278 - const char *primary, const char *secondary, int default_value,
77.1279 - const char *ok_text, GCallback ok_cb,
77.1280 - const char *cancel_text, GCallback cancel_cb,
77.1281 - PurpleAccount *account, const char *who, PurpleConversation *conv,
77.1282 - void *user_data, va_list choices);
77.1283 -
77.1284 -/**
77.1285 - * Prompts the user for an action.
77.1286 - *
77.1287 - * This is often represented as a dialog with a button for each action.
77.1288 - *
77.1289 - * @param handle The plugin or connection handle. For some things this
77.1290 - * is <em>extremely</em> important. See the comments on
77.1291 - * purple_request_input().
77.1292 - * @param title The title of the message, or @c NULL if it should have
77.1293 - * no title.
77.1294 - * @param primary The main point of the message, or @c NULL if you're
77.1295 - * feeling enigmatic.
77.1296 - * @param secondary Secondary information, or @c NULL if there is none.
77.1297 - * @param default_action The default action, zero-indexed; if the third action
77.1298 - * supplied should be the default, supply <tt>2</tt>.
77.1299 - * The should be the action that users are most likely
77.1300 - * to select.
77.1301 - * @param account The #PurpleAccount associated with this request, or @c
77.1302 - * NULL if none is.
77.1303 - * @param who The username of the buddy associated with this request,
77.1304 - * or @c NULL if none is.
77.1305 - * @param conv The #PurpleConversation associated with this request, or
77.1306 - * @c NULL if none is.
77.1307 - * @param user_data The data to pass to the callback.
77.1308 - * @param action_count The number of actions.
77.1309 - * @param ... A list of actions. These are pairs of
77.1310 - * arguments. The first of each pair is the
77.1311 - * <tt>char *</tt> label that appears on the button. It
77.1312 - * should have an underscore before the letter you want
77.1313 - * to use as the accelerator key for the button. The
77.1314 - * second of each pair is the #PurpleRequestActionCb
77.1315 - * function to use when the button is clicked.
77.1316 - *
77.1317 - * @return A UI-specific handle.
77.1318 - */
77.1319 -void *purple_request_action(void *handle, const char *title, const char *primary,
77.1320 - const char *secondary, int default_action, PurpleAccount *account,
77.1321 - const char *who, PurpleConversation *conv, void *user_data,
77.1322 - size_t action_count, ...);
77.1323 -
77.1324 -/**
77.1325 - * <tt>va_list</tt> version of purple_request_action(); see its documentation.
77.1326 - */
77.1327 -void *purple_request_action_varg(void *handle, const char *title,
77.1328 - const char *primary, const char *secondary, int default_action,
77.1329 - PurpleAccount *account, const char *who, PurpleConversation *conv,
77.1330 - void *user_data, size_t action_count, va_list actions);
77.1331 -
77.1332 -/**
77.1333 - * Displays groups of fields for the user to fill in.
77.1334 - *
77.1335 - * @param handle The plugin or connection handle. For some things this
77.1336 - * is <em>extremely</em> important. See the comments on
77.1337 - * purple_request_input().
77.1338 - * @param title The title of the message, or @c NULL if it should have
77.1339 - * no title.
77.1340 - * @param primary The main point of the message, or @c NULL if you're
77.1341 - * feeling enigmatic.
77.1342 - * @param secondary Secondary information, or @c NULL if there is none.
77.1343 - * @param fields The list of fields.
77.1344 - * @param ok_text The text for the @c OK button, which may not be @c NULL.
77.1345 - * @param ok_cb The callback for the @c OK button, which may not be @c
77.1346 - * NULL.
77.1347 - * @param cancel_text The text for the @c Cancel button, which may not be @c
77.1348 - * NULL.
77.1349 - * @param cancel_cb The callback for the @c Cancel button, which may be
77.1350 - * @c NULL.
77.1351 - * @param account The #PurpleAccount associated with this request, or @c
77.1352 - * NULL if none is
77.1353 - * @param who The username of the buddy associated with this request,
77.1354 - * or @c NULL if none is
77.1355 - * @param conv The #PurpleConversation associated with this request, or
77.1356 - * @c NULL if none is
77.1357 - * @param user_data The data to pass to the callback.
77.1358 - *
77.1359 - * @return A UI-specific handle.
77.1360 - */
77.1361 -void *purple_request_fields(void *handle, const char *title, const char *primary,
77.1362 - const char *secondary, PurpleRequestFields *fields,
77.1363 - const char *ok_text, GCallback ok_cb,
77.1364 - const char *cancel_text, GCallback cancel_cb,
77.1365 - PurpleAccount *account, const char *who, PurpleConversation *conv,
77.1366 - void *user_data);
77.1367 -
77.1368 -/**
77.1369 - * Closes a request.
77.1370 - *
77.1371 - * @param type The request type.
77.1372 - * @param uihandle The request UI handle.
77.1373 - */
77.1374 -void purple_request_close(PurpleRequestType type, void *uihandle);
77.1375 -
77.1376 -/**
77.1377 - * Closes all requests registered with the specified handle.
77.1378 - *
77.1379 - * @param handle The handle, as supplied as the @a handle parameter to one of the
77.1380 - * <tt>purple_request_*</tt> functions.
77.1381 - *
77.1382 - * @see purple_request_input().
77.1383 - */
77.1384 -void purple_request_close_with_handle(void *handle);
77.1385 -
77.1386 -/**
77.1387 - * A wrapper for purple_request_action() that uses @c Yes and @c No buttons.
77.1388 - */
77.1389 -#define purple_request_yes_no(handle, title, primary, secondary, \
77.1390 - default_action, account, who, conv, \
77.1391 - user_data, yes_cb, no_cb) \
77.1392 - purple_request_action((handle), (title), (primary), (secondary), \
77.1393 - (default_action), account, who, conv, (user_data), 2, \
77.1394 - _("_Yes"), (yes_cb), _("_No"), (no_cb))
77.1395 -
77.1396 -/**
77.1397 - * A wrapper for purple_request_action() that uses @c OK and @c Cancel buttons.
77.1398 - */
77.1399 -#define purple_request_ok_cancel(handle, title, primary, secondary, \
77.1400 - default_action, account, who, conv, \
77.1401 - user_data, ok_cb, cancel_cb) \
77.1402 - purple_request_action((handle), (title), (primary), (secondary), \
77.1403 - (default_action), account, who, conv, (user_data), 2, \
77.1404 - _("_OK"), (ok_cb), _("_Cancel"), (cancel_cb))
77.1405 -
77.1406 -/**
77.1407 - * A wrapper for purple_request_action() that uses Accept and Cancel buttons.
77.1408 - */
77.1409 -#define purple_request_accept_cancel(handle, title, primary, secondary, \
77.1410 - default_action, account, who, conv, \
77.1411 - user_data, accept_cb, cancel_cb) \
77.1412 - purple_request_action((handle), (title), (primary), (secondary), \
77.1413 - (default_action), account, who, conv, (user_data), 2, \
77.1414 - _("_Accept"), (accept_cb), _("_Cancel"), (cancel_cb))
77.1415 -
77.1416 -/**
77.1417 - * Displays a file selector request dialog. Returns the selected filename to
77.1418 - * the callback. Can be used for either opening a file or saving a file.
77.1419 - *
77.1420 - * @param handle The plugin or connection handle. For some things this
77.1421 - * is <em>extremely</em> important. See the comments on
77.1422 - * purple_request_input().
77.1423 - * @param title The title of the message, or @c NULL if it should have
77.1424 - * no title.
77.1425 - * @param filename The default filename (may be @c NULL)
77.1426 - * @param savedialog True if this dialog is being used to save a file.
77.1427 - * False if it is being used to open a file.
77.1428 - * @param ok_cb The callback for the @c OK button.
77.1429 - * @param cancel_cb The callback for the @c Cancel button, which may be @c NULL.
77.1430 - * @param account The #PurpleAccount associated with this request, or @c
77.1431 - * NULL if none is
77.1432 - * @param who The username of the buddy associated with this request,
77.1433 - * or @c NULL if none is
77.1434 - * @param conv The #PurpleConversation associated with this request, or
77.1435 - * @c NULL if none is
77.1436 - * @param user_data The data to pass to the callback.
77.1437 - *
77.1438 - * @return A UI-specific handle.
77.1439 - */
77.1440 -void *purple_request_file(void *handle, const char *title, const char *filename,
77.1441 - gboolean savedialog, GCallback ok_cb, GCallback cancel_cb,
77.1442 - PurpleAccount *account, const char *who, PurpleConversation *conv,
77.1443 - void *user_data);
77.1444 -
77.1445 -/**
77.1446 - * Displays a folder select dialog. Returns the selected filename to
77.1447 - * the callback.
77.1448 - *
77.1449 - * @param handle The plugin or connection handle. For some things this
77.1450 - * is <em>extremely</em> important. See the comments on
77.1451 - * purple_request_input().
77.1452 - * @param title The title of the message, or @c NULL if it should have
77.1453 - * no title.
77.1454 - * @param dirname The default directory name (may be @c NULL)
77.1455 - * @param ok_cb The callback for the @c OK button.
77.1456 - * @param cancel_cb The callback for the @c Cancel button, which may be @c NULL.
77.1457 - * @param account The #PurpleAccount associated with this request, or @c
77.1458 - * NULL if none is
77.1459 - * @param who The username of the buddy associated with this request,
77.1460 - * or @c NULL if none is
77.1461 - * @param conv The #PurpleConversation associated with this request, or
77.1462 - * @c NULL if none is
77.1463 - * @param user_data The data to pass to the callback.
77.1464 - *
77.1465 - * @return A UI-specific handle.
77.1466 - */
77.1467 -void *purple_request_folder(void *handle, const char *title, const char *dirname,
77.1468 - GCallback ok_cb, GCallback cancel_cb,
77.1469 - PurpleAccount *account, const char *who, PurpleConversation *conv,
77.1470 - void *user_data);
77.1471 -
77.1472 -/*@}*/
77.1473 -
77.1474 -/**************************************************************************/
77.1475 -/** @name UI Registration Functions */
77.1476 -/**************************************************************************/
77.1477 -/*@{*/
77.1478 -
77.1479 -/**
77.1480 - * Sets the UI operations structure to be used when displaying a
77.1481 - * request.
77.1482 - *
77.1483 - * @param ops The UI operations structure.
77.1484 - */
77.1485 -void purple_request_set_ui_ops(PurpleRequestUiOps *ops);
77.1486 -
77.1487 -/**
77.1488 - * Returns the UI operations structure to be used when displaying a
77.1489 - * request.
77.1490 - *
77.1491 - * @return The UI operations structure.
77.1492 - */
77.1493 -PurpleRequestUiOps *purple_request_get_ui_ops(void);
77.1494 -
77.1495 -/*@}*/
77.1496 -
77.1497 -#ifdef __cplusplus
77.1498 -}
77.1499 -#endif
77.1500 -
77.1501 -#endif /* _PURPLE_REQUEST_H_ */
78.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/roomlist.h Sun Jun 21 22:04:11 2009 -0400
78.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
78.3 @@ -1,398 +0,0 @@
78.4 -/**
78.5 - * @file roomlist.h Room List API
78.6 - * @ingroup core
78.7 - */
78.8 -
78.9 -/* purple
78.10 - *
78.11 - * Purple is the legal property of its developers, whose names are too numerous
78.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
78.13 - * source distribution.
78.14 - *
78.15 - * This program is free software; you can redistribute it and/or modify
78.16 - * it under the terms of the GNU General Public License as published by
78.17 - * the Free Software Foundation; either version 2 of the License, or
78.18 - * (at your option) any later version.
78.19 - *
78.20 - * This program is distributed in the hope that it will be useful,
78.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
78.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
78.23 - * GNU General Public License for more details.
78.24 - *
78.25 - * You should have received a copy of the GNU General Public License
78.26 - * along with this program; if not, write to the Free Software
78.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
78.28 - */
78.29 -
78.30 -#ifndef _PURPLE_ROOMLIST_H_
78.31 -#define _PURPLE_ROOMLIST_H_
78.32 -
78.33 -typedef struct _PurpleRoomlist PurpleRoomlist;
78.34 -typedef struct _PurpleRoomlistRoom PurpleRoomlistRoom;
78.35 -typedef struct _PurpleRoomlistField PurpleRoomlistField;
78.36 -/** @copydoc _PurpleRoomlistUiOps */
78.37 -typedef struct _PurpleRoomlistUiOps PurpleRoomlistUiOps;
78.38 -
78.39 -/**
78.40 - * The types of rooms.
78.41 - *
78.42 - * These are ORable flags.
78.43 - */
78.44 -typedef enum
78.45 -{
78.46 - PURPLE_ROOMLIST_ROOMTYPE_CATEGORY = 0x01, /**< It's a category, but not a room you can join. */
78.47 - PURPLE_ROOMLIST_ROOMTYPE_ROOM = 0x02 /**< It's a room, like the kind you can join. */
78.48 -
78.49 -} PurpleRoomlistRoomType;
78.50 -
78.51 -/**
78.52 - * The types of fields.
78.53 - */
78.54 -typedef enum
78.55 -{
78.56 - PURPLE_ROOMLIST_FIELD_BOOL,
78.57 - PURPLE_ROOMLIST_FIELD_INT,
78.58 - PURPLE_ROOMLIST_FIELD_STRING /**< We do a g_strdup on the passed value if it's this type. */
78.59 -
78.60 -} PurpleRoomlistFieldType;
78.61 -
78.62 -#include "account.h"
78.63 -#include "glib.h"
78.64 -
78.65 -/**************************************************************************/
78.66 -/** Data Structures */
78.67 -/**************************************************************************/
78.68 -
78.69 -/**
78.70 - * Represents a list of rooms for a given connection on a given protocol.
78.71 - */
78.72 -struct _PurpleRoomlist {
78.73 - PurpleAccount *account; /**< The account this list belongs to. */
78.74 - GList *fields; /**< The fields. */
78.75 - GList *rooms; /**< The list of rooms. */
78.76 - gboolean in_progress; /**< The listing is in progress. */
78.77 - gpointer ui_data; /**< UI private data. */
78.78 - gpointer proto_data; /** Prpl private data. */
78.79 - guint ref; /**< The reference count. */
78.80 -};
78.81 -
78.82 -/**
78.83 - * Represents a room.
78.84 - */
78.85 -struct _PurpleRoomlistRoom {
78.86 - PurpleRoomlistRoomType type; /**< The type of room. */
78.87 - gchar *name; /**< The name of the room. */
78.88 - GList *fields; /**< Other fields. */
78.89 - PurpleRoomlistRoom *parent; /**< The parent room, or NULL. */
78.90 - gboolean expanded_once; /**< A flag the UI uses to avoid multiple expand prpl cbs. */
78.91 -};
78.92 -
78.93 -/**
78.94 - * A field a room might have.
78.95 - */
78.96 -struct _PurpleRoomlistField {
78.97 - PurpleRoomlistFieldType type; /**< The type of field. */
78.98 - gchar *label; /**< The i18n user displayed name of the field. */
78.99 - gchar *name; /**< The internal name of the field. */
78.100 - gboolean hidden; /**< Hidden? */
78.101 -};
78.102 -
78.103 -/**
78.104 - * The room list ops to be filled out by the UI.
78.105 - */
78.106 -struct _PurpleRoomlistUiOps {
78.107 - void (*show_with_account)(PurpleAccount *account); /**< Force the ui to pop up a dialog and get the list */
78.108 - void (*create)(PurpleRoomlist *list); /**< A new list was created. */
78.109 - void (*set_fields)(PurpleRoomlist *list, GList *fields); /**< Sets the columns. */
78.110 - void (*add_room)(PurpleRoomlist *list, PurpleRoomlistRoom *room); /**< Add a room to the list. */
78.111 - void (*in_progress)(PurpleRoomlist *list, gboolean flag); /**< Are we fetching stuff still? */
78.112 - void (*destroy)(PurpleRoomlist *list); /**< We're destroying list. */
78.113 -
78.114 - void (*_purple_reserved1)(void);
78.115 - void (*_purple_reserved2)(void);
78.116 - void (*_purple_reserved3)(void);
78.117 - void (*_purple_reserved4)(void);
78.118 -};
78.119 -
78.120 -
78.121 -#ifdef __cplusplus
78.122 -extern "C" {
78.123 -#endif
78.124 -
78.125 -/**************************************************************************/
78.126 -/** @name Room List API */
78.127 -/**************************************************************************/
78.128 -/*@{*/
78.129 -
78.130 -/**
78.131 - * This is used to get the room list on an account, asking the UI
78.132 - * to pop up a dialog with the specified account already selected,
78.133 - * and pretend the user clicked the get list button.
78.134 - * While we're pretending, predend I didn't say anything about dialogs
78.135 - * or buttons, since this is the core.
78.136 - *
78.137 - * @param account The account to get the list on.
78.138 - */
78.139 -void purple_roomlist_show_with_account(PurpleAccount *account);
78.140 -
78.141 -/**
78.142 - * Returns a newly created room list object.
78.143 - *
78.144 - * It has an initial reference count of 1.
78.145 - *
78.146 - * @param account The account that's listing rooms.
78.147 - * @return The new room list handle.
78.148 - */
78.149 -PurpleRoomlist *purple_roomlist_new(PurpleAccount *account);
78.150 -
78.151 -/**
78.152 - * Increases the reference count on the room list.
78.153 - *
78.154 - * @param list The object to ref.
78.155 - */
78.156 -void purple_roomlist_ref(PurpleRoomlist *list);
78.157 -
78.158 -/**
78.159 - * Decreases the reference count on the room list.
78.160 - *
78.161 - * The room list will be destroyed when this reaches 0.
78.162 - *
78.163 - * @param list The room list object to unref and possibly
78.164 - * destroy.
78.165 - */
78.166 -void purple_roomlist_unref(PurpleRoomlist *list);
78.167 -
78.168 -/**
78.169 - * Set the different field types and their names for this protocol.
78.170 - *
78.171 - * This must be called before purple_roomlist_room_add().
78.172 - *
78.173 - * @param list The room list.
78.174 - * @param fields A GList of PurpleRoomlistField's. UI's are encouraged
78.175 - * to default to displaying them in the order given.
78.176 - */
78.177 -void purple_roomlist_set_fields(PurpleRoomlist *list, GList *fields);
78.178 -
78.179 -/**
78.180 - * Set the "in progress" state of the room list.
78.181 - *
78.182 - * The UI is encouraged to somehow hint to the user
78.183 - * whether or not we're busy downloading a room list or not.
78.184 - *
78.185 - * @param list The room list.
78.186 - * @param in_progress We're downloading it, or we're not.
78.187 - */
78.188 -void purple_roomlist_set_in_progress(PurpleRoomlist *list, gboolean in_progress);
78.189 -
78.190 -/**
78.191 - * Gets the "in progress" state of the room list.
78.192 - *
78.193 - * The UI is encouraged to somehow hint to the user
78.194 - * whether or not we're busy downloading a room list or not.
78.195 - *
78.196 - * @param list The room list.
78.197 - * @return True if we're downloading it, or false if we're not.
78.198 - */
78.199 -gboolean purple_roomlist_get_in_progress(PurpleRoomlist *list);
78.200 -
78.201 -/**
78.202 - * Adds a room to the list of them.
78.203 - *
78.204 - * @param list The room list.
78.205 - * @param room The room to add to the list. The GList of fields must be in the same
78.206 - order as was given in purple_roomlist_set_fields().
78.207 -*/
78.208 -void purple_roomlist_room_add(PurpleRoomlist *list, PurpleRoomlistRoom *room);
78.209 -
78.210 -/**
78.211 - * Returns a PurpleRoomlist structure from the prpl, and
78.212 - * instructs the prpl to start fetching the list.
78.213 - *
78.214 - * @param gc The PurpleConnection to have get a list.
78.215 - *
78.216 - * @return A PurpleRoomlist* or @c NULL if the protocol
78.217 - * doesn't support that.
78.218 - */
78.219 -PurpleRoomlist *purple_roomlist_get_list(PurpleConnection *gc);
78.220 -
78.221 -/**
78.222 - * Tells the prpl to stop fetching the list.
78.223 - * If this is possible and done, the prpl will
78.224 - * call set_in_progress with @c FALSE and possibly
78.225 - * unref the list if it took a reference.
78.226 - *
78.227 - * @param list The room list to cancel a get_list on.
78.228 - */
78.229 -void purple_roomlist_cancel_get_list(PurpleRoomlist *list);
78.230 -
78.231 -/**
78.232 - * Tells the prpl that a category was expanded.
78.233 - *
78.234 - * On some protocols, the rooms in the category
78.235 - * won't be fetched until this is called.
78.236 - *
78.237 - * @param list The room list.
78.238 - * @param category The category that was expanded. The expression
78.239 - * (category->type & PURPLE_ROOMLIST_ROOMTYPE_CATEGORY)
78.240 - * must be true.
78.241 - */
78.242 -void purple_roomlist_expand_category(PurpleRoomlist *list, PurpleRoomlistRoom *category);
78.243 -
78.244 -/**
78.245 - * Get the list of fields for a roomlist.
78.246 - *
78.247 - * @param roomlist The roomlist, which must not be @c NULL.
78.248 - * @constreturn A list of fields
78.249 - * @since 2.4.0
78.250 - */
78.251 -GList * purple_roomlist_get_fields(PurpleRoomlist *roomlist);
78.252 -
78.253 -/*@}*/
78.254 -
78.255 -/**************************************************************************/
78.256 -/** @name Room API */
78.257 -/**************************************************************************/
78.258 -/*@{*/
78.259 -
78.260 -/**
78.261 - * Creates a new room, to be added to the list.
78.262 - *
78.263 - * @param type The type of room.
78.264 - * @param name The name of the room.
78.265 - * @param parent The room's parent, if any.
78.266 - *
78.267 - * @return A new room.
78.268 - */
78.269 -PurpleRoomlistRoom *purple_roomlist_room_new(PurpleRoomlistRoomType type, const gchar *name,
78.270 - PurpleRoomlistRoom *parent);
78.271 -
78.272 -/**
78.273 - * Adds a field to a room.
78.274 - *
78.275 - * @param list The room list the room belongs to.
78.276 - * @param room The room.
78.277 - * @param field The field to append. Strings get g_strdup'd internally.
78.278 - */
78.279 -void purple_roomlist_room_add_field(PurpleRoomlist *list, PurpleRoomlistRoom *room, gconstpointer field);
78.280 -
78.281 -/**
78.282 - * Join a room, given a PurpleRoomlistRoom and it's associated PurpleRoomlist.
78.283 - *
78.284 - * @param list The room list the room belongs to.
78.285 - * @param room The room to join.
78.286 - */
78.287 -void purple_roomlist_room_join(PurpleRoomlist *list, PurpleRoomlistRoom *room);
78.288 -
78.289 -/**
78.290 - * Get the type of a room.
78.291 - * @param room The room, which must not be @c NULL.
78.292 - * @return The type of the room.
78.293 - * @since 2.4.0
78.294 - */
78.295 -PurpleRoomlistRoomType purple_roomlist_room_get_type(PurpleRoomlistRoom *room);
78.296 -
78.297 -/**
78.298 - * Get the name of a room.
78.299 - * @param room The room, which must not be @c NULL.
78.300 - * @return The name of the room.
78.301 - * @since 2.4.0
78.302 - */
78.303 -const char * purple_roomlist_room_get_name(PurpleRoomlistRoom *room);
78.304 -
78.305 -/**
78.306 - * Get the parent of a room.
78.307 - * @param room The room, which must not be @c NULL.
78.308 - * @return The parent of the room, which can be @c NULL.
78.309 - * @since 2.4.0
78.310 - */
78.311 -PurpleRoomlistRoom * purple_roomlist_room_get_parent(PurpleRoomlistRoom *room);
78.312 -
78.313 -/**
78.314 - * Get the list of fields for a room.
78.315 - *
78.316 - * @param room The room, which must not be @c NULL.
78.317 - * @constreturn A list of fields
78.318 - * @since 2.4.0
78.319 - */
78.320 -GList * purple_roomlist_room_get_fields(PurpleRoomlistRoom *room);
78.321 -
78.322 -/*@}*/
78.323 -
78.324 -/**************************************************************************/
78.325 -/** @name Room Field API */
78.326 -/**************************************************************************/
78.327 -/*@{*/
78.328 -
78.329 -/**
78.330 - * Creates a new field.
78.331 - *
78.332 - * @param type The type of the field.
78.333 - * @param label The i18n'ed, user displayable name.
78.334 - * @param name The internal name of the field.
78.335 - * @param hidden Hide the field.
78.336 - *
78.337 - * @return A new PurpleRoomlistField, ready to be added to a GList and passed to
78.338 - * purple_roomlist_set_fields().
78.339 - */
78.340 -PurpleRoomlistField *purple_roomlist_field_new(PurpleRoomlistFieldType type,
78.341 - const gchar *label, const gchar *name,
78.342 - gboolean hidden);
78.343 -
78.344 -/**
78.345 - * Get the type of a field.
78.346 - *
78.347 - * @param field A PurpleRoomlistField, which must not be @c NULL.
78.348 - *
78.349 - * @return The type of the field.
78.350 - * @since 2.4.0
78.351 - */
78.352 -PurpleRoomlistFieldType purple_roomlist_field_get_type(PurpleRoomlistField *field);
78.353 -
78.354 -/**
78.355 - * Get the label of a field.
78.356 - *
78.357 - * @param field A PurpleRoomlistField, which must not be @c NULL.
78.358 - *
78.359 - * @return The label of the field.
78.360 - * @since 2.4.0
78.361 - */
78.362 -const char * purple_roomlist_field_get_label(PurpleRoomlistField *field);
78.363 -
78.364 -/**
78.365 - * Check whether a roomlist-field is hidden.
78.366 - * @param field A PurpleRoomlistField, which must not be @c NULL.
78.367 - *
78.368 - * @return @c TRUE if the field is hidden, @c FALSE otherwise.
78.369 - * @since 2.4.0
78.370 - */
78.371 -gboolean purple_roomlist_field_get_hidden(PurpleRoomlistField *field);
78.372 -
78.373 -/*@}*/
78.374 -
78.375 -/**************************************************************************/
78.376 -/** @name UI Registration Functions */
78.377 -/**************************************************************************/
78.378 -/*@{*/
78.379 -
78.380 -/**
78.381 - * Sets the UI operations structure to be used in all purple room lists.
78.382 - *
78.383 - * @param ops The UI operations structure.
78.384 - */
78.385 -void purple_roomlist_set_ui_ops(PurpleRoomlistUiOps *ops);
78.386 -
78.387 -/**
78.388 - * Returns the purple window UI operations structure to be used in
78.389 - * new windows.
78.390 - *
78.391 - * @return A filled-out PurpleRoomlistUiOps structure.
78.392 - */
78.393 -PurpleRoomlistUiOps *purple_roomlist_get_ui_ops(void);
78.394 -
78.395 -/*@}*/
78.396 -
78.397 -#ifdef __cplusplus
78.398 -}
78.399 -#endif
78.400 -
78.401 -#endif /* _PURPLE_ROOMLIST_H_ */
79.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/savedstatuses.h Sun Jun 21 22:04:11 2009 -0400
79.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
79.3 @@ -1,425 +0,0 @@
79.4 -/**
79.5 - * @file savedstatuses.h Saved Status API
79.6 - * @ingroup core
79.7 - * @see @ref savedstatus-signals
79.8 - */
79.9 -
79.10 -/* purple
79.11 - *
79.12 - * Purple is the legal property of its developers, whose names are too numerous
79.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
79.14 - * source distribution.
79.15 - *
79.16 - * This program is free software; you can redistribute it and/or modify
79.17 - * it under the terms of the GNU General Public License as published by
79.18 - * the Free Software Foundation; either version 2 of the License, or
79.19 - * (at your option) any later version.
79.20 - *
79.21 - * This program is distributed in the hope that it will be useful,
79.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
79.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
79.24 - * GNU General Public License for more details.
79.25 - *
79.26 - * You should have received a copy of the GNU General Public License
79.27 - * along with this program; if not, write to the Free Software
79.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
79.29 - */
79.30 -#ifndef _PURPLE_SAVEDSTATUSES_H_
79.31 -#define _PURPLE_SAVEDSTATUSES_H_
79.32 -
79.33 -/**
79.34 - * Saved statuses don't really interact much with the rest of Purple. It
79.35 - * could really be a plugin. It's just a list of away states. When
79.36 - * a user chooses one of the saved states, their Purple accounts are set
79.37 - * to the settings of that state.
79.38 - *
79.39 - * In the savedstatus API, there is the concept of a 'transient'
79.40 - * saved status. A transient saved status is one that is not
79.41 - * permanent. Purple will removed it automatically if it isn't
79.42 - * used for a period of time. Transient saved statuses don't
79.43 - * have titles and they don't show up in the list of saved
79.44 - * statuses. In fact, if a saved status does not have a title
79.45 - * then it is transient. If it does have a title, then it is not
79.46 - * transient.
79.47 - *
79.48 - * What good is a transient status, you ask? They can be used to
79.49 - * keep track of the user's 5 most recently used statuses, for
79.50 - * example. Basically if they just set a message on the fly,
79.51 - * we'll cache it for them in case they want to use it again. If
79.52 - * they don't use it again, we'll just delete it.
79.53 - */
79.54 -
79.55 -/*
79.56 - * TODO: Hmm. We should probably just be saving PurplePresences. That's
79.57 - * something we should look into once the status box gets fleshed
79.58 - * out more.
79.59 - */
79.60 -
79.61 -typedef struct _PurpleSavedStatus PurpleSavedStatus;
79.62 -typedef struct _PurpleSavedStatusSub PurpleSavedStatusSub;
79.63 -
79.64 -#include "status.h"
79.65 -
79.66 -#ifdef __cplusplus
79.67 -extern "C" {
79.68 -#endif
79.69 -
79.70 -/**************************************************************************/
79.71 -/** @name Saved status subsystem */
79.72 -/**************************************************************************/
79.73 -/*@{*/
79.74 -
79.75 -/**
79.76 - * Create a new saved status. This will add the saved status to the
79.77 - * list of saved statuses and writes the revised list to status.xml.
79.78 - *
79.79 - * @param title The title of the saved status. This must be
79.80 - * unique. Or, if you want to create a transient
79.81 - * saved status, then pass in NULL.
79.82 - * @param type The type of saved status.
79.83 - *
79.84 - * @return The newly created saved status, or NULL if the title you
79.85 - * used was already taken.
79.86 - */
79.87 -PurpleSavedStatus *purple_savedstatus_new(const char *title,
79.88 - PurpleStatusPrimitive type);
79.89 -
79.90 -/**
79.91 - * Set the title for the given saved status.
79.92 - *
79.93 - * @param status The saved status.
79.94 - * @param title The title of the saved status.
79.95 - */
79.96 -void purple_savedstatus_set_title(PurpleSavedStatus *status,
79.97 - const char *title);
79.98 -
79.99 -/**
79.100 - * Set the type for the given saved status.
79.101 - *
79.102 - * @param status The saved status.
79.103 - * @param type The type of saved status.
79.104 - */
79.105 -void purple_savedstatus_set_type(PurpleSavedStatus *status,
79.106 - PurpleStatusPrimitive type);
79.107 -
79.108 -/**
79.109 - * Set the message for the given saved status.
79.110 - *
79.111 - * @param status The saved status.
79.112 - * @param message The message, or NULL if you want to unset the
79.113 - * message for this status.
79.114 - */
79.115 -void purple_savedstatus_set_message(PurpleSavedStatus *status,
79.116 - const char *message);
79.117 -
79.118 -/**
79.119 - * Set a substatus for an account in a saved status.
79.120 - *
79.121 - * @param status The saved status.
79.122 - * @param account The account.
79.123 - * @param type The status type for the account in the staved
79.124 - * status.
79.125 - * @param message The message for the account in the substatus.
79.126 - */
79.127 -void purple_savedstatus_set_substatus(PurpleSavedStatus *status,
79.128 - const PurpleAccount *account,
79.129 - const PurpleStatusType *type,
79.130 - const char *message);
79.131 -
79.132 -/**
79.133 - * Unset a substatus for an account in a saved status. This clears
79.134 - * the previosly set substatus for the PurpleSavedStatus. If this
79.135 - * saved status is activated then this account will use the default
79.136 - * status type and message.
79.137 - *
79.138 - * @param saved_status The saved status.
79.139 - * @param account The account.
79.140 -*/
79.141 -void purple_savedstatus_unset_substatus(PurpleSavedStatus *saved_status,
79.142 - const PurpleAccount *account);
79.143 -
79.144 -/**
79.145 - * Delete a saved status. This removes the saved status from the list
79.146 - * of saved statuses, and writes the revised list to status.xml.
79.147 - *
79.148 - * @param title The title of the saved status.
79.149 - *
79.150 - * @return TRUE if the status was successfully deleted. FALSE if the
79.151 - * status could not be deleted because no saved status exists
79.152 - * with the given title.
79.153 - */
79.154 -gboolean purple_savedstatus_delete(const char *title);
79.155 -
79.156 -/**
79.157 - * Delete a saved status. This removes the saved status from the list
79.158 - * of saved statuses, and writes the revised list to status.xml.
79.159 - *
79.160 - * @param saved_status the status to delete, the pointer is invalid after
79.161 - * the call
79.162 - *
79.163 - */
79.164 -void purple_savedstatus_delete_by_status(PurpleSavedStatus *saved_status);
79.165 -
79.166 -/**
79.167 - * Returns all saved statuses.
79.168 - *
79.169 - * @constreturn A list of saved statuses.
79.170 - */
79.171 -GList *purple_savedstatuses_get_all(void);
79.172 -
79.173 -/**
79.174 - * Returns the n most popular saved statuses. "Popularity" is
79.175 - * determined by when the last time a saved_status was used and
79.176 - * how many times it has been used. Transient statuses without
79.177 - * messages are not included in the list.
79.178 - *
79.179 - * @param how_many The maximum number of saved statuses
79.180 - * to return, or '0' to get all saved
79.181 - * statuses sorted by popularity.
79.182 - * @return A linked list containing at most how_many
79.183 - * PurpleSavedStatuses. This list should be
79.184 - * g_list_free'd by the caller (but the
79.185 - * PurpleSavedStatuses must not be free'd).
79.186 - */
79.187 -GList *purple_savedstatuses_get_popular(unsigned int how_many);
79.188 -
79.189 -/**
79.190 - * Returns the currently selected saved status. If we are idle
79.191 - * then this returns purple_savedstatus_get_idleaway(). Otherwise
79.192 - * it returns purple_savedstatus_get_default().
79.193 - *
79.194 - * @return A pointer to the in-use PurpleSavedStatus.
79.195 - * This function never returns NULL.
79.196 - */
79.197 -PurpleSavedStatus *purple_savedstatus_get_current(void);
79.198 -
79.199 -/**
79.200 - * Returns the default saved status that is used when our
79.201 - * accounts are not idle-away.
79.202 - *
79.203 - * @return A pointer to the in-use PurpleSavedStatus.
79.204 - * This function never returns NULL.
79.205 - */
79.206 -PurpleSavedStatus *purple_savedstatus_get_default(void);
79.207 -
79.208 -/**
79.209 - * Returns the saved status that is used when your
79.210 - * accounts become idle-away.
79.211 - *
79.212 - * @return A pointer to the idle-away PurpleSavedStatus.
79.213 - * This function never returns NULL.
79.214 - */
79.215 -PurpleSavedStatus *purple_savedstatus_get_idleaway(void);
79.216 -
79.217 -/**
79.218 - * Return TRUE if we are currently idle-away. Otherwise
79.219 - * returns FALSE.
79.220 - *
79.221 - * @return TRUE if our accounts have been set to idle-away.
79.222 - */
79.223 -gboolean purple_savedstatus_is_idleaway(void);
79.224 -
79.225 -/**
79.226 - * Set whether accounts in Purple are idle-away or not.
79.227 - *
79.228 - * @param idleaway TRUE if accounts should be switched to use the
79.229 - * idle-away saved status. FALSE if they should
79.230 - * be switched to use the default status.
79.231 - */
79.232 -void purple_savedstatus_set_idleaway(gboolean idleaway);
79.233 -
79.234 -/**
79.235 - * Returns the status to be used when purple is starting up
79.236 - *
79.237 - * @return A pointer to the startup PurpleSavedStatus.
79.238 - * This function never returns NULL.
79.239 - */
79.240 -PurpleSavedStatus *purple_savedstatus_get_startup(void);
79.241 -
79.242 -/**
79.243 - * Finds a saved status with the specified title.
79.244 - *
79.245 - * @param title The name of the saved status.
79.246 - *
79.247 - * @return The saved status if found, or NULL.
79.248 - */
79.249 -PurpleSavedStatus *purple_savedstatus_find(const char *title);
79.250 -
79.251 -/**
79.252 - * Finds a saved status with the specified creation time.
79.253 - *
79.254 - * @param creation_time The timestamp when the saved
79.255 - * status was created.
79.256 - *
79.257 - * @return The saved status if found, or NULL.
79.258 - */
79.259 -PurpleSavedStatus *purple_savedstatus_find_by_creation_time(time_t creation_time);
79.260 -
79.261 -/**
79.262 - * Finds a saved status with the specified primitive and message.
79.263 - *
79.264 - * @param type The PurpleStatusPrimitive for the status you're trying
79.265 - * to find.
79.266 - * @param message The message for the status you're trying
79.267 - * to find.
79.268 - *
79.269 - * @return The saved status if found, or NULL.
79.270 - */
79.271 -PurpleSavedStatus *purple_savedstatus_find_transient_by_type_and_message(PurpleStatusPrimitive type, const char *message);
79.272 -
79.273 -/**
79.274 - * Determines if a given saved status is "transient."
79.275 - * A transient saved status is one that was not
79.276 - * explicitly added by the user. Transient statuses
79.277 - * are automatically removed if they are not used
79.278 - * for a period of time.
79.279 - *
79.280 - * A transient saved statuses is automatically
79.281 - * created by the status box when the user sets himself
79.282 - * to one of the generic primitive statuses. The reason
79.283 - * we need to save this status information is so we can
79.284 - * restore it when Purple restarts.
79.285 - *
79.286 - * @param saved_status The saved status.
79.287 - *
79.288 - * @return TRUE if the saved status is transient.
79.289 - */
79.290 -gboolean purple_savedstatus_is_transient(const PurpleSavedStatus *saved_status);
79.291 -
79.292 -/**
79.293 - * Return the name of a given saved status.
79.294 - *
79.295 - * @param saved_status The saved status.
79.296 - *
79.297 - * @return The title. This value may be a static buffer which may
79.298 - * be overwritten on subsequent calls to this function. If
79.299 - * you need a reference to the title for prolonged use then
79.300 - * you should make a copy of it.
79.301 - */
79.302 -const char *purple_savedstatus_get_title(const PurpleSavedStatus *saved_status);
79.303 -
79.304 -/**
79.305 - * Return the type of a given saved status.
79.306 - *
79.307 - * @param saved_status The saved status.
79.308 - *
79.309 - * @return The name.
79.310 - */
79.311 -PurpleStatusPrimitive purple_savedstatus_get_type(const PurpleSavedStatus *saved_status);
79.312 -
79.313 -/**
79.314 - * Return the default message of a given saved status.
79.315 - *
79.316 - * @param saved_status The saved status.
79.317 - *
79.318 - * @return The message. This will return NULL if the saved
79.319 - * status does not have a message. This will
79.320 - * contain the normal markup that is created by
79.321 - * Purple's IMHTML (basically HTML markup).
79.322 - */
79.323 -const char *purple_savedstatus_get_message(const PurpleSavedStatus *saved_status);
79.324 -
79.325 -/**
79.326 - * Return the time in seconds-since-the-epoch when this
79.327 - * saved status was created. Note: For any status created
79.328 - * by Purple 1.5.0 or older this value will be invalid and
79.329 - * very small (close to 0). This is because Purple 1.5.0
79.330 - * and older did not record the timestamp when the status
79.331 - * was created.
79.332 - *
79.333 - * However, this value is guaranteed to be a unique
79.334 - * identifier for the given saved status.
79.335 - *
79.336 - * @param saved_status The saved status.
79.337 - *
79.338 - * @return The timestamp when this saved status was created.
79.339 - */
79.340 -time_t purple_savedstatus_get_creation_time(const PurpleSavedStatus *saved_status);
79.341 -
79.342 -/**
79.343 - * Determine if a given saved status has "substatuses,"
79.344 - * or if it is a simple status (the same for all
79.345 - * accounts).
79.346 - *
79.347 - * @param saved_status The saved status.
79.348 - *
79.349 - * @return TRUE if the saved_status has substatuses.
79.350 - * FALSE otherwise.
79.351 - */
79.352 -gboolean purple_savedstatus_has_substatuses(const PurpleSavedStatus *saved_status);
79.353 -
79.354 -/**
79.355 - * Get the substatus for an account in a saved status.
79.356 - *
79.357 - * @param saved_status The saved status.
79.358 - * @param account The account.
79.359 - *
79.360 - * @return The PurpleSavedStatusSub for the account, or NULL if
79.361 - * the given account does not have a substatus that
79.362 - * differs from the default status of this PurpleSavedStatus.
79.363 - */
79.364 -PurpleSavedStatusSub *purple_savedstatus_get_substatus(
79.365 - const PurpleSavedStatus *saved_status,
79.366 - const PurpleAccount *account);
79.367 -
79.368 -/**
79.369 - * Get the status type of a given substatus.
79.370 - *
79.371 - * @param substatus The substatus.
79.372 - *
79.373 - * @return The status type.
79.374 - */
79.375 -const PurpleStatusType *purple_savedstatus_substatus_get_type(const PurpleSavedStatusSub *substatus);
79.376 -
79.377 -/**
79.378 - * Get the message of a given substatus.
79.379 - *
79.380 - * @param substatus The substatus.
79.381 - *
79.382 - * @return The message of the substatus, or NULL if this substatus does
79.383 - * not have a message.
79.384 - */
79.385 -const char *purple_savedstatus_substatus_get_message(const PurpleSavedStatusSub *substatus);
79.386 -
79.387 -/**
79.388 - * Sets the statuses for all your accounts to those specified
79.389 - * by the given saved_status. This function calls
79.390 - * purple_savedstatus_activate_for_account() for all your accounts.
79.391 - *
79.392 - * @param saved_status The status you want to set your accounts to.
79.393 - */
79.394 -void purple_savedstatus_activate(PurpleSavedStatus *saved_status);
79.395 -
79.396 -/**
79.397 - * Sets the statuses for a given account to those specified
79.398 - * by the given saved_status.
79.399 - *
79.400 - * @param saved_status The status you want to set your accounts to.
79.401 - * @param account The account whose statuses you want to change.
79.402 - */
79.403 -void purple_savedstatus_activate_for_account(const PurpleSavedStatus *saved_status, PurpleAccount *account);
79.404 -
79.405 -/**
79.406 - * Get the handle for the status subsystem.
79.407 - *
79.408 - * @return the handle to the status subsystem
79.409 - */
79.410 -void *purple_savedstatuses_get_handle(void);
79.411 -
79.412 -/**
79.413 - * Initializes the status subsystem.
79.414 - */
79.415 -void purple_savedstatuses_init(void);
79.416 -
79.417 -/**
79.418 - * Uninitializes the status subsystem.
79.419 - */
79.420 -void purple_savedstatuses_uninit(void);
79.421 -
79.422 -/*@}*/
79.423 -
79.424 -#ifdef __cplusplus
79.425 -}
79.426 -#endif
79.427 -
79.428 -#endif /* _PURPLE_SAVEDSTATUSES_H_ */
80.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/search.h Sun Jun 21 22:04:11 2009 -0400
80.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
80.3 @@ -1,153 +0,0 @@
80.4 -/**
80.5 - * @file search.h
80.6 - *
80.7 - * purple
80.8 - *
80.9 - * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
80.10 - *
80.11 - * This program is free software; you can redistribute it and/or modify
80.12 - * it under the terms of the GNU General Public License as published by
80.13 - * the Free Software Foundation; either version 2 of the License, or
80.14 - * (at your option) any later version.
80.15 - *
80.16 - * This program is distributed in the hope that it will be useful,
80.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
80.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
80.19 - * GNU General Public License for more details.
80.20 - *
80.21 - * You should have received a copy of the GNU General Public License
80.22 - * along with this program; if not, write to the Free Software
80.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
80.24 - */
80.25 -
80.26 -
80.27 -#ifndef _PURPLE_GG_SEARCH_H
80.28 -#define _PURPLE_GG_SEARCH_H
80.29 -
80.30 -#include "connection.h"
80.31 -
80.32 -#include <libgadu.h>
80.33 -#include "gg.h"
80.34 -
80.35 -
80.36 -typedef enum {
80.37 - GGP_SEARCH_TYPE_INFO,
80.38 - GGP_SEARCH_TYPE_FULL
80.39 -
80.40 -} GGPSearchType;
80.41 -
80.42 -typedef struct {
80.43 -
80.44 - char *uin;
80.45 - char *lastname;
80.46 - char *firstname;
80.47 - char *nickname;
80.48 - char *city;
80.49 - char *birthyear;
80.50 - char *gender;
80.51 - char *active;
80.52 - char *offset;
80.53 -
80.54 - char *last_uin;
80.55 -
80.56 - GGPSearchType search_type;
80.57 - guint32 seq;
80.58 -
80.59 - void *user_data;
80.60 - void *window;
80.61 -} GGPSearchForm;
80.62 -
80.63 -typedef GHashTable GGPSearches;
80.64 -
80.65 -
80.66 -/**
80.67 - * Create a new GGPSearchForm structure, and set the fields
80.68 - * to the sane defaults.
80.69 - *
80.70 - * @return Newly allocated GGPSearchForm.
80.71 - */
80.72 -GGPSearchForm *
80.73 -ggp_search_form_new(GGPSearchType st);
80.74 -
80.75 -/**
80.76 - * Destroy a Search Form.
80.77 - *
80.78 - * @param form Search Form to destroy.
80.79 - */
80.80 -void
80.81 -ggp_search_form_destroy(GGPSearchForm *form);
80.82 -
80.83 -/**
80.84 - * Add a search to the list of searches.
80.85 - *
80.86 - * @param searches The list of searches.
80.87 - * @param seq Search (form) ID number.
80.88 - * @param form The search form to add.
80.89 - */
80.90 -void
80.91 -ggp_search_add(GGPSearches *searches, guint32 seq, GGPSearchForm *form);
80.92 -
80.93 -/**
80.94 - * Remove a search from the list.
80.95 - *
80.96 - * If you want to destory the search completely also call:
80.97 - * ggp_search_form_destroy().
80.98 - *
80.99 - * @param searches The list of searches.
80.100 - * @param seq ID number of the search.
80.101 - */
80.102 -void
80.103 -ggp_search_remove(GGPSearches *searches, guint32 seq);
80.104 -
80.105 -/**
80.106 - * Return the search with the specified ID.
80.107 - *
80.108 - * @param searches The list of searches.
80.109 - * @param seq ID number of the search.
80.110 - */
80.111 -GGPSearchForm *
80.112 -ggp_search_get(GGPSearches *searches, guint32 seq);
80.113 -
80.114 -/**
80.115 - * Create a new GGPSearches structure.
80.116 - *
80.117 - * @return GGPSearches instance.
80.118 - */
80.119 -GGPSearches *
80.120 -ggp_search_new(void);
80.121 -
80.122 -/**
80.123 - * Destroy GGPSearches instance.
80.124 - *
80.125 - * @param searches GGPSearches instance.
80.126 - */
80.127 -void
80.128 -ggp_search_destroy(GGPSearches *searches);
80.129 -
80.130 -/**
80.131 - * Initiate a search in the public directory.
80.132 - *
80.133 - * @param gc PurpleConnection.
80.134 - * @param form Filled in GGPSearchForm.
80.135 - *
80.136 - * @return Sequence number of a search or 0 if an error occurred.
80.137 - */
80.138 -guint32
80.139 -ggp_search_start(PurpleConnection *gc, GGPSearchForm *form);
80.140 -
80.141 -/*
80.142 - * Return converted to the UTF-8 value of the specified field.
80.143 - *
80.144 - * @param res Public directory look-up result.
80.145 - * @param num Id of the record.
80.146 - * @param fileld Name of the field.
80.147 - *
80.148 - * @return UTF-8 encoded value of the field.
80.149 - */
80.150 -char *
80.151 -ggp_search_get_result(gg_pubdir50_t res, int num, const char *field);
80.152 -
80.153 -
80.154 -#endif /* _PURPLE_GG_SEARCH_H */
80.155 -
80.156 -/* vim: set ts=8 sts=0 sw=8 noet: */
81.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/servconn.h Sun Jun 21 22:04:11 2009 -0400
81.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
81.3 @@ -1,181 +0,0 @@
81.4 -/**
81.5 - * @file servconn.h Server connection functions
81.6 - *
81.7 - * purple
81.8 - *
81.9 - * Purple is the legal property of its developers, whose names are too numerous
81.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
81.11 - * source distribution.
81.12 - *
81.13 - * This program is free software; you can redistribute it and/or modify
81.14 - * it under the terms of the GNU General Public License as published by
81.15 - * the Free Software Foundation; either version 2 of the License, or
81.16 - * (at your option) any later version.
81.17 - *
81.18 - * This program is distributed in the hope that it will be useful,
81.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
81.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
81.21 - * GNU General Public License for more details.
81.22 - *
81.23 - * You should have received a copy of the GNU General Public License
81.24 - * along with this program; if not, write to the Free Software
81.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
81.26 - */
81.27 -#ifndef _MSN_SERVCONN_H_
81.28 -#define _MSN_SERVCONN_H_
81.29 -
81.30 -typedef struct _MsnServConn MsnServConn;
81.31 -
81.32 -#include "session.h"
81.33 -#include "cmdproc.h"
81.34 -
81.35 -#include "proxy.h"
81.36 -#include "httpconn.h"
81.37 -
81.38 -/**
81.39 - * Connection error types.
81.40 - */
81.41 -typedef enum
81.42 -{
81.43 - MSN_SERVCONN_ERROR_NONE,
81.44 - MSN_SERVCONN_ERROR_CONNECT,
81.45 - MSN_SERVCONN_ERROR_WRITE,
81.46 - MSN_SERVCONN_ERROR_READ
81.47 -
81.48 -} MsnServConnError;
81.49 -
81.50 -/**
81.51 - * Connection types.
81.52 - */
81.53 -typedef enum
81.54 -{
81.55 - MSN_SERVCONN_NS,
81.56 - MSN_SERVCONN_SB
81.57 -
81.58 -} MsnServConnType;
81.59 -
81.60 -/**
81.61 - * A Connection.
81.62 - */
81.63 -struct _MsnServConn
81.64 -{
81.65 - MsnServConnType type; /**< The type of this connection. */
81.66 - MsnSession *session; /**< The MSN session of this connection. */
81.67 - MsnCmdProc *cmdproc; /**< The command processor of this connection. */
81.68 -
81.69 - PurpleProxyConnectData *connect_data;
81.70 -
81.71 - gboolean connected; /**< A flag that states if it's connected. */
81.72 - gboolean processing; /**< A flag that states if something is working
81.73 - with this connection. */
81.74 - gboolean wasted; /**< A flag that states if it should be destroyed. */
81.75 -
81.76 - char *host; /**< The host this connection is connected or should be
81.77 - connected to. */
81.78 - int num; /**< A number id of this connection. */
81.79 -
81.80 - MsnHttpConn *httpconn; /**< The HTTP connection this connection should use. */
81.81 -
81.82 - int fd; /**< The connection's file descriptor. */
81.83 - int inpa; /**< The connection's input handler. */
81.84 -
81.85 - char *rx_buf; /**< The receive buffer. */
81.86 - int rx_len; /**< The receive buffer lenght. */
81.87 -
81.88 - size_t payload_len; /**< The length of the payload.
81.89 - It's only set when we've received a command that
81.90 - has a payload. */
81.91 -
81.92 - PurpleCircBuffer *tx_buf;
81.93 - guint tx_handler;
81.94 -
81.95 - void (*connect_cb)(MsnServConn *); /**< The callback to call when connecting. */
81.96 - void (*disconnect_cb)(MsnServConn *); /**< The callback to call when disconnecting. */
81.97 - void (*destroy_cb)(MsnServConn *); /**< The callback to call when destroying. */
81.98 -};
81.99 -
81.100 -/**
81.101 - * Creates a new connection object.
81.102 - *
81.103 - * @param session The session.
81.104 - * @param type The type of the connection.
81.105 - */
81.106 -MsnServConn *msn_servconn_new(MsnSession *session, MsnServConnType type);
81.107 -
81.108 -/**
81.109 - * Destroys a connection object.
81.110 - *
81.111 - * @param servconn The connection.
81.112 - */
81.113 -void msn_servconn_destroy(MsnServConn *servconn);
81.114 -
81.115 -/**
81.116 - * Connects to a host.
81.117 - *
81.118 - * @param servconn The connection.
81.119 - * @param host The host.
81.120 - * @param port The port.
81.121 - * @param force Force this servconn to connect to a new server.
81.122 - */
81.123 -gboolean msn_servconn_connect(MsnServConn *servconn, const char *host, int port,
81.124 - gboolean force);
81.125 -
81.126 -/**
81.127 - * Disconnects.
81.128 - *
81.129 - * @param servconn The connection.
81.130 - */
81.131 -void msn_servconn_disconnect(MsnServConn *servconn);
81.132 -
81.133 -/**
81.134 - * Sets the connect callback.
81.135 - *
81.136 - * @param servconn The servconn.
81.137 - * @param connect_cb The connect callback.
81.138 - */
81.139 -void msn_servconn_set_connect_cb(MsnServConn *servconn,
81.140 - void (*connect_cb)(MsnServConn *));
81.141 -/**
81.142 - * Sets the disconnect callback.
81.143 - *
81.144 - * @param servconn The servconn.
81.145 - * @param disconnect_cb The disconnect callback.
81.146 - */
81.147 -void msn_servconn_set_disconnect_cb(MsnServConn *servconn,
81.148 - void (*disconnect_cb)(MsnServConn *));
81.149 -/**
81.150 - * Sets the destroy callback.
81.151 - *
81.152 - * @param servconn The servconn that's being destroyed.
81.153 - * @param destroy_cb The destroy callback.
81.154 - */
81.155 -void msn_servconn_set_destroy_cb(MsnServConn *servconn,
81.156 - void (*destroy_cb)(MsnServConn *));
81.157 -
81.158 -/**
81.159 - * Writes a chunck of data to the servconn.
81.160 - *
81.161 - * @param servconn The servconn.
81.162 - * @param buf The data to write.
81.163 - * @param size The size of the data.
81.164 - */
81.165 -gssize msn_servconn_write(MsnServConn *servconn, const char *buf,
81.166 - size_t size);
81.167 -
81.168 -/**
81.169 - * Function to call whenever an error related to a switchboard occurs.
81.170 - *
81.171 - * @param servconn The servconn.
81.172 - * @param error The error that happened.
81.173 - */
81.174 -void msn_servconn_got_error(MsnServConn *servconn, MsnServConnError error);
81.175 -
81.176 -/**
81.177 - * Process the data in servconn->rx_buf. This is called after reading
81.178 - * data from the socket.
81.179 - *
81.180 - * @param servconn The servconn.
81.181 - */
81.182 -void msn_servconn_process_data(MsnServConn *servconn);
81.183 -
81.184 -#endif /* _MSN_SERVCONN_H_ */
82.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/server.h Sun Jun 21 22:04:11 2009 -0400
82.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
82.3 @@ -1,193 +0,0 @@
82.4 -/**
82.5 - * @file server.h Server API
82.6 - * @ingroup core
82.7 - */
82.8 -
82.9 -/* purple
82.10 - *
82.11 - * Purple is the legal property of its developers, whose names are too numerous
82.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
82.13 - * source distribution.
82.14 - *
82.15 - * This program is free software; you can redistribute it and/or modify
82.16 - * it under the terms of the GNU General Public License as published by
82.17 - * the Free Software Foundation; either version 2 of the License, or
82.18 - * (at your option) any later version.
82.19 - *
82.20 - * This program is distributed in the hope that it will be useful,
82.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
82.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
82.23 - * GNU General Public License for more details.
82.24 - *
82.25 - * You should have received a copy of the GNU General Public License
82.26 - * along with this program; if not, write to the Free Software
82.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
82.28 - */
82.29 -#ifndef _PURPLE_SERVER_H_
82.30 -#define _PURPLE_SERVER_H_
82.31 -
82.32 -#include "account.h"
82.33 -#include "conversation.h"
82.34 -#include "prpl.h"
82.35 -
82.36 -#ifdef __cplusplus
82.37 -extern "C" {
82.38 -#endif
82.39 -
82.40 -/**
82.41 - * Send a typing message to a given user over a given connection.
82.42 - *
82.43 - * TODO: Could probably move this into the conversation API.
82.44 - *
82.45 - * @param gc The connection over which to send the typing notification.
82.46 - * @param name The user to send the typing notification to.
82.47 - * @param state One of PURPLE_TYPING, PURPLE_TYPED, or PURPLE_NOT_TYPING.
82.48 - * @return A quiet-period, specified in seconds, where Purple will not
82.49 - * send any additional typing notification messages. Most
82.50 - * protocols should return 0, which means that no additional
82.51 - * PURPLE_TYPING messages need to be sent. If this is 5, for
82.52 - * example, then Purple will wait five seconds, and if the Purple
82.53 - * user is still typing then Purple will send another PURPLE_TYPING
82.54 - * message.
82.55 - */
82.56 -unsigned int serv_send_typing(PurpleConnection *gc, const char *name, PurpleTypingState state);
82.57 -
82.58 -void serv_move_buddy(PurpleBuddy *, PurpleGroup *, PurpleGroup *);
82.59 -int serv_send_im(PurpleConnection *, const char *, const char *, PurpleMessageFlags flags);
82.60 -
82.61 -/** Get information about an account's attention commands, from the prpl.
82.62 - *
82.63 - * @return The attention command numbered 'code' from the prpl's attention_types, or NULL.
82.64 - */
82.65 -PurpleAttentionType *purple_get_attention_type_from_code(PurpleAccount *account, guint type_code);
82.66 -
82.67 -/** Send an attention request message.
82.68 - *
82.69 - * @deprecated Use purple_prpl_send_attention() instead.
82.70 - *
82.71 - * @param gc The connection to send the message on.
82.72 - * @param who Whose attention to request.
82.73 - * @param type_code An index into the prpl's attention_types list determining the type
82.74 - * of the attention request command to send. 0 if prpl only defines one
82.75 - * (for example, Yahoo and MSN), but some protocols define more (MySpaceIM).
82.76 - *
82.77 - * Note that you can't send arbitrary PurpleAttentionType's, because there is
82.78 - * only a fixed set of attention commands.
82.79 - */
82.80 -void serv_send_attention(PurpleConnection *gc, const char *who, guint type_code);
82.81 -
82.82 -/** Process an incoming attention message.
82.83 - *
82.84 - * @deprecated Use purple_prpl_got_attention() instead.
82.85 - *
82.86 - * @param gc The connection that received the attention message.
82.87 - * @param who Who requested your attention.
82.88 - * @param type_code An index into the prpl's attention_types list determining the type
82.89 - * of the attention request command to send.
82.90 - */
82.91 -void serv_got_attention(PurpleConnection *gc, const char *who, guint type_code);
82.92 -
82.93 -void serv_get_info(PurpleConnection *, const char *);
82.94 -void serv_set_info(PurpleConnection *, const char *);
82.95 -
82.96 -void serv_add_permit(PurpleConnection *, const char *);
82.97 -void serv_add_deny(PurpleConnection *, const char *);
82.98 -void serv_rem_permit(PurpleConnection *, const char *);
82.99 -void serv_rem_deny(PurpleConnection *, const char *);
82.100 -void serv_set_permit_deny(PurpleConnection *);
82.101 -void serv_chat_invite(PurpleConnection *, int, const char *, const char *);
82.102 -void serv_chat_leave(PurpleConnection *, int);
82.103 -void serv_chat_whisper(PurpleConnection *, int, const char *, const char *);
82.104 -int serv_chat_send(PurpleConnection *, int, const char *, PurpleMessageFlags flags);
82.105 -void serv_alias_buddy(PurpleBuddy *);
82.106 -void serv_got_alias(PurpleConnection *gc, const char *who, const char *alias);
82.107 -
82.108 -/**
82.109 - * A protocol plugin should call this when it retrieves a private alias from
82.110 - * the server. Private aliases are the aliases the user sets, while public
82.111 - * aliases are the aliases or display names that buddies set for themselves.
82.112 - *
82.113 - * @param gc The connection on which the alias was received.
82.114 - * @param who The screen name of the buddy whose alias was received.
82.115 - * @param alias The alias that was received.
82.116 - */
82.117 -void purple_serv_got_private_alias(PurpleConnection *gc, const char *who, const char *alias);
82.118 -
82.119 -
82.120 -/**
82.121 - * Receive a typing message from a remote user. Either PURPLE_TYPING
82.122 - * or PURPLE_TYPED. If the user has stopped typing then use
82.123 - * serv_got_typing_stopped instead.
82.124 - *
82.125 - * TODO: Could probably move this into the conversation API.
82.126 - *
82.127 - * @param gc The connection on which the typing message was received.
82.128 - * @param name The name of the remote user.
82.129 - * @param timeout If this is a number greater than 0, then
82.130 - * Purple will wait this number of seconds and then
82.131 - * set this buddy to the PURPLE_NOT_TYPING state. This
82.132 - * is used by protocols that send repeated typing messages
82.133 - * while the user is composing the message.
82.134 - * @param state The typing state received
82.135 - */
82.136 -void serv_got_typing(PurpleConnection *gc, const char *name, int timeout,
82.137 - PurpleTypingState state);
82.138 -
82.139 -/**
82.140 - * TODO: Could probably move this into the conversation API.
82.141 - */
82.142 -void serv_got_typing_stopped(PurpleConnection *gc, const char *name);
82.143 -
82.144 -void serv_got_im(PurpleConnection *gc, const char *who, const char *msg,
82.145 - PurpleMessageFlags flags, time_t mtime);
82.146 -
82.147 -/**
82.148 - * @param data The hash function should be g_str_hash() and the equal
82.149 - * function should be g_str_equal().
82.150 - */
82.151 -void serv_join_chat(PurpleConnection *, GHashTable *data);
82.152 -
82.153 -/**
82.154 - * @param data The hash function should be g_str_hash() and the equal
82.155 - * function should be g_str_equal().
82.156 - */
82.157 -void serv_reject_chat(PurpleConnection *, GHashTable *data);
82.158 -
82.159 -/**
82.160 - * Called by a prpl when an account is invited into a chat.
82.161 - *
82.162 - * @param gc The connection on which the invite arrived.
82.163 - * @param name The name of the chat you're being invited to.
82.164 - * @param who The username of the person inviting the account.
82.165 - * @param message The optional invite message.
82.166 - * @param data The components necessary if you want to call serv_join_chat().
82.167 - * The hash function should be g_str_hash() and the equal
82.168 - * function should be g_str_equal().
82.169 - */
82.170 -void serv_got_chat_invite(PurpleConnection *gc, const char *name,
82.171 - const char *who, const char *message,
82.172 - GHashTable *data);
82.173 -
82.174 -PurpleConversation *serv_got_joined_chat(PurpleConnection *gc,
82.175 - int id, const char *name);
82.176 -/**
82.177 - * Called by a prpl when an attempt to join a chat via serv_join_chat()
82.178 - * fails.
82.179 - *
82.180 - * @param gc The connection on which chat joining failed
82.181 - * @param data The components passed to serv_join_chat() originally.
82.182 - * The hash function should be g_str_hash() and the equal
82.183 - * function should be g_str_equal().
82.184 - */
82.185 -void purple_serv_got_join_chat_failed(PurpleConnection *gc, GHashTable *data);
82.186 -
82.187 -void serv_got_chat_left(PurpleConnection *g, int id);
82.188 -void serv_got_chat_in(PurpleConnection *g, int id, const char *who,
82.189 - PurpleMessageFlags flags, const char *message, time_t mtime);
82.190 -void serv_send_file(PurpleConnection *gc, const char *who, const char *file);
82.191 -
82.192 -#ifdef __cplusplus
82.193 -}
82.194 -#endif
82.195 -
82.196 -#endif /* _PURPLE_SERVER_H_ */
83.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/session.h Sun Jun 21 22:04:11 2009 -0400
83.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
83.3 @@ -1,242 +0,0 @@
83.4 -/**
83.5 - * @file session.h MSN session functions
83.6 - *
83.7 - * purple
83.8 - *
83.9 - * Purple is the legal property of its developers, whose names are too numerous
83.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
83.11 - * source distribution.
83.12 - *
83.13 - * This program is free software; you can redistribute it and/or modify
83.14 - * it under the terms of the GNU General Public License as published by
83.15 - * the Free Software Foundation; either version 2 of the License, or
83.16 - * (at your option) any later version.
83.17 - *
83.18 - * This program is distributed in the hope that it will be useful,
83.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
83.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
83.21 - * GNU General Public License for more details.
83.22 - *
83.23 - * You should have received a copy of the GNU General Public License
83.24 - * along with this program; if not, write to the Free Software
83.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
83.26 - */
83.27 -#ifndef _MSN_SESSION_H_
83.28 -#define _MSN_SESSION_H_
83.29 -
83.30 -typedef struct _MsnSession MsnSession;
83.31 -
83.32 -#include "sslconn.h"
83.33 -
83.34 -#include "user.h"
83.35 -#include "slpcall.h"
83.36 -
83.37 -#include "notification.h"
83.38 -#include "switchboard.h"
83.39 -#include "group.h"
83.40 -
83.41 -#include "cmdproc.h"
83.42 -#include "nexus.h"
83.43 -#include "httpconn.h"
83.44 -#include "oim.h"
83.45 -
83.46 -#include "userlist.h"
83.47 -#include "sync.h"
83.48 -
83.49 -/**
83.50 - * Types of errors.
83.51 - */
83.52 -typedef enum
83.53 -{
83.54 - MSN_ERROR_SERVCONN,
83.55 - MSN_ERROR_UNSUPPORTED_PROTOCOL,
83.56 - MSN_ERROR_HTTP_MALFORMED,
83.57 - MSN_ERROR_AUTH,
83.58 - MSN_ERROR_BAD_BLIST,
83.59 - MSN_ERROR_SIGN_OTHER,
83.60 - MSN_ERROR_SERV_DOWN,
83.61 - MSN_ERROR_SERV_UNAVAILABLE
83.62 -
83.63 -} MsnErrorType;
83.64 -
83.65 -/**
83.66 - * Login steps.
83.67 - */
83.68 -typedef enum
83.69 -{
83.70 - MSN_LOGIN_STEP_START,
83.71 - MSN_LOGIN_STEP_HANDSHAKE,
83.72 - MSN_LOGIN_STEP_TRANSFER,
83.73 - MSN_LOGIN_STEP_HANDSHAKE2,
83.74 - MSN_LOGIN_STEP_AUTH_START,
83.75 - MSN_LOGIN_STEP_AUTH,
83.76 - MSN_LOGIN_STEP_GET_COOKIE,
83.77 - MSN_LOGIN_STEP_AUTH_END,
83.78 - MSN_LOGIN_STEP_SYN,
83.79 - MSN_LOGIN_STEP_END
83.80 -
83.81 -} MsnLoginStep;
83.82 -
83.83 -#define MSN_LOGIN_STEPS MSN_LOGIN_STEP_END
83.84 -
83.85 -struct _MsnSession
83.86 -{
83.87 - PurpleAccount *account;
83.88 - MsnUser *user;
83.89 -
83.90 - guint protocol_ver;
83.91 -
83.92 - MsnLoginStep login_step; /**< The current step in the login process. */
83.93 -
83.94 - gboolean connected;
83.95 - gboolean logged_in; /**< A temporal flag to ignore local buddy list adds. */
83.96 - int adl_fqy; /**< A count of ADL/FQY so status is only changed once. */
83.97 - gboolean destroying; /**< A flag that states if the session is being destroyed. */
83.98 - gboolean http_method;
83.99 -
83.100 - MsnNotification *notification;
83.101 - MsnNexus *nexus;
83.102 - MsnOim *oim;
83.103 - MsnSync *sync;
83.104 - MsnUserList *userlist;
83.105 - char *abch_cachekey;
83.106 -
83.107 - int servconns_count; /**< The count of server connections. */
83.108 - GList *switches; /**< The list of all the switchboards. */
83.109 - GList *slplinks; /**< The list of all the slplinks. */
83.110 -
83.111 - /*psm info*/
83.112 - char *psm;
83.113 -
83.114 -#if 0
83.115 - char *blocked_text;
83.116 -#endif
83.117 -
83.118 - struct
83.119 - {
83.120 - char *kv;
83.121 - char *sid;
83.122 - char *mspauth;
83.123 - unsigned long sl;
83.124 - char *client_ip;
83.125 - int client_port;
83.126 - char *mail_url;
83.127 - gulong mail_timestamp;
83.128 - gboolean email_enabled;
83.129 - } passport_info;
83.130 -
83.131 - GHashTable *soap_table;
83.132 - guint soap_cleanup_handle;
83.133 -};
83.134 -
83.135 -/**
83.136 - * Creates an MSN session.
83.137 - *
83.138 - * @param account The account.
83.139 - *
83.140 - * @return The new MSN session.
83.141 - */
83.142 -MsnSession *msn_session_new(PurpleAccount *account);
83.143 -
83.144 -/**
83.145 - * Destroys an MSN session.
83.146 - *
83.147 - * @param session The MSN session to destroy.
83.148 - */
83.149 -void msn_session_destroy(MsnSession *session);
83.150 -
83.151 -/**
83.152 - * Connects to and initiates an MSN session.
83.153 - *
83.154 - * @param session The MSN session.
83.155 - * @param host The dispatch server host.
83.156 - * @param port The dispatch server port.
83.157 - * @param http_method Whether to use or not http_method.
83.158 - *
83.159 - * @return @c TRUE on success, @c FALSE on failure.
83.160 - */
83.161 -gboolean msn_session_connect(MsnSession *session,
83.162 - const char *host, int port,
83.163 - gboolean http_method);
83.164 -
83.165 -/**
83.166 - * Disconnects from an MSN session.
83.167 - *
83.168 - * @param session The MSN session.
83.169 - */
83.170 -void msn_session_disconnect(MsnSession *session);
83.171 -
83.172 - /**
83.173 - * Finds a switchboard with the given username.
83.174 - *
83.175 - * @param session The MSN session.
83.176 - * @param username The username to search for.
83.177 - *
83.178 - * @return The switchboard, if found.
83.179 - */
83.180 -MsnSwitchBoard *msn_session_find_swboard(MsnSession *session,
83.181 - const char *username);
83.182 -
83.183 - /**
83.184 - * Finds a switchboard with the given conversation.
83.185 - *
83.186 - * @param session The MSN session.
83.187 - * @param conv The conversation to search for.
83.188 - *
83.189 - * @return The switchboard, if found.
83.190 - */
83.191 -MsnSwitchBoard *msn_session_find_swboard_with_conv(MsnSession *session,
83.192 - PurpleConversation *conv);
83.193 -/**
83.194 - * Finds a switchboard with the given chat ID.
83.195 - *
83.196 - * @param session The MSN session.
83.197 - * @param chat_id The chat ID to search for.
83.198 - *
83.199 - * @return The switchboard, if found.
83.200 - */
83.201 -MsnSwitchBoard *msn_session_find_swboard_with_id(const MsnSession *session,
83.202 - int chat_id);
83.203 -
83.204 -/**
83.205 - * Returns a switchboard to communicate with certain username.
83.206 - *
83.207 - * @param session The MSN session.
83.208 - * @param username The username to search for.
83.209 - * @param flag The flag of the switchboard
83.210 - *
83.211 - * @return The switchboard.
83.212 - */
83.213 -MsnSwitchBoard *msn_session_get_swboard(MsnSession *session,
83.214 - const char *username, MsnSBFlag flag);
83.215 -
83.216 -/**
83.217 - * Sets an error for the MSN session.
83.218 - *
83.219 - * @param session The MSN session.
83.220 - * @param error The error.
83.221 - * @param info Extra information.
83.222 - */
83.223 -void msn_session_set_error(MsnSession *session, MsnErrorType error,
83.224 - const char *info);
83.225 -
83.226 -/**
83.227 - * Sets the current step in the login proccess.
83.228 - *
83.229 - * @param session The MSN session.
83.230 - * @param step The current step.
83.231 - */
83.232 -void msn_session_set_login_step(MsnSession *session, MsnLoginStep step);
83.233 -
83.234 -/**
83.235 - * Finish the login proccess.
83.236 - *
83.237 - * @param session The MSN session.
83.238 - */
83.239 -void msn_session_finish_login(MsnSession *session);
83.240 -
83.241 -/*post message to User*/
83.242 -void msn_session_report_user(MsnSession *session,const char *passport,
83.243 - const char *msg,PurpleMessageFlags flags);
83.244 -
83.245 -#endif /* _MSN_SESSION_H_ */
84.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/session_private.h Sun Jun 21 22:04:11 2009 -0400
84.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
84.3 @@ -1,97 +0,0 @@
84.4 -/**
84.5 - * Copyright (C) 2008 Felipe Contreras.
84.6 - *
84.7 - * Purple is the legal property of its developers, whose names are too numerous
84.8 - * to list here. Please refer to the COPYRIGHT file distributed with this
84.9 - * source distribution.
84.10 - *
84.11 - * This program is free software; you can redistribute it and/or modify
84.12 - * it under the terms of the GNU General Public License as published by
84.13 - * the Free Software Foundation; either version 2 of the License, or
84.14 - * (at your option) any later version.
84.15 - *
84.16 - * This program is distributed in the hope that it will be useful,
84.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
84.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
84.19 - * GNU General Public License for more details.
84.20 - *
84.21 - * You should have received a copy of the GNU General Public License
84.22 - * along with this program; if not, write to the Free Software
84.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
84.24 - */
84.25 -
84.26 -#ifndef MSN_SESSION_PRIVATE_H
84.27 -#define MSN_SESSION_PRIVATE_H
84.28 -
84.29 -#include "session.h"
84.30 -#include "io/pecan_node.h"
84.31 -
84.32 -#include "ab/pecan_contact.h"
84.33 -#include "ab/pecan_contactlist.h"
84.34 -
84.35 -#include "io/pecan_node.h"
84.36 -
84.37 -#include "pecan_oim.h"
84.38 -
84.39 -struct MsnNotification;
84.40 -struct MsnNexus;
84.41 -struct MsnSync;
84.42 -
84.43 -struct _PurpleAccount;
84.44 -struct _PurpleConversation;
84.45 -
84.46 -struct MsnSession
84.47 -{
84.48 - gchar *username;
84.49 - gchar *password;
84.50 -
84.51 - struct _PurpleAccount *account;
84.52 - PecanContact *user;
84.53 -
84.54 - guint protocol_ver;
84.55 -
84.56 - MsnLoginStep login_step; /**< The current step in the login process. */
84.57 -
84.58 - gboolean connected;
84.59 - gboolean logged_in; /**< A temporal flag to ignore local buddy list adds. */
84.60 - gboolean destroying; /**< A flag that states if the session is being destroyed. */
84.61 - gboolean http_method;
84.62 - gboolean server_alias;
84.63 - PecanNode *http_conn;
84.64 -
84.65 - struct MsnNotification *notification;
84.66 - struct MsnNexus *nexus;
84.67 - struct MsnSync *sync;
84.68 -
84.69 - PecanContactList *contactlist;
84.70 -
84.71 - int servconns_count; /**< The count of server connections. */
84.72 - GList *switches; /**< The list of all the switchboards. */
84.73 - GList *directconns; /**< The list of all the directconnections. */
84.74 - GList *slplinks; /**< The list of all the slplinks. */
84.75 -
84.76 - int conv_seq; /**< The current conversation sequence number. */
84.77 -
84.78 - struct
84.79 - {
84.80 - char *kv;
84.81 - char *sid;
84.82 - char *mspauth;
84.83 - unsigned long sl;
84.84 - int email_enabled;
84.85 - char *client_ip;
84.86 - int client_port;
84.87 - gchar *mail_url;
84.88 - gulong mail_url_timestamp;
84.89 - } passport_info;
84.90 - struct
84.91 - {
84.92 - gchar *t;
84.93 - gchar *p;
84.94 - } passport_cookie;
84.95 -
84.96 - guint inbox_unread_count; /* The number of unread e-mails on the inbox. */
84.97 - PecanOimSession *oim_session;
84.98 -};
84.99 -
84.100 -#endif /* MSN_SESSION_PRIVATE_H */
85.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/si.h Sun Jun 21 22:04:11 2009 -0400
85.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
85.3 @@ -1,34 +0,0 @@
85.4 -/**
85.5 - * @file jutil.h utility functions
85.6 - *
85.7 - * purple
85.8 - *
85.9 - * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
85.10 - *
85.11 - * This program is free software; you can redistribute it and/or modify
85.12 - * it under the terms of the GNU General Public License as published by
85.13 - * the Free Software Foundation; either version 2 of the License, or
85.14 - * (at your option) any later version.
85.15 - *
85.16 - * This program is distributed in the hope that it will be useful,
85.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
85.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
85.19 - * GNU General Public License for more details.
85.20 - *
85.21 - * You should have received a copy of the GNU General Public License
85.22 - * along with this program; if not, write to the Free Software
85.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
85.24 - */
85.25 -#ifndef _PURPLE_JABBER_SI_H_
85.26 -#define _PURPLE_JABBER_SI_H_
85.27 -
85.28 -#include "ft.h"
85.29 -
85.30 -#include "jabber.h"
85.31 -
85.32 -void jabber_bytestreams_parse(JabberStream *js, xmlnode *packet);
85.33 -void jabber_si_parse(JabberStream *js, xmlnode *packet);
85.34 -PurpleXfer *jabber_si_new_xfer(PurpleConnection *gc, const char *who);
85.35 -void jabber_si_xfer_send(PurpleConnection *gc, const char *who, const char *file);
85.36 -
85.37 -#endif /* _PURPLE_JABBER_SI_H_ */
86.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/signals.h Sun Jun 21 22:04:11 2009 -0400
86.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
86.3 @@ -1,372 +0,0 @@
86.4 -/**
86.5 - * @file signals.h Signal API
86.6 - * @ingroup core
86.7 - */
86.8 -
86.9 -/* purple
86.10 - *
86.11 - * Purple is the legal property of its developers, whose names are too numerous
86.12 - * to list here. Please refer to the COPYRIGHT file distributed with this
86.13 - * source distribution.
86.14 - *
86.15 - * This program is free software; you can redistribute it and/or modify
86.16 - * it under the terms of the GNU General Public License as published by
86.17 - * the Free Software Foundation; either version 2 of the License, or
86.18 - * (at your option) any later version.
86.19 - *
86.20 - * This program is distributed in the hope that it will be useful,
86.21 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
86.22 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
86.23 - * GNU General Public License for more details.
86.24 - *
86.25 - * You should have received a copy of the GNU General Public License
86.26 - * along with this program; if not, write to the Free Software
86.27 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
86.28 - */
86.29 -#ifndef _PURPLE_SIGNALS_H_
86.30 -#define _PURPLE_SIGNALS_H_
86.31 -
86.32 -#include <glib.h>
86.33 -#include "value.h"
86.34 -
86.35 -#define PURPLE_CALLBACK(func) ((PurpleCallback)func)
86.36 -
86.37 -typedef void (*PurpleCallback)(void);
86.38 -typedef void (*PurpleSignalMarshalFunc)(PurpleCallback cb, va_list args,
86.39 - void *data, void **return_val);
86.40 -
86.41 -#ifdef __cplusplus
86.42 -extern "C" {
86.43 -#endif
86.44 -
86.45 -/**************************************************************************/
86.46 -/** @name Signal API */
86.47 -/**************************************************************************/
86.48 -/*@{*/
86.49 -
86.50 -/** The priority of a signal connected using purple_signal_connect().
86.51 - *
86.52 - * @see purple_signal_connect_priority()
86.53 - */
86.54 -#define PURPLE_SIGNAL_PRIORITY_DEFAULT 0
86.55 -/** The largest signal priority; signals with this priority will be called
86.56 - * <em>last</em>. (This is highest as in numerical value, not as in order of
86.57 - * importance.)
86.58 - *
86.59 - * @see purple_signal_connect_priority().
86.60 - */
86.61 -#define PURPLE_SIGNAL_PRIORITY_HIGHEST 9999
86.62 -/** The smallest signal priority; signals with this priority will be called
86.63 - * <em>first</em>. (This is lowest as in numerical value, not as in order of
86.64 - * importance.)
86.65 - *
86.66 - * @see purple_signal_connect_priority().
86.67 - */
86.68 -#define PURPLE_SIGNAL_PRIORITY_LOWEST -9999
86.69 -
86.70 -/**
86.71 - * Registers a signal in an instance.
86.72 - *
86.73 - * @param instance The instance to register the signal for.
86.74 - * @param signal The signal name.
86.75 - * @param marshal The marshal function.
86.76 - * @param ret_value The return value type, or NULL for no return value.
86.77 - * @param num_values The number of values to be passed to the callbacks.
86.78 - * @param ... The values to pass to the callbacks.
86.79 - *
86.80 - * @return The signal ID local to that instance, or 0 if the signal
86.81 - * couldn't be registered.
86.82 - *
86.83 - * @see PurpleValue
86.84 - */
86.85 -gulong purple_signal_register(void *instance, const char *signal,
86.86 - PurpleSignalMarshalFunc marshal,
86.87 - PurpleValue *ret_value, int num_values, ...);
86.88 -
86.89 -/**
86.90 - * Unregisters a signal in an instance.
86.91 - *
86.92 - * @param instance The instance to unregister the signal for.
86.93 - * @param signal The signal name.
86.94 - */
86.95 -void purple_signal_unregister(void *instance, const char *signal);
86.96 -
86.97 -/**
86.98 - * Unregisters all signals in an instance.
86.99 - *
86.100 - * @param instance The instance to unregister the signal for.
86.101 - */
86.102 -void purple_signals_unregister_by_instance(void *instance);
86.103 -
86.104 -/**
86.105 - * Returns a list of value types used for a signal.
86.106 - *
86.107 - * @param instance The instance the signal is registered to.
86.108 - * @param signal The signal.
86.109 - * @param ret_value The return value from the last signal handler.
86.110 - * @param num_values The returned number of values.
86.111 - * @param values The returned list of values.
86.112 - */
86.113 -void purple_signal_get_values(void *instance, const char *signal,
86.114 - PurpleValue **ret_value,
86.115 - int *num_values, PurpleValue ***values);
86.116 -
86.117 -/**
86.118 - * Connects a signal handler to a signal for a particular object.
86.119 - *
86.120 - * Take care not to register a handler function twice. Purple will
86.121 - * not correct any mistakes for you in this area.
86.122 - *
86.123 - * @param instance The instance to connect to.
86.124 - * @param signal The name of the signal to connect.
86.125 - * @param handle The handle of the receiver.
86.126 - * @param func The callback function.
86.127 - * @param data The data to pass to the callback function.
86.128 - * @param priority The priority with which the handler should be called. Signal
86.129 - * handlers are called in ascending numerical order of @a
86.130 - * priority from #PURPLE_SIGNAL_PRIORITY_LOWEST to
86.131 - * #PURPLE_SIGNAL_PRIORITY_HIGHEST.
86.132 - *
86.133 - * @return The signal handler ID.
86.134 - *
86.135 - * @see purple_signal_disconnect()
86.136 - */
86.137 -gulong purple_signal_connect_priority(void *instance, const char *signal,
86.138 - void *handle, PurpleCallback func, void *data, int priority);
86.139 -
86.140 -/**
86.141 - * Connects a signal handler to a signal for a particular object.
86.142 - * (Its priority defaults to 0, aka #PURPLE_SIGNAL_PRIORITY_DEFAULT.)
86.143 - *
86.144 - * Take care not to register a handler function twice. Purple will
86.145 - * not correct any mistakes for you in this area.
86.146 - *
86.147 - * @param instance The instance to connect to.
86.148 - * @param signal The name of the signal to connect.
86.149 - * @param handle The handle of the receiver.
86.150 - * @param func The callback function.
86.151 - * @param data The data to pass to the callback function.
86.152 - *
86.153 - * @return The signal handler ID.
86.154 - *
86.155 - * @see purple_signal_disconnect()
86.156 - */
86.157 -gulong purple_signal_connect(void *instance, const char *signal,
86.158 - void *handle, PurpleCallback func, void *data);
86.159 -
86.160 -/**
86.161 - * Connects a signal handler to a signal for a particular object.
86.162 - *
86.163 - * The signal handler will take a va_args of arguments, instead of
86.164 - * individual arguments.
86.165 - *
86.166 - * Take care not to register a handler function twice. Purple will
86.167 - * not correct any mistakes for you in this area.
86.168 - *
86.169 - * @param instance The instance to connect to.
86.170 - * @param signal The name of the signal to connect.
86.171 - * @param handle The handle of the receiver.
86.172 - * @param func The callback function.
86.173 - * @param data The data to pass to the callback function.
86.174 - * @param priority The priority with which the handler should be called. Signal
86.175 - * handlers are called in ascending numerical order of @a
86.176 - * priority from #PURPLE_SIGNAL_PRIORITY_LOWEST to
86.177 - * #PURPLE_SIGNAL_PRIORITY_HIGHEST.
86.178 - *
86.179 - * @return The signal handler ID.
86.180 - *
86.181 - * @see purple_signal_disconnect()
86.182 - */
86.183 -gulong purple_signal_connect_priority_vargs(void *instance, const char *signal,
86.184 - void *handle, PurpleCallback func, void *data, int priority);
86.185 -
86.186 -/**
86.187 - * Connects a signal handler to a signal for a particular object.
86.188 - * (Its priority defaults to 0, aka #PURPLE_SIGNAL_PRIORITY_DEFAULT.)
86.189 - *
86.190 - * The signal handler will take a va_args of arguments, instead of
86.191 - * individual arguments.
86.192 - *
86.193 - * Take care not to register a handler function twice. Purple will
86.194 - * not correct any mistakes for you in this area.
86.195 - *
86.196 - * @param instance The instance to connect to.
86.197 - * @param signal The name of the signal to connect.
86.198 - * @param handle The handle of the receiver.
86.199 - * @param func The callback function.
86.200 - * @param data The data to pass to the callback function.
86.201 - *
86.202 - * @return The signal handler ID.
86.203 - *
86.204 - * @see purple_signal_disconnect()
86.205 - */
86.206 -gulong purple_signal_connect_vargs(void *instance, const char *signal,
86.207 - void *handle, PurpleCallback func, void *data);
86.208 -
86.209 -/**
86.210 - * Disconnects a signal handler from a signal on an object.
86.211 - *
86.212 - * @param instance The instance to disconnect from.
86.213 - * @param signal The name of the signal to disconnect.
86.214 - * @param handle The handle of the receiver.
86.215 - * @param func The registered function to disconnect.
86.216 - *
86.217 - * @see purple_signal_connect()
86.218 - */
86.219 -void purple_signal_disconnect(void *instance, const char *signal,
86.220 - void *handle, PurpleCallback func);
86.221 -
86.222 -/**
86.223 - * Removes all callbacks associated with a receiver handle.
86.224 - *
86.225 - * @param handle The receiver handle.
86.226 - */
86.227 -void purple_signals_disconnect_by_handle(void *handle);
86.228 -
86.229 -/**
86.230 - * Emits a signal.
86.231 - *
86.232 - * @param instance The instance emitting the signal.
86.233 - * @param signal The signal being emitted.
86.234 - *
86.235 - * @see purple_signal_connect()
86.236 - * @see purple_signal_disconnect()
86.237 - */
86.238 -void purple_signal_emit(void *instance, const char *signal, ...);
86.239 -
86.240 -/**
86.241 - * Emits a signal, using a va_list of arguments.
86.242 - *
86.243 - * @param instance The instance emitting the signal.
86.244 - * @param signal The signal being emitted.
86.245 - * @param args The arguments list.
86.246 - *
86.247 - * @see purple_signal_connect()
86.248 - * @see purple_signal_disconnect()
86.249 - */
86.250 -void purple_signal_emit_vargs(void *instance, const char *signal, va_list args);
86.251 -
86.252 -/**
86.253 - * Emits a signal and returns the first non-NULL return value.
86.254 - *
86.255 - * Further signal handlers are NOT called after a handler returns
86.256 - * something other than NULL.
86.257 - *
86.258 - * @param instance The instance emitting the signal.
86.259 - * @param signal The signal being emitted.
86.260 - *
86.261 - * @return The first non-NULL return value
86.262 - */
86.263 -void *purple_signal_emit_return_1(void *instance, const char *signal, ...);
86.264 -
86.265 -/**
86.266 - * Emits a signal and returns the first non-NULL return value.
86.267 - *
86.268 - * Further signal handlers are NOT called after a handler returns
86.269 - * something other than NULL.
86.270 - *
86.271 - * @param instance The instance emitting the signal.
86.272 - * @param signal The signal being emitted.
86.273 - * @param args The arguments list.
86.274 - *
86.275 - * @return The first non-NULL return value
86.276 - */
86.277 -void *purple_signal_emit_vargs_return_1(void *instance, const char *signal,
86.278 - va_list args);
86.279 -
86.280 -/**
86.281 - * Initializes the signals subsystem.
86.282 - */
86.283 -void purple_signals_init(void);
86.284 -
86.285 -/**
86.286 - * Uninitializes the signals subsystem.
86.287 - */
86.288 -void purple_signals_uninit(void);
86.289 -
86.290 -/*@}*/
86.291 -
86.292 -/**************************************************************************/
86.293 -/** @name Marshal Functions */
86.294 -/**************************************************************************/
86.295 -/*@{*/
86.296 -
86.297 -void purple_marshal_VOID(
86.298 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.299 -void purple_marshal_VOID__INT(
86.300 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.301 -void purple_marshal_VOID__INT_INT(
86.302 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.303 -void purple_marshal_VOID__POINTER(
86.304 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.305 -void purple_marshal_VOID__POINTER_UINT(
86.306 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.307 -void purple_marshal_VOID__POINTER_INT_INT(
86.308 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.309 -void purple_marshal_VOID__POINTER_INT_POINTER(
86.310 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.311 -void purple_marshal_VOID__POINTER_POINTER(
86.312 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.313 -void purple_marshal_VOID__POINTER_POINTER_UINT(
86.314 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.315 -void purple_marshal_VOID__POINTER_POINTER_UINT_UINT(
86.316 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.317 -void purple_marshal_VOID__POINTER_POINTER_POINTER(
86.318 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.319 -void purple_marshal_VOID__POINTER_POINTER_POINTER_POINTER(
86.320 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.321 -void purple_marshal_VOID__POINTER_POINTER_POINTER_POINTER_POINTER(
86.322 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.323 -void purple_marshal_VOID__POINTER_POINTER_POINTER_UINT(
86.324 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.325 -void purple_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT(
86.326 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.327 -void purple_marshal_VOID__POINTER_POINTER_POINTER_UINT_UINT(
86.328 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.329 -
86.330 -void purple_marshal_INT__INT(
86.331 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.332 -void purple_marshal_INT__INT_INT(
86.333 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.334 -void purple_marshal_INT__POINTER_POINTER(
86.335 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.336 -void purple_marshal_INT__POINTER_POINTER_POINTER_POINTER_POINTER(
86.337 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.338 -
86.339 -void purple_marshal_BOOLEAN__POINTER(
86.340 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.341 -void purple_marshal_BOOLEAN__POINTER_POINTER(
86.342 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.343 -void purple_marshal_BOOLEAN__POINTER_POINTER_POINTER(
86.344 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.345 -void purple_marshal_BOOLEAN__POINTER_POINTER_UINT(
86.346 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.347 -void purple_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT(
86.348 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.349 -void purple_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER(
86.350 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.351 -void purple_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER(
86.352 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.353 -void purple_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_UINT(
86.354 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.355 -
86.356 -void purple_marshal_BOOLEAN__INT_POINTER(
86.357 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.358 -
86.359 -void purple_marshal_POINTER__POINTER_INT(
86.360 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.361 -void purple_marshal_POINTER__POINTER_INT64(
86.362 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.363 -void purple_marshal_POINTER__POINTER_INT_BOOLEAN(
86.364 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.365 -void purple_marshal_POINTER__POINTER_INT64_BOOLEAN(
86.366 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.367 -void purple_marshal_POINTER__POINTER_POINTER(
86.368 - PurpleCallback cb, va_list args, void *data, void **return_val);
86.369 -/*@}*/
86.370 -
86.371 -#ifdef __cplusplus
86.372 -}
86.373 -#endif
86.374 -
86.375 -#endif /* _PURPLE_SIGNALS_H_ */
87.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/slp.h Sun Jun 21 22:04:11 2009 -0400
87.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
87.3 @@ -1,48 +0,0 @@
87.4 -/**
87.5 - * @file slp.h MSNSLP support
87.6 - *
87.7 - * purple
87.8 - *
87.9 - * Purple is the legal property of its developers, whose names are too numerous
87.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
87.11 - * source distribution.
87.12 - *
87.13 - * This program is free software; you can redistribute it and/or modify
87.14 - * it under the terms of the GNU General Public License as published by
87.15 - * the Free Software Foundation; either version 2 of the License, or
87.16 - * (at your option) any later version.
87.17 - *
87.18 - * This program is distributed in the hope that it will be useful,
87.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
87.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
87.21 - * GNU General Public License for more details.
87.22 - *
87.23 - * You should have received a copy of the GNU General Public License
87.24 - * along with this program; if not, write to the Free Software
87.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
87.26 - */
87.27 -#ifndef _MSN_SLP_H_
87.28 -#define _MSN_SLP_H_
87.29 -
87.30 -#include "slpcall.h"
87.31 -#include "session.h"
87.32 -#include "internal.h"
87.33 -#include "ft.h"
87.34 -
87.35 -void msn_xfer_progress_cb(MsnSlpCall *slpcall, gsize total_length, gsize
87.36 - len, gsize offset);
87.37 -
87.38 -MsnSlpCall * msn_slp_sip_recv(MsnSlpLink *slplink,
87.39 - const char *body);
87.40 -
87.41 -void send_bye(MsnSlpCall *slpcall, const char *type);
87.42 -
87.43 -void msn_xfer_completed_cb(MsnSlpCall *slpcall,
87.44 - const guchar *body, gsize size);
87.45 -
87.46 -void msn_xfer_cancel(PurpleXfer *xfer);
87.47 -void msn_xfer_end_cb(MsnSlpCall *slpcall, MsnSession *session);
87.48 -
87.49 -void msn_queue_buddy_icon_request(MsnUser *user);
87.50 -
87.51 -#endif /* _MSN_SLP_H_ */
88.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/slpcall.h Sun Jun 21 22:04:11 2009 -0400
88.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
88.3 @@ -1,90 +0,0 @@
88.4 -/**
88.5 - * @file slpcall.h SLP Call functions
88.6 - *
88.7 - * purple
88.8 - *
88.9 - * Purple is the legal property of its developers, whose names are too numerous
88.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
88.11 - * source distribution.
88.12 - *
88.13 - * This program is free software; you can redistribute it and/or modify
88.14 - * it under the terms of the GNU General Public License as published by
88.15 - * the Free Software Foundation; either version 2 of the License, or
88.16 - * (at your option) any later version.
88.17 - *
88.18 - * This program is distributed in the hope that it will be useful,
88.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
88.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
88.21 - * GNU General Public License for more details.
88.22 - *
88.23 - * You should have received a copy of the GNU General Public License
88.24 - * along with this program; if not, write to the Free Software
88.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
88.26 - */
88.27 -#ifndef _MSN_SLPCALL_H_
88.28 -#define _MSN_SLPCALL_H_
88.29 -
88.30 -#include "internal.h"
88.31 -#include "ft.h"
88.32 -
88.33 -typedef struct _MsnSlpCall MsnSlpCall;
88.34 -
88.35 -#include "slplink.h"
88.36 -
88.37 -/* The official client seems to timeout slp calls after 5 minutes */
88.38 -#define MSN_SLPCALL_TIMEOUT 300
88.39 -
88.40 -typedef enum
88.41 -{
88.42 - MSN_SLPCALL_ANY,
88.43 - MSN_SLPCALL_DC
88.44 -
88.45 -} MsnSlpCallType;
88.46 -
88.47 -struct _MsnSlpCall
88.48 -{
88.49 - /* Our parent slplink */
88.50 - MsnSlpLink *slplink;
88.51 -
88.52 - MsnSlpCallType type;
88.53 -
88.54 - /* Call-ID */
88.55 - char *id;
88.56 - char *branch;
88.57 -
88.58 - long session_id;
88.59 - long app_id;
88.60 -
88.61 - gboolean pending; /**< A flag that states if we should wait for this
88.62 - slpcall to start and do not time out. */
88.63 - gboolean progress; /**< A flag that states if there has been progress since
88.64 - the last time out. */
88.65 - gboolean wasted; /**< A flag that states if this slpcall is going to be
88.66 - destroyed. */
88.67 - gboolean started; /**< A flag that states if this slpcall's session has
88.68 - been initiated. */
88.69 -
88.70 - void (*progress_cb)(MsnSlpCall *slpcall,
88.71 - gsize total_length, gsize len, gsize offset);
88.72 - void (*session_init_cb)(MsnSlpCall *slpcall);
88.73 -
88.74 - /* Can be checksum, or smile */
88.75 - char *data_info;
88.76 -
88.77 - PurpleXfer *xfer;
88.78 -
88.79 - MsnSlpCb cb;
88.80 - void (*end_cb)(MsnSlpCall *slpcall, MsnSession *session);
88.81 -
88.82 - guint timer;
88.83 -};
88.84 -
88.85 -MsnSlpCall *msn_slpcall_new(MsnSlpLink *slplink);
88.86 -void msn_slpcall_init(MsnSlpCall *slpcall, MsnSlpCallType type);
88.87 -void msn_slpcall_session_init(MsnSlpCall *slpcall);
88.88 -void msn_slpcall_destroy(MsnSlpCall *slpcall);
88.89 -void msn_slpcall_invite(MsnSlpCall *slpcall, const char *euf_guid,
88.90 - int app_id, const char *context);
88.91 -void msn_slpcall_close(MsnSlpCall *slpcall);
88.92 -
88.93 -#endif /* _MSN_SLPCALL_H_ */
89.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/slplink.h Sun Jun 21 22:04:11 2009 -0400
89.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
89.3 @@ -1,95 +0,0 @@
89.4 -/**
89.5 - * @file slplink.h MSNSLP Link support
89.6 - *
89.7 - * purple
89.8 - *
89.9 - * Purple is the legal property of its developers, whose names are too numerous
89.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
89.11 - * source distribution.
89.12 - *
89.13 - * This program is free software; you can redistribute it and/or modify
89.14 - * it under the terms of the GNU General Public License as published by
89.15 - * the Free Software Foundation; either version 2 of the License, or
89.16 - * (at your option) any later version.
89.17 - *
89.18 - * This program is distributed in the hope that it will be useful,
89.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
89.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
89.21 - * GNU General Public License for more details.
89.22 - *
89.23 - * You should have received a copy of the GNU General Public License
89.24 - * along with this program; if not, write to the Free Software
89.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
89.26 - */
89.27 -#ifndef _MSN_SLPLINK_H_
89.28 -#define _MSN_SLPLINK_H_
89.29 -
89.30 -typedef struct _MsnSlpLink MsnSlpLink;
89.31 -
89.32 -#include "directconn.h"
89.33 -#include "slpcall.h"
89.34 -#include "slpmsg.h"
89.35 -
89.36 -#include "switchboard.h"
89.37 -
89.38 -#include "ft.h"
89.39 -
89.40 -#include "session.h"
89.41 -
89.42 -typedef void (*MsnSlpCb)(MsnSlpCall *slpcall,
89.43 - const guchar *data, gsize size);
89.44 -typedef void (*MsnSlpEndCb)(MsnSlpCall *slpcall, MsnSession *session);
89.45 -
89.46 -struct _MsnSlpLink
89.47 -{
89.48 - MsnSession *session;
89.49 - MsnSwitchBoard *swboard;
89.50 -
89.51 - char *remote_user;
89.52 -
89.53 - int slp_seq_id;
89.54 -
89.55 - MsnDirectConn *directconn;
89.56 -
89.57 - GList *slp_calls;
89.58 - GList *slp_msgs;
89.59 -
89.60 - GQueue *slp_msg_queue;
89.61 -};
89.62 -
89.63 -void msn_slplink_destroy(MsnSlpLink *slplink);
89.64 -
89.65 -/**
89.66 - * @return An MsnSlpLink for the given user, or NULL if there is no
89.67 - * existing MsnSlpLink.
89.68 - */
89.69 -MsnSlpLink *msn_session_find_slplink(MsnSession *session,
89.70 - const char *who);
89.71 -
89.72 -/**
89.73 - * @return An MsnSlpLink for the given user. One will be created if
89.74 - * it does not already exist.
89.75 - */
89.76 -MsnSlpLink *msn_session_get_slplink(MsnSession *session, const char *username);
89.77 -
89.78 -void msn_slplink_add_slpcall(MsnSlpLink *slplink, MsnSlpCall *slpcall);
89.79 -void msn_slplink_remove_slpcall(MsnSlpLink *slplink, MsnSlpCall *slpcall);
89.80 -MsnSlpCall *msn_slplink_find_slp_call(MsnSlpLink *slplink,
89.81 - const char *id);
89.82 -MsnSlpCall *msn_slplink_find_slp_call_with_session_id(MsnSlpLink *slplink, long id);
89.83 -void msn_slplink_queue_slpmsg(MsnSlpLink *slplink, MsnSlpMessage *slpmsg);
89.84 -void msn_slplink_send_slpmsg(MsnSlpLink *slplink,
89.85 - MsnSlpMessage *slpmsg);
89.86 -void msn_slplink_send_queued_slpmsgs(MsnSlpLink *slplink);
89.87 -void msn_slplink_process_msg(MsnSlpLink *slplink, MsnMessage *msg);
89.88 -void msn_slplink_request_ft(MsnSlpLink *slplink, PurpleXfer *xfer);
89.89 -
89.90 -void msn_slplink_request_object(MsnSlpLink *slplink,
89.91 - const char *info,
89.92 - MsnSlpCb cb,
89.93 - MsnSlpEndCb end_cb,
89.94 - const MsnObject *obj);
89.95 -
89.96 -MsnSlpCall *msn_slp_process_msg(MsnSlpLink *slplink, MsnSlpMessage *slpmsg);
89.97 -
89.98 -#endif /* _MSN_SLPLINK_H_ */
90.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/slpmsg.h Sun Jun 21 22:04:11 2009 -0400
90.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
90.3 @@ -1,107 +0,0 @@
90.4 -/**
90.5 - * @file slpmsg.h SLP Message functions
90.6 - *
90.7 - * purple
90.8 - *
90.9 - * Purple is the legal property of its developers, whose names are too numerous
90.10 - * to list here. Please refer to the COPYRIGHT file distributed with this
90.11 - * source distribution.
90.12 - *
90.13 - * This program is free software; you can redistribute it and/or modify
90.14 - * it under the terms of the GNU General Public License as published by
90.15 - * the Free Software Foundation; either version 2 of the License, or
90.16 - * (at your option) any later version.
90.17 - *
90.18 - * This program is distributed in the hope that it will be useful,
90.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
90.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
90.21 - * GNU General Public License for more details.
90.22 - *
90.23 - * You should have received a copy of the GNU General Public License
90.24 - * along with this program; if not, write to the Free Software
90.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
90.26 - */
90.27 -#ifndef _MSN_SLPMSG_H_
90.28 -#define _MSN_SLPMSG_H_
90.29 -
90.30 -typedef struct _MsnSlpMessage MsnSlpMessage;
90.31 -
90.32 -#include "imgstore.h"
90.33 -
90.34 -#include "slpcall.h"
90.35 -#include "slplink.h"
90.36 -#include "session.h"
90.37 -#include "msg.h"
90.38 -
90.39 -#include "slp.h"
90.40 -
90.41 -/**
90.42 - * A SLP Message This contains everything that we will need to send a SLP
90.43 - * Message even if has to be sent in several parts.
90.44 - */
90.45 -struct _MsnSlpMessage
90.46 -{
90.47 - MsnSlpCall *slpcall; /**< The slpcall to which this slp message belongs (if applicable). */
90.48 - MsnSlpLink *slplink; /**< The slplink through which this slp message is being sent. */
90.49 - MsnSession *session;
90.50 -
90.51 - long session_id;
90.52 - long id;
90.53 - long ack_id;
90.54 - long ack_sub_id;
90.55 - long long ack_size;
90.56 - long app_id;
90.57 -
90.58 - gboolean sip; /**< A flag that states if this is a SIP slp message. */
90.59 - int ref_count; /**< The reference count. */
90.60 - long flags;
90.61 -
90.62 - FILE *fp;
90.63 - PurpleStoredImage *img;
90.64 - guchar *buffer;
90.65 - long long offset;
90.66 - long long size;
90.67 -
90.68 - GList *msgs; /**< The real messages. */
90.69 -
90.70 -#if 1
90.71 - MsnMessage *msg; /**< The temporary real message that will be sent. */
90.72 -#endif
90.73 -
90.74 -#ifdef MSN_DEBUG_SLP
90.75 - char *info;
90.76 - gboolean text_body;
90.77 -#endif
90.78 -};
90.79 -
90.80 -/**
90.81 - * Creates a new slp message
90.82 - *
90.83 - * @param slplink The slplink through which this slp message will be sent.
90.84 - * @return The created slp message.
90.85 - */
90.86 -MsnSlpMessage *msn_slpmsg_new(MsnSlpLink *slplink);
90.87 -
90.88 -/**
90.89 - * Destroys a slp message
90.90 - *
90.91 - * @param slpmsg The slp message to destory.
90.92 - */
90.93 -void msn_slpmsg_destroy(MsnSlpMessage *slpmsg);
90.94 -
90.95 -void msn_slpmsg_set_body(MsnSlpMessage *slpmsg, const char *body,
90.96 - long long size);
90.97 -void msn_slpmsg_set_image(MsnSlpMessage *slpmsg, PurpleStoredImage *img);
90.98 -void msn_slpmsg_open_file(MsnSlpMessage *slpmsg,
90.99 - const char *file_name);
90.100 -MsnSlpMessage * msn_slpmsg_sip_new(MsnSlpCall *slpcall, int cseq,
90.101 - const char *header,
90.102 - const char *branch,
90.103 - const char *content_type,
90.104 - const char *content);
90.105 -
90.106 -#ifdef MSN_DEBUG_SLP
90.107 -void msn_slpmsg_show(MsnMessage *msg);
90.108 -#endif
90.109 -
90.110 -#endif /* _MSN_SLPMSG_H_ */
91.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/smiley.h Sun Jun 21 22:04:11 2009 -0400
91.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
91.3 @@ -1,269 +0,0 @@
91.4 -/**
91.5 - * @file smiley.h Smiley API
91.6 - * @ingroup core
91.7 - * @since 2.5.0
91.8 - */
91.9 -
91.10 -/* purple
91.11 - *
91.12 - * Purple is the legal property of its developers, whose names are too numerous
91.13 - * to list here. Please refer to the COPYRIGHT file distributed with this
91.14 - * source distribution.
91.15 - *
91.16 - * This program is free software; you can redistribute it and/or modify
91.17 - * it under the terms of the GNU General Public License as published by
91.18 - * the Free Software Foundation; either version 2 of the License, or
91.19 - * (at your option) any later version.
91.20 - *
91.21 - * This program is distributed in the hope that it will be useful,
91.22 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
91.23 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
91.24 - * GNU General Public License for more details.
91.25 - *
91.26 - * You should have received a copy of the GNU General Public License
91.27 - * along with this program; if not, write to the Free Software
91.28 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
91.29 - *
91.30 - */
91.31 -
91.32 -#ifndef _PURPLE_SMILEY_H_
91.33 -#define _PURPLE_SMILEY_H_
91.34 -
91.35 -#include <glib-object.h>
91.36 -
91.37 -#include "imgstore.h"
91.38 -#include "util.h"
91.39 -
91.40 -/**
91.41 - * A custom smiley.
91.42 - * This contains everything Purple will ever need to know about a custom smiley.
91.43 - * Everything.
91.44 - *
91.45 - * PurpleSmiley is a GObject.
91.46 - */
91.47 -typedef struct _PurpleSmiley PurpleSmiley;
91.48 -typedef struct _PurpleSmileyClass PurpleSmileyClass;
91.49 -
91.50 -#define PURPLE_TYPE_SMILEY (purple_smiley_get_type ())
91.51 -#define PURPLE_SMILEY(smiley) (G_TYPE_CHECK_INSTANCE_CAST ((smiley), PURPLE_TYPE_SMILEY, PurpleSmiley))
91.52 -#define PURPLE_SMILEY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PURPLE_TYPE_SMILEY, PurpleSmileyClass))
91.53 -#define PURPLE_IS_SMILEY(smiley) (G_TYPE_CHECK_INSTANCE_TYPE ((smiley), PURPLE_TYPE_SMILEY))
91.54 -#define PURPLE_IS_SMILEY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PURPLE_TYPE_SMILEY))
91.55 -#define PURPLE_SMILEY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PURPLE_TYPE_SMILEY, PurpleSmileyClass))
91.56 -
91.57 -#ifdef __cplusplus
91.58 -extern "C" {
91.59 -#endif
91.60 -
91.61 -/**************************************************************************/
91.62 -/** @name Custom Smiley API */
91.63 -/**************************************************************************/
91.64 -/*@{*/
91.65 -
91.66 -/**
91.67 - * GObject foo.
91.68 - * @internal.
91.69 - */
91.70 -GType purple_smiley_get_type(void);
91.71 -
91.72 -/**
91.73 - * Creates a new custom smiley structure and populates it.
91.74 - *
91.75 - * If a custom smiley with the informed shortcut already exist, it
91.76 - * will be automaticaly returned.
91.77 - *
91.78 - * @param img The image associated with the smiley.
91.79 - * @param shortcut The custom smiley associated shortcut.
91.80 - *
91.81 - * @return The custom smiley structure filled up.
91.82 - */
91.83 -PurpleSmiley *
91.84 -purple_smiley_new(PurpleStoredImage *img, const char *shortcut);
91.85 -
91.86 -/**
91.87 - * Creates a new custom smiley structure and populates it.
91.88 - *
91.89 - * The data is retrieved from an already existent file.
91.90 - *
91.91 - * If a custom smiley with the informed shortcut already exist, it
91.92 - * will be automaticaly returned.
91.93 - *
91.94 - * @param shortcut The custom smiley associated shortcut.
91.95 - * @param filepath The image file to be imported to a
91.96 - * new custom smiley.
91.97 - *
91.98 - * @return The custom smiley structure filled up.
91.99 - */
91.100 -PurpleSmiley *
91.101 -purple_smiley_new_from_file(const char *shortcut, const char *filepath);
91.102 -
91.103 -/**
91.104 - * Destroy the custom smiley and release the associated resources.
91.105 - *
91.106 - * @param smiley The custom smiley.
91.107 - */
91.108 -void
91.109 -purple_smiley_delete(PurpleSmiley *smiley);
91.110 -
91.111 -/**
91.112 - * Changes the custom smiley's shortcut.
91.113 - *
91.114 - * @param smiley The custom smiley.
91.115 - * @param shortcut The custom smiley associated shortcut.
91.116 - *
91.117 - * @return TRUE whether the shortcut is not associated with another
91.118 - * custom smiley and the parameters are valid. FALSE otherwise.
91.119 - */
91.120 -gboolean
91.121 -purple_smiley_set_shortcut(PurpleSmiley *smiley, const char *shortcut);
91.122 -
91.123 -/**
91.124 - * Changes the custom smiley's data.
91.125 - *
91.126 - * When the filename controling is made outside this API, the param
91.127 - * #keepfilename must be TRUE.
91.128 - * Otherwise, the file and filename will be regenerated, and the
91.129 - * old one will be removed.
91.130 - *
91.131 - * @param smiley The custom smiley.
91.132 - * @param smiley_data The custom smiley data.
91.133 - * @param smiley_data_len The custom smiley data length.
91.134 - */
91.135 -void
91.136 -purple_smiley_set_data(PurpleSmiley *smiley, guchar *smiley_data,
91.137 - size_t smiley_data_len);
91.138 -
91.139 -/**
91.140 - * Returns the custom smiley's associated shortcut.
91.141 - *
91.142 - * @param smiley The custom smiley.
91.143 - *
91.144 - * @return The shortcut.
91.145 - */
91.146 -const char *purple_smiley_get_shortcut(const PurpleSmiley *smiley);
91.147 -
91.148 -/**
91.149 - * Returns the custom smiley data's checksum.
91.150 - *
91.151 - * @param smiley The custom smiley.
91.152 - *
91.153 - * @return The checksum.
91.154 - */
91.155 -const char *purple_smiley_get_checksum(const PurpleSmiley *smiley);
91.156 -
91.157 -/**
91.158 - * Returns the PurpleStoredImage with the reference counter incremented.
91.159 - *
91.160 - * The returned PurpleStoredImage reference counter must be decremented
91.161 - * after use.
91.162 - *
91.163 - * @param smiley The custom smiley.
91.164 - *
91.165 - * @return A PurpleStoredImage reference.
91.166 - */
91.167 -PurpleStoredImage *purple_smiley_get_stored_image(const PurpleSmiley *smiley);
91.168 -
91.169 -/**
91.170 - * Returns the custom smiley's data.
91.171 - *
91.172 - * @param smiley The custom smiley.
91.173 - * @param len If not @c NULL, the length of the icon data returned
91.174 - * will be set in the location pointed to by this.
91.175 - *
91.176 - * @return A pointer to the custom smiley data.
91.177 - */
91.178 -gconstpointer purple_smiley_get_data(const PurpleSmiley *smiley, size_t *len);
91.179 -
91.180 -/**
91.181 - * Returns an extension corresponding to the custom smiley's file type.
91.182 - *
91.183 - * @param smiley The custom smiley.
91.184 - *
91.185 - * @return The custom smiley's extension, "icon" if unknown, or @c NULL if
91.186 - * the image data has disappeared.
91.187 - */
91.188 -const char *purple_smiley_get_extension(const PurpleSmiley *smiley);
91.189 -
91.190 -/**
91.191 - * Returns a full path to an custom smiley.
91.192 - *
91.193 - * If the custom smiley has data and the file exists in the cache, this
91.194 - * will return a full path to the cached file.
91.195 - *
91.196 - * In general, it is not appropriate to be poking in the file cached
91.197 - * directly. If you find yourself wanting to use this function, think
91.198 - * very long and hard about it, and then don't.
91.199 - *
91.200 - * @param smiley The custom smiley.
91.201 - *
91.202 - * @return A full path to the file, or @c NULL under various conditions.
91.203 - * The caller should use #g_free to free the returned string.
91.204 - */
91.205 -char *purple_smiley_get_full_path(PurpleSmiley *smiley);
91.206 -
91.207 -/*@}*/
91.208 -
91.209 -
91.210 -/**************************************************************************/
91.211 -/** @name Custom Smiley Subsystem API */
91.212 -/**************************************************************************/
91.213 -/*@{*/
91.214 -
91.215 -/**
91.216 - * Returns a list of all custom smileys. The caller should free the list.
91.217 - *
91.218 - * @return A list of all custom smileys.
91.219 - */
91.220 -GList *
91.221 -purple_smileys_get_all(void);
91.222 -
91.223 -/**
91.224 - * Returns the custom smiley given it's shortcut.
91.225 - *
91.226 - * @param shortcut The custom smiley's shortcut.
91.227 - *
91.228 - * @return The custom smiley (with a reference for the caller) if found,
91.229 - * or @c NULL if not found.
91.230 - */
91.231 -PurpleSmiley *
91.232 -purple_smileys_find_by_shortcut(const char *shortcut);
91.233 -
91.234 -/**
91.235 - * Returns the custom smiley given it's checksum.
91.236 - *
91.237 - * @param checksum The custom smiley's checksum.
91.238 - *
91.239 - * @return The custom smiley (with a reference for the caller) if found,
91.240 - * or @c NULL if not found.
91.241 - */
91.242 -PurpleSmiley *
91.243 -purple_smileys_find_by_checksum(const char *checksum);
91.244 -
91.245 -/**
91.246 - * Returns the directory used to store custom smiley cached files.
91.247 - *
91.248 - * The default directory is PURPLEDIR/smileys, unless otherwise specified
91.249 - * by purple_buddy_icons_set_cache_dir().
91.250 - *
91.251 - * @return The directory to store custom smyles cached files to.
91.252 - */
91.253 -const char *purple_smileys_get_storing_dir(void);
91.254 -
91.255 -/**
91.256 - * Initializes the custom smiley subsystem.
91.257 - */
91.258 -void purple_smileys_init(void);
91.259 -
91.260 -/**
91.261 - * Uninitializes the custom smiley subsystem.
91.262 - */
91.263 -void purple_smileys_uninit(void);
91.264 -
91.265 -/*@}*/
91.266 -
91.267 -#ifdef __cplusplus
91.268 -}
91.269 -#endif
91.270 -
91.271 -#endif /* _PURPLE_SMILEY_H_ */
91.272 -
92.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/snactypes.h Sun Jun 21 22:04:11 2009 -0400
92.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
92.3 @@ -1,291 +0,0 @@
92.4 -/*
92.5 - * Purple's oscar protocol plugin
92.6 - * This file is the legal property of its developers.
92.7 - * Please see the AUTHORS file distributed alongside this file.
92.8 - *
92.9 - * This library is free software; you can redistribute it and/or
92.10 - * modify it under the terms of the GNU Lesser General Public
92.11 - * License as published by the Free Software Foundation; either
92.12 - * version 2 of the License, or (at your option) any later version.
92.13 - *
92.14 - * This library is distributed in the hope that it will be useful,
92.15 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
92.16 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
92.17 - * Lesser General Public License for more details.
92.18 - *
92.19 - * You should have received a copy of the GNU Lesser General Public
92.20 - * License along with this library; if not, write to the Free Software
92.21 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
92.22 -*/
92.23 -
92.24 -/*
92.25 - * AIM Callback Types
92.26 - *
92.27 - */
92.28 -#ifndef _SNACTYPES_H_
92.29 -#define _SNACTYPES_H_
92.30 -
92.31 -/*
92.32 - * SNAC Families.
92.33 - */
92.34 -#define SNAC_FAMILY_OSERVICE 0x0001
92.35 -#define SNAC_FAMILY_LOCATE 0x0002
92.36 -#define SNAC_FAMILY_BUDDY 0x0003
92.37 -#define SNAC_FAMILY_ICBM 0x0004
92.38 -#define SNAC_FAMILY_ADVERT 0x0005
92.39 -#define SNAC_FAMILY_INVITE 0x0006
92.40 -#define SNAC_FAMILY_ADMIN 0x0007
92.41 -#define SNAC_FAMILY_POPUP 0x0008
92.42 -#define SNAC_FAMILY_BOS 0x0009
92.43 -#define SNAC_FAMILY_USERLOOKUP 0x000a
92.44 -#define SNAC_FAMILY_STATS 0x000b
92.45 -#define SNAC_FAMILY_TRANSLATE 0x000c
92.46 -#define SNAC_FAMILY_CHATNAV 0x000d
92.47 -#define SNAC_FAMILY_CHAT 0x000e
92.48 -#define SNAC_FAMILY_ODIR 0x000f
92.49 -#define SNAC_FAMILY_BART 0x0010
92.50 -#define SNAC_FAMILY_FEEDBAG 0x0013
92.51 -#define SNAC_FAMILY_ICQ 0x0015
92.52 -#define SNAC_FAMILY_AUTH 0x0017
92.53 -#define SNAC_FAMILY_ALERT 0x0018
92.54 -
92.55 -#define AIM_CB_FAM_SPECIAL 0xffff /* Internal libfaim use */
92.