Frameworks/libpurple.framework/Versions/0.5.6/Headers/yahoo_doodle.h
branchadium-1.3
changeset 350 708bedafdc3a
parent 349 17ef128722b7
child 351 b01ab9b157f9
     1.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/yahoo_doodle.h	Sun Jun 21 22:04:11 2009 -0400
     1.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.3 @@ -1,131 +0,0 @@
     1.4 -/**
     1.5 - * @file yahoo_doodle.h The Yahoo! protocol plugin Doodle IMVironment object
     1.6 - *
     1.7 - * purple
     1.8 - *
     1.9 - * Purple is the legal property of its developers, whose names are too numerous
    1.10 - * to list here.  Please refer to the COPYRIGHT file distributed with this
    1.11 - * source distribution.
    1.12 - *
    1.13 - * This program is free software; you can redistribute it and/or modify
    1.14 - * it under the terms of the GNU General Public License as published by
    1.15 - * the Free Software Foundation; either version 2 of the License, or
    1.16 - * (at your option) any later version.
    1.17 - *
    1.18 - * This program is distributed in the hope that it will be useful,
    1.19 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.20 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    1.21 - * GNU General Public License for more details.
    1.22 - *
    1.23 - * You should have received a copy of the GNU General Public License
    1.24 - * along with this program; if not, write to the Free Software
    1.25 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02111-1301  USA
    1.26 - */
    1.27 -
    1.28 -#ifndef _YAHOO_DOODLE_H_
    1.29 -#define _YAHOO_DOODLE_H_
    1.30 -
    1.31 -/******************************************************************************
    1.32 - * Includes
    1.33 - *****************************************************************************/
    1.34 -#include "whiteboard.h"
    1.35 -#include "cmds.h"
    1.36 -
    1.37 -#define DOODLE_IMV_KEY "doodle;106"
    1.38 -
    1.39 -/******************************************************************************
    1.40 - * Defines
    1.41 - *****************************************************************************/
    1.42 -/* Doodle communication commands */
    1.43 -/* TODO: Should be an enum. */
    1.44 -#define DOODLE_CMD_REQUEST	0
    1.45 -#define DOODLE_CMD_CLEAR	1
    1.46 -#define DOODLE_CMD_DRAW		2
    1.47 -#define DOODLE_CMD_EXTRA	3
    1.48 -#define DOODLE_CMD_READY	4
    1.49 -#define DOODLE_CMD_CONFIRM	5
    1.50 -/* Doodle communication command for shutting down (also 0) */
    1.51 -#define DOODLE_CMD_SHUTDOWN 0
    1.52 -
    1.53 -#define DOODLE_EXTRA_NONE      "\"1\""
    1.54 -#define DOODLE_EXTRA_TICTACTOE "\"3\""
    1.55 -#define DOODLE_EXTRA_DOTS      "\"2\""
    1.56 -
    1.57 -/* Doodle session states */
    1.58 -/* TODO: Should be an enum. */
    1.59 -#define DOODLE_STATE_REQUESTING  0
    1.60 -#define DOODLE_STATE_REQUESTED   1
    1.61 -#define DOODLE_STATE_ESTABLISHED 2
    1.62 -#define DOODLE_STATE_CANCELED    3
    1.63 -
    1.64 -/* Doodle canvas dimensions */
    1.65 -#define DOODLE_CANVAS_WIDTH  368
    1.66 -#define DOODLE_CANVAS_HEIGHT 256
    1.67 -
    1.68 -/* Doodle color codes (most likely RGB) */
    1.69 -/* TODO: Should be an enum and sorted by color name. */
    1.70 -#define	DOODLE_COLOR_RED    13369344
    1.71 -#define	DOODLE_COLOR_ORANGE 16737792
    1.72 -#define	DOODLE_COLOR_YELLOW 15658496
    1.73 -#define	DOODLE_COLOR_GREEN     52224
    1.74 -#define	DOODLE_COLOR_CYAN      52428
    1.75 -#define	DOODLE_COLOR_BLUE        204
    1.76 -#define	DOODLE_COLOR_VIOLET  5381277
    1.77 -#define	DOODLE_COLOR_PURPLE 13369548
    1.78 -#define	DOODLE_COLOR_TAN    12093547
    1.79 -#define	DOODLE_COLOR_BROWN   5256485
    1.80 -#define	DOODLE_COLOR_BLACK         0
    1.81 -#define	DOODLE_COLOR_GREY   11184810
    1.82 -#define	DOODLE_COLOR_WHITE  16777215
    1.83 -
    1.84 -#define PALETTE_NUM_OF_COLORS 12
    1.85 -
    1.86 -/* Doodle brush sizes (most likely variable) */
    1.87 -#define DOODLE_BRUSH_SMALL   2
    1.88 -#define DOODLE_BRUSH_MEDIUM  5
    1.89 -#define DOODLE_BRUSH_LARGE  10
    1.90 -
    1.91 -#define DOODLE_MAX_BRUSH_MOTIONS 100
    1.92 -
    1.93 -/******************************************************************************
    1.94 - * Datatypes
    1.95 - *****************************************************************************/
    1.96 -typedef struct _doodle_session
    1.97 -{
    1.98 -	int brush_size;  /* Size of drawing brush */
    1.99 -	int brush_color; /* Color of drawing brush */
   1.100 -	gchar *imv_key;
   1.101 -} doodle_session;
   1.102 -
   1.103 -/******************************************************************************
   1.104 - * API
   1.105 - *****************************************************************************/
   1.106 -
   1.107 -PurpleCmdRet yahoo_doodle_purple_cmd_start(PurpleConversation *conv, const char *cmd, char **args,
   1.108 -									   char **error, void *data);
   1.109 -
   1.110 -void yahoo_doodle_process(PurpleConnection *gc, const char *me, const char *from,
   1.111 -						  const char *command, const char *message, const char *imv_key);
   1.112 -void yahoo_doodle_initiate(PurpleConnection *gc, const char *to);
   1.113 -
   1.114 -void yahoo_doodle_command_got_shutdown(PurpleConnection *gc, const char *from);
   1.115 -
   1.116 -void yahoo_doodle_command_send_request(PurpleConnection *gc, const char *to, const char *imv_key);
   1.117 -void yahoo_doodle_command_send_ready(PurpleConnection *gc, const char *to, const char *imv_key);
   1.118 -void yahoo_doodle_command_send_draw(PurpleConnection *gc, const char *to, const char *message, const char *imv_key);
   1.119 -void yahoo_doodle_command_send_clear(PurpleConnection *gc, const char *to, const char *imv_key);
   1.120 -void yahoo_doodle_command_send_extra(PurpleConnection *gc, const char *to, const char *message, const char *imv_key);
   1.121 -void yahoo_doodle_command_send_confirm(PurpleConnection *gc, const char *to, const char *imv_key);
   1.122 -void yahoo_doodle_command_send_shutdown(PurpleConnection *gc, const char *to);
   1.123 -
   1.124 -void yahoo_doodle_start(PurpleWhiteboard *wb);
   1.125 -void yahoo_doodle_end(PurpleWhiteboard *wb);
   1.126 -void yahoo_doodle_get_dimensions(const PurpleWhiteboard *wb, int *width, int *height);
   1.127 -void yahoo_doodle_send_draw_list(PurpleWhiteboard *wb, GList *draw_list);
   1.128 -void yahoo_doodle_clear(PurpleWhiteboard *wb);
   1.129 -
   1.130 -void yahoo_doodle_draw_stroke(PurpleWhiteboard *wb, GList *draw_list);
   1.131 -void yahoo_doodle_get_brush(const PurpleWhiteboard *wb, int *size, int *color);
   1.132 -void yahoo_doodle_set_brush(PurpleWhiteboard *wb, int size, int color);
   1.133 -
   1.134 -#endif /* _YAHOO_DOODLE_H_ */