Mercurial > pidgin.yaz
comparison src/oscar.c @ 1906:42aa9434800a
[gaim-migrate @ 1916]
gah.
committer: Tailor Script <tailor@pidgin.im>
author | Eric Warmenhoven <eric@warmenhoven.org> |
---|---|
date | Mon, 28 May 2001 20:37:58 +0000 |
parents | 17ae421bb214 |
children | 1cfc79c126fe |
comparison
equal
deleted
inserted
replaced
1905:17ae421bb214 | 1906:42aa9434800a |
---|---|
41 #include "prpl.h" | 41 #include "prpl.h" |
42 #include "gaim.h" | 42 #include "gaim.h" |
43 #include "aim.h" | 43 #include "aim.h" |
44 #include "proxy.h" | 44 #include "proxy.h" |
45 | 45 |
46 #if USE_GNOME | 46 #if USE_PIXBUF |
47 #include <gdk-pixbuf/gdk-pixbuf.h> | 47 #include <gdk-pixbuf/gdk-pixbuf.h> |
48 #include <gdk-pixbuf/gdk-pixbuf-loader.h> | 48 #include <gdk-pixbuf/gdk-pixbuf-loader.h> |
49 #endif | 49 #endif |
50 | 50 |
51 /*#include "pixmaps/cancel.xpm"*/ | 51 /*#include "pixmaps/cancel.xpm"*/ |
60 #define USEROPT_AUTHPORT 1 | 60 #define USEROPT_AUTHPORT 1 |
61 | 61 |
62 #define AIMHASHDATA "http://gaim.sourceforge.net/aim_data.php3" | 62 #define AIMHASHDATA "http://gaim.sourceforge.net/aim_data.php3" |
63 | 63 |
64 static int gaim_caps = AIM_CAPS_CHAT | | 64 static int gaim_caps = AIM_CAPS_CHAT | |
65 #if USE_GNOME | 65 #if USE_PIXBUF |
66 AIM_CAPS_BUDDYICON | | 66 AIM_CAPS_BUDDYICON | |
67 #endif | 67 #endif |
68 AIM_CAPS_GETFILE | | 68 AIM_CAPS_GETFILE | |
69 AIM_CAPS_IMIMAGE; | 69 AIM_CAPS_IMIMAGE; |
70 | 70 |
141 GtkWidget *label; | 141 GtkWidget *label; |
142 long pos; | 142 long pos; |
143 long size; | 143 long size; |
144 }; | 144 }; |
145 | 145 |
146 #if USE_GNOME | 146 #if USE_PIXBUF |
147 struct icon_req { | 147 struct icon_req { |
148 char *user; | 148 char *user; |
149 time_t timestamp; | 149 time_t timestamp; |
150 unsigned long length; | 150 unsigned long length; |
151 gpointer data; | 151 gpointer data; |
520 if (n->watcher > 0) | 520 if (n->watcher > 0) |
521 gdk_input_remove(n->watcher); | 521 gdk_input_remove(n->watcher); |
522 odata->direct_ims = g_slist_remove(odata->direct_ims, n); | 522 odata->direct_ims = g_slist_remove(odata->direct_ims, n); |
523 g_free(n); | 523 g_free(n); |
524 } | 524 } |
525 #if USE_GNOME | 525 #if USE_PIXBUF |
526 while (odata->hasicons) { | 526 while (odata->hasicons) { |
527 struct icon_req *n = odata->hasicons->data; | 527 struct icon_req *n = odata->hasicons->data; |
528 gdk_pixbuf_animation_unref(n->anim); | 528 gdk_pixbuf_animation_unref(n->anim); |
529 if (n->timer) | 529 if (n->timer) |
530 gtk_timeout_remove(n->timer); | 530 gtk_timeout_remove(n->timer); |
1591 | 1591 |
1592 return TRUE; | 1592 return TRUE; |
1593 } | 1593 } |
1594 */ | 1594 */ |
1595 | 1595 |
1596 #if USE_GNOME | 1596 #if USE_PIXBUF |
1597 static gboolean redraw_anim(gpointer data) | 1597 static gboolean redraw_anim(gpointer data) |
1598 { | 1598 { |
1599 int delay; | 1599 int delay; |
1600 struct icon_req *ir = data; | 1600 struct icon_req *ir = data; |
1601 GList *frames; | 1601 GList *frames; |
1661 struct aim_incomingim_ch1_args *args; | 1661 struct aim_incomingim_ch1_args *args; |
1662 | 1662 |
1663 args = va_arg(ap, struct aim_incomingim_ch1_args *); | 1663 args = va_arg(ap, struct aim_incomingim_ch1_args *); |
1664 va_end(ap); | 1664 va_end(ap); |
1665 | 1665 |
1666 #if USE_GNOME | 1666 #if USE_PIXBUF |
1667 if (args->icbmflags & AIM_IMFLAGS_HASICON) { | 1667 if (args->icbmflags & AIM_IMFLAGS_HASICON) { |
1668 struct oscar_data *od = gc->proto_data; | 1668 struct oscar_data *od = gc->proto_data; |
1669 struct icon_req *ir; | 1669 struct icon_req *ir; |
1670 GSList *h = od->hasicons; | 1670 GSList *h = od->hasicons; |
1671 char *who = normalize(userinfo->sn); | 1671 char *who = normalize(userinfo->sn); |
1723 userinfo->sn, gc->username); | 1723 userinfo->sn, gc->username); |
1724 do_ask_dialog(buf, g, accept_getfile, cancel_getfile); | 1724 do_ask_dialog(buf, g, accept_getfile, cancel_getfile); |
1725 */ | 1725 */ |
1726 } else if (args->reqclass & AIM_CAPS_VOICE) { | 1726 } else if (args->reqclass & AIM_CAPS_VOICE) { |
1727 } else if (args->reqclass & AIM_CAPS_BUDDYICON) { | 1727 } else if (args->reqclass & AIM_CAPS_BUDDYICON) { |
1728 #if USE_GNOME | 1728 #if USE_PIXBUF |
1729 struct oscar_data *od = gc->proto_data; | 1729 struct oscar_data *od = gc->proto_data; |
1730 GSList *h = od->hasicons; | 1730 GSList *h = od->hasicons; |
1731 struct icon_req *ir = NULL; | 1731 struct icon_req *ir = NULL; |
1732 char *who; | 1732 char *who; |
1733 struct conversation *c; | 1733 struct conversation *c; |
2437 } else { | 2437 } else { |
2438 if (away) | 2438 if (away) |
2439 aim_send_im(odata->sess, odata->conn, name, AIM_IMFLAGS_AWAY, message); | 2439 aim_send_im(odata->sess, odata->conn, name, AIM_IMFLAGS_AWAY, message); |
2440 else { | 2440 else { |
2441 int flags = AIM_IMFLAGS_ACK; | 2441 int flags = AIM_IMFLAGS_ACK; |
2442 #if USE_GNOME | 2442 #if USE_PIXBUF |
2443 GSList *h = odata->hasicons; | 2443 GSList *h = odata->hasicons; |
2444 struct icon_req *ir; | 2444 struct icon_req *ir; |
2445 char *who = normalize(name); | 2445 char *who = normalize(name); |
2446 while (h) { | 2446 while (h) { |
2447 ir = h->data; | 2447 ir = h->data; |
3125 } | 3125 } |
3126 } | 3126 } |
3127 | 3127 |
3128 static void oscar_insert_convo(struct gaim_connection *gc, struct conversation *c) | 3128 static void oscar_insert_convo(struct gaim_connection *gc, struct conversation *c) |
3129 { | 3129 { |
3130 #if USE_GNOME | 3130 #if USE_PIXBUF |
3131 struct oscar_data *od = gc->proto_data; | 3131 struct oscar_data *od = gc->proto_data; |
3132 GSList *h = od->hasicons; | 3132 GSList *h = od->hasicons; |
3133 struct icon_req *ir = NULL; | 3133 struct icon_req *ir = NULL; |
3134 char *who = normalize(c->name); | 3134 char *who = normalize(c->name); |
3135 | 3135 |
3171 #endif | 3171 #endif |
3172 } | 3172 } |
3173 | 3173 |
3174 static void oscar_remove_convo(struct gaim_connection *gc, struct conversation *c) | 3174 static void oscar_remove_convo(struct gaim_connection *gc, struct conversation *c) |
3175 { | 3175 { |
3176 #if USE_GNOME | 3176 #if USE_PIXBUF |
3177 struct oscar_data *od = gc->proto_data; | 3177 struct oscar_data *od = gc->proto_data; |
3178 GSList *h = od->hasicons; | 3178 GSList *h = od->hasicons; |
3179 struct icon_req *ir = NULL; | 3179 struct icon_req *ir = NULL; |
3180 char *who = normalize(c->name); | 3180 char *who = normalize(c->name); |
3181 | 3181 |