From: Christian H. <ch...@us...> - 2003-06-02 21:51:31
|
Update of /cvsroot/gaim/gaim/plugins In directory sc8-pr-cvs1:/tmp/cvs-serv8218/plugins Modified Files: events.c filectl.c history.c iconaway.c notify.c statenotify.c timestamp.c Log Message: I've been meaning to do this for a LONG time. The conversation API now follows the naming convention of the rest of the new APIs. I'll get some g_return_*_if_fail() checks in there soon. Index: events.c =================================================================== RCS file: /cvsroot/gaim/gaim/plugins/events.c,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- events.c 28 Apr 2003 18:45:34 -0000 1.10 +++ events.c 2 Jun 2003 21:50:55 -0000 1.11 @@ -161,7 +161,7 @@ printf("event_got_typing: %s\n", who); } -static evt_del_conversation(struct gaim_conversation *c, void *data) +static evt_del_conversation(GaimConversation *c, void *data) { printf("event_del_conversation\n"); } Index: filectl.c =================================================================== RCS file: /cvsroot/gaim/gaim/plugins/filectl.c,v retrieving revision 1.18 retrieving revision 1.19 diff -u -d -r1.18 -r1.19 --- filectl.c 28 Apr 2003 18:45:36 -0000 1.18 +++ filectl.c 2 Jun 2003 21:50:55 -0000 1.19 @@ -72,7 +72,7 @@ signoff_all(NULL, NULL); free(arg1); } else if (!strncasecmp(command, "send", 4)) { - struct gaim_conversation *c; + GaimConversation *c; arg1 = getarg(buffer, 1, 0); arg2 = getarg(buffer, 2, 1); c = find_conversation(arg1); Index: history.c =================================================================== RCS file: /cvsroot/gaim/gaim/plugins/history.c,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- history.c 31 May 2003 14:43:07 -0000 1.12 +++ history.c 2 Jun 2003 21:50:56 -0000 1.13 @@ -17,8 +17,8 @@ void historize (char *name, void *data) { - struct gaim_conversation *c = gaim_find_conversation(name); - struct gaim_gtk_conversation *gtkconv; + GaimConversation *c = gaim_find_conversation(name); + GaimGtkConversation *gtkconv; struct stat st; FILE *fd; char *userdir = g_strdup(gaim_user_dir()); Index: iconaway.c =================================================================== RCS file: /cvsroot/gaim/gaim/plugins/iconaway.c,v retrieving revision 1.28 retrieving revision 1.29 diff -u -d -r1.28 -r1.29 --- iconaway.c 31 May 2003 14:38:03 -0000 1.28 +++ iconaway.c 2 Jun 2003 21:50:56 -0000 1.29 @@ -20,7 +20,7 @@ void iconify_windows(GaimConnection *gc, char *state, char *message, void *data) { - struct gaim_window *win; + GaimWindow *win; GList *windows; if (!imaway || !gc->away) @@ -33,10 +33,10 @@ windows != NULL; windows = windows->next) { - win = (struct gaim_window *)windows->data; + win = (GaimWindow *)windows->data; if (GAIM_IS_GTK_WINDOW(win)) { - struct gaim_gtk_window *gtkwin; + GaimGtkWindow *gtkwin; gtkwin = GAIM_GTK_WINDOW(win); Index: notify.c =================================================================== RCS file: /cvsroot/gaim/gaim/plugins/notify.c,v retrieving revision 1.34 retrieving revision 1.35 diff -u -d -r1.34 -r1.35 --- notify.c 26 May 2003 08:30:41 -0000 1.34 +++ notify.c 2 Jun 2003 21:50:56 -0000 1.35 @@ -71,11 +71,11 @@ void quote_add(GtkWidget *widget); gboolean quote_remove(GtkWidget *widget); /* urgent functions */ -void urgent_add(struct gaim_conversation *c); -gboolean urgent_remove(struct gaim_conversation *c); +void urgent_add(GaimConversation *c); +gboolean urgent_remove(GaimConversation *c); -int notify(struct gaim_conversation *cnv) { - struct gaim_gtk_window *gtkwin; +int notify(GaimConversation *cnv) { + GaimGtkWindow *gtkwin; Window focus_return; int revert_to_return; @@ -97,8 +97,8 @@ return 0; } -guint unnotify(struct gaim_conversation *c, gboolean clean) { - struct gaim_gtk_window *gtkwin; +guint unnotify(GaimConversation *c, gboolean clean) { + GaimGtkWindow *gtkwin; guint option = 0; gtkwin = GAIM_GTK_WINDOW(gaim_conversation_get_window(c)); @@ -130,7 +130,7 @@ } void chat_recv_im(struct gaim_connection *gc, int id, char **who, char **text) { - struct gaim_conversation *c = gaim_find_chat(gc, id); + GaimConversation *c = gaim_find_chat(gc, id); if (c && (type & TYPE_CHAT)) notify(c); @@ -138,7 +138,7 @@ } void chat_sent_im(struct gaim_connection *gc, int id, char **text) { - struct gaim_conversation *c = gaim_find_chat(gc, id); + GaimConversation *c = gaim_find_chat(gc, id); if (c && (type & TYPE_CHAT)) unnotify(c, FALSE); @@ -146,7 +146,7 @@ } int im_recv_im(struct gaim_connection *gc, char **who, char **what, void *m) { - struct gaim_conversation *c = gaim_find_conversation(*who); + GaimConversation *c = gaim_find_conversation(*who); if (c && (type & TYPE_IM)) notify(c); @@ -154,16 +154,16 @@ } int im_sent_im(struct gaim_connection *gc, char *who, char **what, void *m) { - struct gaim_conversation *c = gaim_find_conversation(who); + GaimConversation *c = gaim_find_conversation(who); if (c && (type & TYPE_IM)) unnotify(c, FALSE); return 0; } -int attach_signals(struct gaim_conversation *c) { - struct gaim_gtk_conversation *gtkconv; - struct gaim_gtk_window *gtkwin; +int attach_signals(GaimConversation *c) { + GaimGtkConversation *gtkconv; + GaimGtkWindow *gtkwin; gtkconv = GAIM_GTK_CONVERSATION(c); gtkwin = GAIM_GTK_WINDOW(gaim_conversation_get_window(c)); @@ -189,9 +189,9 @@ return 0; } -void detach_signals(struct gaim_conversation *c) { - struct gaim_gtk_conversation *gtkconv; - struct gaim_gtk_window *gtkwin; +void detach_signals(GaimConversation *c) { + GaimGtkConversation *gtkconv; + GaimGtkWindow *gtkwin; guint options; gtkconv = GAIM_GTK_CONVERSATION(c); @@ -214,21 +214,21 @@ } void new_conv(char *who) { - struct gaim_conversation *c = gaim_find_conversation(who); + GaimConversation *c = gaim_find_conversation(who); if (c && (type & TYPE_IM)) attach_signals(c); } void chat_join(struct gaim_connection *gc, int id, char *room) { - struct gaim_conversation *c = gaim_find_chat(gc, id); + GaimConversation *c = gaim_find_chat(gc, id); if (c && (type & TYPE_CHAT)) attach_signals(c); } int un_star(GtkWidget *widget, gpointer data) { - struct gaim_conversation *c = g_object_get_data(G_OBJECT(widget), "user_data"); + GaimConversation *c = g_object_get_data(G_OBJECT(widget), "user_data"); if (method & METHOD_QUOTE) quote_remove(widget); @@ -354,8 +354,8 @@ return FALSE; } -void urgent_add(struct gaim_conversation *c) { - struct gaim_gtk_window *gtkwin; +void urgent_add(GaimConversation *c) { + GaimGtkWindow *gtkwin; XWMHints *hints; gtkwin = GAIM_GTK_WINDOW(gaim_conversation_get_window(c)); @@ -366,8 +366,8 @@ XFree(hints); } -gboolean urgent_remove(struct gaim_conversation *c) { - struct gaim_gtk_conversation *gtkconv; +gboolean urgent_remove(GaimConversation *c) { + GaimGtkConversation *gtkconv; gtkconv = GAIM_GTK_CONVERSATION(c); @@ -376,8 +376,8 @@ (gaim_conversation_get_type(c) != GAIM_CONV_CHAT && (im_options & OPT_IM_ONE_WINDOW))) { if (gaim_conversation_get_type(c) == GAIM_CONV_CHAT) { - struct gaim_conversation *c = (struct gaim_conversation *)gaim_get_chats()->data; - struct gaim_gtk_window *gtkwin; + GaimConversation *c = (GaimConversation *)gaim_get_chats()->data; + GaimGtkWindow *gtkwin; GdkWindow *win; XWMHints *hints; @@ -395,12 +395,12 @@ XFree(hints); return FALSE; } else { - struct gaim_conversation *c; - struct gaim_gtk_window *gtkwin; + GaimConversation *c; + GaimGtkWindow *gtkwin; GdkWindow *win; XWMHints *hints; - c = (struct gaim_conversation *)gaim_get_ims()->data; + c = (GaimConversation *)gaim_get_ims()->data; gtkwin = GAIM_GTK_WINDOW(gaim_conversation_get_window(c)); win = gtkwin->window->window; @@ -415,7 +415,7 @@ return FALSE; } } else { - struct gaim_gtk_window *gtkwin; + GaimGtkWindow *gtkwin; XWMHints *hints; gtkwin = GAIM_GTK_WINDOW(gaim_conversation_get_window(c)); @@ -527,9 +527,9 @@ while (cnv) { guint notification; - struct gaim_conversation *c = (struct gaim_conversation *) cnv->data; - struct gaim_gtk_conversation *gtkconv; - struct gaim_gtk_window *gtkwin; + GaimConversation *c = (GaimConversation *) cnv->data; + GaimGtkConversation *gtkconv; + GaimGtkWindow *gtkwin; guint options = GPOINTER_TO_UINT(g_object_get_data(G_OBJECT(c->window), "notify_data")); gtkconv = GAIM_GTK_CONVERSATION(c); @@ -664,8 +664,8 @@ GList *c = gaim_get_conversations(); while (c) { - struct gaim_conversation *cnv = (struct gaim_conversation *)c->data; - struct gaim_gtk_window *gtkwin; + GaimConversation *cnv = (GaimConversation *)c->data; + GaimGtkWindow *gtkwin; gtkwin = GAIM_GTK_WINDOW(gaim_conversation_get_window(cnv)); Index: statenotify.c =================================================================== RCS file: /cvsroot/gaim/gaim/plugins/statenotify.c,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- statenotify.c 31 May 2003 06:59:58 -0000 1.2 +++ statenotify.c 2 Jun 2003 21:50:56 -0000 1.3 @@ -3,7 +3,7 @@ static void write_status(GaimConnection *gc, char *who, const char *message) { - struct gaim_conversation *conv; + GaimConversation *conv; struct buddy *b; char buf[256]; Index: timestamp.c =================================================================== RCS file: /cvsroot/gaim/gaim/plugins/timestamp.c,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- timestamp.c 26 May 2003 08:30:42 -0000 1.15 +++ timestamp.c 2 Jun 2003 21:50:56 -0000 1.16 @@ -19,7 +19,7 @@ gboolean do_timestamp (gpointer data) { - struct gaim_conversation *c = (struct gaim_conversation *)data; + GaimConversation *c = (GaimConversation *)data; char *buf; char mdate[6]; time_t tim = time(NULL); @@ -36,7 +36,7 @@ void timestamp_new_convo(char *name) { - struct gaim_conversation *c = gaim_find_conversation(name); + GaimConversation *c = gaim_find_conversation(name); do_timestamp(c); timestamp_timeouts = g_slist_append(timestamp_timeouts, @@ -101,7 +101,7 @@ plugin_load(GaimPlugin *plugin) { GList *cnvs; - struct gaim_conversation *c; + GaimConversation *c; for (cnvs = gaim_get_conversations(); cnvs != NULL; cnvs = cnvs->next) { c = cnvs->data; |