Mercurial > pidgin
comparison src/protocols/yahoo/yahoo_doodle.h @ 11801:81806e9241be
[gaim-migrate @ 14092]
Cleanups, mostly // -> /* */ and moved g_print's to gaim_debug_info, and a few c99ism fixes..
committer: Tailor Script <tailor@pidgin.im>
author | Gary Kramlich <grim@reaperworld.com> |
---|---|
date | Mon, 24 Oct 2005 21:48:21 +0000 |
parents | 32bac0647037 |
children | 2219f4bf4a57 |
comparison
equal
deleted
inserted
replaced
11800:32bac0647037 | 11801:81806e9241be |
---|---|
23 */ | 23 */ |
24 | 24 |
25 #ifndef _YAHOO_DOODLE_H_ | 25 #ifndef _YAHOO_DOODLE_H_ |
26 #define _YAHOO_DOODLE_H_ | 26 #define _YAHOO_DOODLE_H_ |
27 | 27 |
28 // INCLUDES ============================================================================================ | 28 /****************************************************************************** |
29 * Includes | |
30 *****************************************************************************/ | |
29 #include "whiteboard.h" | 31 #include "whiteboard.h" |
30 #include "cmds.h" | 32 #include "cmds.h" |
31 | 33 |
32 // DEFINES ============================================================================================= | 34 /****************************************************************************** |
33 | 35 * Defines |
34 // Doodle communication commands | 36 *****************************************************************************/ |
37 /* Doodle communication commands */ | |
35 #define DOODLE_CMD_REQUEST 0 | 38 #define DOODLE_CMD_REQUEST 0 |
36 #define DOODLE_CMD_READY 1 | 39 #define DOODLE_CMD_READY 1 |
37 #define DOODLE_CMD_CLEAR 2 | 40 #define DOODLE_CMD_CLEAR 2 |
38 #define DOODLE_CMD_DRAW 3 | 41 #define DOODLE_CMD_DRAW 3 |
39 #define DOODLE_CMD_EXTRA 4 | 42 #define DOODLE_CMD_EXTRA 4 |
40 #define DOODLE_CMD_CONFIRM 5 | 43 #define DOODLE_CMD_CONFIRM 5 |
41 | 44 |
42 // Doodle communication command for shutting down (also 0) | 45 /* Doodle communication command for shutting down (also 0) */ |
43 #define DOODLE_CMD_SHUTDOWN DOODLE_CMD_REQUEST | 46 #define DOODLE_CMD_SHUTDOWN DOODLE_CMD_REQUEST |
44 | 47 |
45 #define DOODLE_EXTRA_NONE "\"1\"" | 48 #define DOODLE_EXTRA_NONE "\"1\"" |
46 #define DOODLE_EXTRA_TICTACTOE "\"3\"" | 49 #define DOODLE_EXTRA_TICTACTOE "\"3\"" |
47 #define DOODLE_EXTRA_DOTS "\"2\"" | 50 #define DOODLE_EXTRA_DOTS "\"2\"" |
48 | 51 |
49 // Doodle session states | 52 /* Doodle session states */ |
50 #define DOODLE_STATE_REQUESTING 0 | 53 #define DOODLE_STATE_REQUESTING 0 |
51 #define DOODLE_STATE_REQUESTED 1 | 54 #define DOODLE_STATE_REQUESTED 1 |
52 #define DOODLE_STATE_ESTABLISHED 2 | 55 #define DOODLE_STATE_ESTABLISHED 2 |
53 | 56 |
54 // Doodle canvas dimensions | 57 /* Doodle canvas dimensions */ |
55 #define DOODLE_CANVAS_WIDTH 368 | 58 #define DOODLE_CANVAS_WIDTH 368 |
56 #define DOODLE_CANVAS_HEIGHT 256 | 59 #define DOODLE_CANVAS_HEIGHT 256 |
57 | 60 |
58 // Doodle color codes (most likely RGB) | 61 /* Doodle color codes (most likely RGB) */ |
59 #define DOODLE_COLOR_RED 13369344 | 62 #define DOODLE_COLOR_RED 13369344 |
60 #define DOODLE_COLOR_ORANGE 16737792 | 63 #define DOODLE_COLOR_ORANGE 16737792 |
61 #define DOODLE_COLOR_YELLOW 15658496 | 64 #define DOODLE_COLOR_YELLOW 15658496 |
62 #define DOODLE_COLOR_GREEN 52224 | 65 #define DOODLE_COLOR_GREEN 52224 |
63 #define DOODLE_COLOR_CYAN 52428 | 66 #define DOODLE_COLOR_CYAN 52428 |
70 #define DOODLE_COLOR_GREY 11184810 | 73 #define DOODLE_COLOR_GREY 11184810 |
71 #define DOODLE_COLOR_WHITE 16777215 | 74 #define DOODLE_COLOR_WHITE 16777215 |
72 | 75 |
73 #define PALETTE_NUM_OF_COLORS 12 | 76 #define PALETTE_NUM_OF_COLORS 12 |
74 | 77 |
75 // Doodle brush sizes (most likely variable) | 78 /* Doodle brush sizes (most likely variable) */ |
76 #define DOODLE_BRUSH_SMALL 2 | 79 #define DOODLE_BRUSH_SMALL 2 |
77 #define DOODLE_BRUSH_MEDIUM 5 | 80 #define DOODLE_BRUSH_MEDIUM 5 |
78 #define DOODLE_BRUSH_LARGE 10 | 81 #define DOODLE_BRUSH_LARGE 10 |
79 | 82 |
80 #define DOODLE_MAX_BRUSH_MOTIONS 100 | 83 #define DOODLE_MAX_BRUSH_MOTIONS 100 |
81 | 84 |
82 // DATATYPES =========================================================================================== | 85 /****************************************************************************** |
86 * Datatypes | |
87 *****************************************************************************/ | |
83 typedef struct _doodle_session | 88 typedef struct _doodle_session |
84 { | 89 { |
85 int brush_size; // Size of drawing brush | 90 int brush_size; /* Size of drawing brush */ |
86 int brush_color; // Color of drawing brush | 91 int brush_color; /* Color of drawing brush */ |
87 } doodle_session; | 92 } doodle_session; |
88 | 93 |
89 // PROTOTYPES ========================================================================================== | 94 /****************************************************************************** |
90 | 95 * API |
96 *****************************************************************************/ | |
91 void dummy_func( void ); | 97 void dummy_func( void ); |
92 | 98 |
93 GaimCmdRet yahoo_doodle_gaim_cmd_start( GaimConversation *conv, const char *cmd, char **args, | 99 GaimCmdRet yahoo_doodle_gaim_cmd_start( GaimConversation *conv, const char *cmd, char **args, |
94 char **error, void *data ); | 100 char **error, void *data ); |
95 | 101 |
119 void yahoo_doodle_clear( GaimWhiteboard *wb ); | 125 void yahoo_doodle_clear( GaimWhiteboard *wb ); |
120 | 126 |
121 void yahoo_doodle_draw_stroke( GaimWhiteboard *wb, GList *draw_list ); | 127 void yahoo_doodle_draw_stroke( GaimWhiteboard *wb, GList *draw_list ); |
122 char *yahoo_doodle_build_draw_string( doodle_session *ds, GList *draw_list ); | 128 char *yahoo_doodle_build_draw_string( doodle_session *ds, GList *draw_list ); |
123 | 129 |
124 #endif // _YAHOO_DOODLE_H_ | 130 #endif /* _YAHOO_DOODLE_H_ */ |