Mercurial > pidgin
comparison src/multi.c @ 3067:b695cbbeee2d
[gaim-migrate @ 3081]
removed some compile warnings
committer: Tailor Script <tailor@pidgin.im>
author | Sean Egan <seanegan@gmail.com> |
---|---|
date | Sun, 17 Mar 2002 01:22:35 +0000 |
parents | 3b1dc99ef79e |
children | cbb8b9b4ca4a |
comparison
equal
deleted
inserted
replaced
3066:3b1dc99ef79e | 3067:b695cbbeee2d |
---|---|
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
19 * | 19 * |
20 */ | 20 */ |
21 | 21 |
22 #include <string.h> | 22 #include <string.h> |
23 #include <ctype.h> | |
23 #include <gtk/gtk.h> | 24 #include <gtk/gtk.h> |
24 #include "prpl.h" | 25 #include "prpl.h" |
25 #include "multi.h" | 26 #include "multi.h" |
26 #include "gaim.h" | 27 #include "gaim.h" |
27 #ifdef USE_APPLET | 28 #ifdef USE_APPLET |
892 | 893 |
893 static void acct_signin(GtkWidget *w, gpointer d) | 894 static void acct_signin(GtkWidget *w, gpointer d) |
894 { | 895 { |
895 GList *l = GTK_CLIST(list)->selection; | 896 GList *l = GTK_CLIST(list)->selection; |
896 int row = -1; | 897 int row = -1; |
897 struct aim_user *u; | 898 struct aim_user *u = NULL; |
898 struct prpl *p = find_prpl(u->protocol); | 899 struct prpl *p = find_prpl(u->protocol); |
899 while (l) { | 900 while (l) { |
900 row = (int)l->data; | 901 row = (int)l->data; |
901 u = g_slist_nth_data(aim_users, row); | 902 u = g_slist_nth_data(aim_users, row); |
902 serv_login(u); | 903 serv_login(u); |
1047 }; | 1048 }; |
1048 static GSList *meters = NULL; | 1049 static GSList *meters = NULL; |
1049 | 1050 |
1050 GtkWidget* create_meter_pixmap (GtkWidget *widget, struct gaim_connection *gc) | 1051 GtkWidget* create_meter_pixmap (GtkWidget *widget, struct gaim_connection *gc) |
1051 { | 1052 { |
1052 GdkColormap *colormap; | |
1053 GdkPixmap *gdkpixmap; | 1053 GdkPixmap *gdkpixmap; |
1054 GdkBitmap *mask; | 1054 GdkBitmap *mask; |
1055 GtkWidget *pixmap; | 1055 GtkWidget *pixmap; |
1056 GtkStyle *style; | 1056 GtkStyle *style; |
1057 char **xpm; | 1057 char **xpm = NULL; |
1058 | 1058 |
1059 style = gtk_widget_get_style( widget ); | 1059 style = gtk_widget_get_style( widget ); |
1060 | 1060 |
1061 if (gc->prpl->list_icon) | 1061 if (gc->prpl->list_icon) |
1062 if (gc->prpl->protocol == PROTO_OSCAR) | 1062 if (gc->prpl->protocol == PROTO_OSCAR) { |
1063 /* This is such a bad hack to get the right icon | 1063 /* This is such a bad hack to get the right icon |
1064 * for OSCAR. But it's pretty */ | 1064 * for OSCAR. But it's pretty */ |
1065 if (isdigit(*gc->username)) | 1065 if (isdigit(*gc->username)) { |
1066 xpm = gc->prpl->list_icon(0); | 1066 xpm = gc->prpl->list_icon(0); |
1067 else | 1067 } else { |
1068 xpm = gc->prpl->list_icon(0x10); | 1068 xpm = gc->prpl->list_icon(0x10); |
1069 else | 1069 } |
1070 } else { | |
1070 xpm = gc->prpl->list_icon (0); | 1071 xpm = gc->prpl->list_icon (0); |
1072 } | |
1071 if (xpm == NULL) | 1073 if (xpm == NULL) |
1072 xpm = (char **)no_icon_xpm; | 1074 xpm = (char **)no_icon_xpm; |
1073 | 1075 |
1074 gdkpixmap = gdk_pixmap_create_from_xpm_d(widget->window, &mask, &style->bg[GTK_STATE_NORMAL], xpm); | 1076 gdkpixmap = gdk_pixmap_create_from_xpm_d(widget->window, &mask, &style->bg[GTK_STATE_NORMAL], xpm); |
1075 | 1077 |
1280 gtk_widget_hide(mainwindow); | 1282 gtk_widget_hide(mainwindow); |
1281 | 1283 |
1282 if (!meter_win) { | 1284 if (!meter_win) { |
1283 GtkWidget *cancel_button; | 1285 GtkWidget *cancel_button; |
1284 GtkWidget *vbox; | 1286 GtkWidget *vbox; |
1285 GString *name; | 1287 |
1286 | |
1287 meter_win = g_new0(struct meter_window, 1); | 1288 meter_win = g_new0(struct meter_window, 1); |
1288 meter_win->rows=0; | 1289 meter_win->rows=0; |
1289 | 1290 |
1290 meter_win->window = gtk_window_new (GTK_WINDOW_TOPLEVEL); | 1291 meter_win->window = gtk_window_new (GTK_WINDOW_TOPLEVEL); |
1291 GAIM_DIALOG(meter_win->window); | 1292 GAIM_DIALOG(meter_win->window); |