changeset 604:0b1a132e0f75

[gaim-migrate @ 614] gaim passes the -Wall test again committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Fri, 04 Aug 2000 04:45:51 +0000
parents 9b0717b4a490
children 1dbc72baf900
files src/buddy_chat.c src/conversation.c src/convo.h src/gaim.h src/gtkhtml.c src/oscar.c src/ticker.c
diffstat 7 files changed, 53 insertions(+), 84 deletions(-) [+]
line wrap: on
line diff
--- a/src/buddy_chat.c	Fri Aug 04 04:08:31 2000 +0000
+++ b/src/buddy_chat.c	Fri Aug 04 04:45:51 2000 +0000
@@ -33,6 +33,10 @@
 
 #include "convo.h"
 
+#include "pixmaps/join.xpm"
+#include "pixmaps/cancel.xpm"
+
+
 static GtkWidget *joinchat;
 static GtkWidget *entry;
 static GtkWidget *invite;
--- a/src/conversation.c	Fri Aug 04 04:08:31 2000 +0000
+++ b/src/conversation.c	Fri Aug 04 04:45:51 2000 +0000
@@ -35,6 +35,39 @@
 #include <gdk/gdkkeysyms.h>
 #include "convo.h"
 
+#include "pixmaps/underline.xpm"
+#include "pixmaps/bold.xpm"
+#include "pixmaps/italic.xpm"
+#include "pixmaps/small.xpm"
+#include "pixmaps/normal.xpm"
+#include "pixmaps/big.xpm"
+#include "pixmaps/fontface.xpm"
+#include "pixmaps/speaker.xpm"
+/* #include "pixmaps/aimicon2.xpm" */
+#include "pixmaps/wood.xpm"
+#include "pixmaps/palette.xpm"
+#include "pixmaps/link.xpm"
+#include "pixmaps/strike.xpm"
+
+#include "pixmaps/angel.xpm"
+#include "pixmaps/bigsmile.xpm"
+#include "pixmaps/burp.xpm"
+#include "pixmaps/crossedlips.xpm"
+#include "pixmaps/cry.xpm"
+#include "pixmaps/embarrassed.xpm"
+#include "pixmaps/kiss.xpm"
+#include "pixmaps/moneymouth.xpm"
+#include "pixmaps/sad.xpm"
+#include "pixmaps/scream.xpm"
+#include "pixmaps/smile.xpm"
+#include "pixmaps/smile8.xpm"
+#include "pixmaps/think.xpm"
+#include "pixmaps/tongue.xpm"
+#include "pixmaps/wink.xpm"
+#include "pixmaps/yell.xpm"
+#include "pixmaps/luke03.xpm"
+
+
 int state_lock=0;
 
 GdkPixmap *dark_icon_pm = NULL;
@@ -395,12 +428,6 @@
 	return FALSE;
 }
 
-static void color_callback(GtkWidget *widget, struct conversation *c)
-{
-	/* show_color_dialog(c); */
-	gtk_widget_grab_focus(c->entry);
-}
-
 void add_callback(GtkWidget *widget, struct conversation *c)
 {
 	if (find_buddy(c->name) != NULL) {
--- a/src/convo.h	Fri Aug 04 04:08:31 2000 +0000
+++ b/src/convo.h	Fri Aug 04 04:45:51 2000 +0000
@@ -25,41 +25,6 @@
 #include <gtk/gtk.h>
 #include "gaim.h"
 
-#include "pixmaps/underline.xpm"
-#include "pixmaps/bold.xpm"
-#include "pixmaps/italic.xpm"
-#include "pixmaps/small.xpm"
-#include "pixmaps/normal.xpm"
-#include "pixmaps/big.xpm"
-#include "pixmaps/fontface.xpm"
-#include "pixmaps/speaker.xpm"
-/* #include "pixmaps/aimicon2.xpm" */
-#include "pixmaps/wood.xpm"
-#include "pixmaps/palette.xpm"
-#include "pixmaps/link.xpm"
-#include "pixmaps/strike.xpm"
-
-#include "pixmaps/angel.xpm"
-#include "pixmaps/bigsmile.xpm"
-#include "pixmaps/burp.xpm"
-#include "pixmaps/crossedlips.xpm"
-#include "pixmaps/cry.xpm"
-#include "pixmaps/embarrassed.xpm"
-#include "pixmaps/kiss.xpm"
-#include "pixmaps/moneymouth.xpm"
-#include "pixmaps/sad.xpm"
-#include "pixmaps/scream.xpm"
-#include "pixmaps/smile.xpm"
-#include "pixmaps/smile8.xpm"
-#include "pixmaps/think.xpm"
-#include "pixmaps/tongue.xpm"
-#include "pixmaps/wink.xpm"
-#include "pixmaps/yell.xpm"
-#include "pixmaps/luke03.xpm"
-
-#include "pixmaps/join.xpm"
-#include "pixmaps/cancel.xpm"
-
 
 /* we declare all of the global functions for chat and IM windows here, so
  * that it's easy to keep them merged. */
--- a/src/gaim.h	Fri Aug 04 04:08:31 2000 +0000
+++ b/src/gaim.h	Fri Aug 04 04:45:51 2000 +0000
@@ -405,7 +405,7 @@
 #define TYPE_SIGNOFF   4
 #define TYPE_KEEPALIVE 5
 
-#define REVISION "gaim:$Revision: 613 $"
+#define REVISION "gaim:$Revision: 614 $"
 #define FLAPON "FLAPON\r\n\r\n"
 
 #define ROAST "Tic/Toc"
@@ -610,6 +610,7 @@
 extern void serv_chat_whisper(int, char *, char *);
 extern void serv_chat_send(int, char *);
 extern void serv_do_imimage(GtkWidget *, char *);
+extern void serv_got_imimage(char *, char *, char *, struct aim_conn_t *, int);
 
 /* output from serv */
 extern void serv_got_update(char *, int, int, time_t, time_t, int, u_short);
@@ -797,3 +798,9 @@
 /* functions for appletmgr */
 extern char * getConfig();
 
+/* fucntions in ticker.c */
+void SetTickerPrefs();
+void BuddyTickerSignOff();
+void BuddyTickerAddUser(char *, GdkPixmap *, GdkBitmap *);
+void BuddyTickerSetPixmap(char *, GdkPixmap *, GdkBitmap *);
+void BuddyTickerSignoff();
--- a/src/gtkhtml.c	Fri Aug 04 04:08:31 2000 +0000
+++ b/src/gtkhtml.c	Fri Aug 04 04:45:51 2000 +0000
@@ -30,6 +30,7 @@
 #include <gdk/gdkprivate.h>
 #include <gdk/gdkx.h>
 #include <gdk/gdkkeysyms.h>
+#include <ctype.h>
 
 #ifndef _WIN32
 #include <X11/Xlib.h>
--- a/src/oscar.c	Fri Aug 04 04:08:31 2000 +0000
+++ b/src/oscar.c	Fri Aug 04 04:45:51 2000 +0000
@@ -592,10 +592,6 @@
 	GtkWidget *label;
 	GtkWidget *yes;
 	GtkWidget *no;
-	GtkWidget *button;
-	GdkBitmap *mask;
-	GdkPixmap *pm;
-	GtkWidget *image;
 	char buf[BUF_LONG];
 
 	window = gtk_window_new(GTK_WINDOW_DIALOG);
@@ -618,43 +614,11 @@
 	gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 5);
 	gtk_widget_show(hbox);
 
-	yes = gtk_button_new();
+	yes = picture_button(window, _("Accept"), ok_xpm);
 	gtk_box_pack_start(GTK_BOX(hbox), yes, FALSE, FALSE, 5);
-	gtk_widget_show(yes);
-	if (display_options & OPT_DISP_COOL_LOOK)
-		gtk_button_set_relief(GTK_BUTTON(yes), GTK_RELIEF_NONE);
-
-	button = gtk_hbox_new(FALSE, 5);
-	gtk_container_add(GTK_CONTAINER(yes), button);
-	gtk_widget_show(button);
-
-	pm = gdk_pixmap_create_from_xpm_d(window->window, &mask, NULL, ok_xpm);
-	image = gtk_pixmap_new(pm, mask);
-	gtk_box_pack_start(GTK_BOX(button), image, FALSE, FALSE, 2);
-	gtk_widget_show(image);
-
-	label = gtk_label_new(_("Accept"));
-	gtk_box_pack_end(GTK_BOX(button), label, FALSE, FALSE, 2);
-	gtk_widget_show(label);
 
-	no = gtk_button_new();
+	no = picture_button(window, _("Cancel"), cancel_xpm);
 	gtk_box_pack_end(GTK_BOX(hbox), no, FALSE, FALSE, 5);
-	gtk_widget_show(no);
-	if (display_options & OPT_DISP_COOL_LOOK)
-		gtk_button_set_relief(GTK_BUTTON(no), GTK_RELIEF_NONE);
-
-	button = gtk_hbox_new(FALSE, 5);
-	gtk_container_add(GTK_CONTAINER(no), button);
-	gtk_widget_show(button);
-
-	pm = gdk_pixmap_create_from_xpm_d(window->window, &mask, NULL, cancel_xpm);
-	image = gtk_pixmap_new(pm, mask);
-	gtk_box_pack_start(GTK_BOX(button), image, FALSE, FALSE, 2);
-	gtk_widget_show(image);
-
-	label = gtk_label_new(_("Cancel"));
-	gtk_box_pack_end(GTK_BOX(button), label, FALSE, FALSE, 2);
-	gtk_widget_show(label);
 
 	gtk_signal_connect(GTK_OBJECT(yes), "clicked",
 			   GTK_SIGNAL_FUNC(accept_directim), window);
@@ -716,8 +680,6 @@
 		} else if (rendtype & AIM_CAPS_IMIMAGE) {
 			/* DirectIM stuff */
 			struct aim_directim_priv *priv, *priv2;
-			struct aim_conn_t *newconn;
-			int watcher;
 
 			userinfo = va_arg(ap, struct aim_userinfo_s *);
 			priv = va_arg(ap, struct aim_directim_priv *);
--- a/src/ticker.c	Fri Aug 04 04:08:31 2000 +0000
+++ b/src/ticker.c	Fri Aug 04 04:45:51 2000 +0000
@@ -24,6 +24,7 @@
 #include <gtk/gtk.h>
 #include "gtkticker.h"
 #include <string.h>
+#include <stdlib.h>
 
 GtkWidget *tickerwindow = NULL;
 GtkWidget *ticker;
@@ -49,6 +50,7 @@
 void BuddyTickerSignOff( void );
 GList * BuddyTickerFindUser( char *name );
 int BuddyTickerMessageRemove( gpointer data );
+extern void pressed_ticker(char *);
 
 // this pref is startup only, so make a shadow here of settings at startup
 // code uses this variable, not display_prefs
@@ -106,12 +108,13 @@
 	TickerData *p = (TickerData *) callback_data;
 
 	pressed_ticker( p->buddy );
+
+	return TRUE;
 }
 
 void
 BuddyTickerAddUser( char *name, GdkPixmap *pm, GdkBitmap *bm )
 {
-	GtkWidget *hbox, *label, *pmap;
 	TickerData *p;
 	GList *q;
 
@@ -217,7 +220,7 @@
 BuddyTickerMessageRemove( gpointer data )
 {
 	if ( userclose == TRUE )
-		return;
+		return FALSE;
 	gtk_ticker_remove( GTK_TICKER( ticker ), msgw );
 	return FALSE;
 }