Yattm - unified GTK instant-messaging client logo
   [Generated for version 0.2-17 - Mon Jan 6 19:01:23 GMT+1 2003]

Home - Main Page - Data Structures - File List - Data Fields - Globals

chat_window.h

Go to the documentation of this file.
00001 /*
00002  * Yattm 
00003  *
00004  * Copyright (C) 1999, Torrey Searle <tsearle@uci.edu>
00005  *
00006  * This program is free software; you can redistribute it and/or modify
00007  * it under the terms of the GNU General Public License as published by
00008  * the Free Software Foundation; either version 2 of the License, or
00009  * (at your option) any later version.
00010  *
00011  * This program is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014  * GNU General Public License for more details.
00015  *
00016  * You should have received a copy of the GNU General Public License
00017  * along with this program; if not, write to the Free Software
00018  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00019  *
00020  */
00021 
00022 /*
00023  * chat_window.h
00024  * header file for the conversation window
00025  *
00026  */
00027 
00028 #ifndef __CHAT_WINDOW_H__
00029 #define __CHAT_WINDOW_H__
00030 
00031 #include <gtk/gtk.h>
00032 #include <stdio.h>
00033 #include <time.h>
00034 
00035 #include "contact.h"
00036 #include "log_window.h"
00037 #include "service.h"
00038 
00039 typedef struct _chat_window
00040 {
00041     GtkWidget * window;
00042     GtkWidget * chat;
00043     GtkWidget * entry;
00044     GtkWidget *smiley_button;
00045     GtkWidget *smiley_window;
00046     GtkWidget *sound_button;
00047     GtkWidget *allow_button;
00048     GtkWidget *status_label;
00049 
00050     gboolean sound_enabled;
00051     gboolean send_enabled;
00052     gboolean first_enabled;
00053     gboolean receive_enabled;
00054 
00055     struct contact * contact;
00056     eb_account * perfered; /*for sanity reasons, try using the
00057                most recently used account first */
00058     eb_local_account * local_user;
00059     FILE * fp;
00060 
00061     time_t next_typing_send;
00062     GList * history;
00063     GList * hist_pos;
00064     gint this_msg_in_history;
00065 
00066     /* Set to FALSE on init, TRUE when away msg first sent,
00067     FALSE when user sends regular message */
00068     gint away_msg_sent;
00069 
00070     /*** MIZHI: log window pointer */
00071     log_window* lw;
00072 
00074     GtkWidget* notebook; /* when using tabbed chat, this is the same for all chat_window structs. */
00075     GtkWidget* notebook_child; /* this part is different for each person we're talking to */
00076     GtkWidget* talk_pixmap; /* depending on whether or not they're being talked to is what this is */
00077 } chat_window;
00078 
00079 /* Struct to hold info used by get_local_accounts to hold callback info */
00080 typedef struct _chat_window_account {
00081     chat_window *cw;
00082     gpointer data;
00083 } chat_window_account;
00084 
00085 chat_window * eb_chat_window_new( eb_local_account * local,
00086                   struct contact * remote );
00087 
00088 void eb_chat_window_display_remote_message( eb_local_account * account,
00089                         eb_account * remote,
00090                                             struct service * serv,
00091                         gchar * message);
00092 
00093 void eb_chat_window_display_status( eb_account * remote,
00094                     gchar * message );
00095 
00096 void eb_chat_window_display_contact( struct contact * remote_contact );
00097 void eb_chat_window_display_account( eb_account * remote_account );
00098 void eb_chat_window_display_error( eb_account * remote, gchar * message );
00099 void eb_log_status_changed(eb_account *ea, gchar *status );
00100 void eb_log_message( FILE *log_file, gchar buff[], gchar *message );
00101 void eb_chat_window_do_timestamp( struct contact * c, gboolean online );
00102 void eb_restore_last_conv(gchar *file_name, chat_window* cw);
00103 void send_message(GtkWidget *widget, gpointer d);
00104 
00105 #if defined(__MINGW32__) && defined(__IN_PLUGIN__)
00106 __declspec(dllimport) GList *outgoing_message_filters;
00107 __declspec(dllimport) GList *incoming_message_filters;
00108 #else
00109 extern GList *outgoing_message_filters;
00110 extern GList *incoming_message_filters;
00111 #endif
00112 
00113 #endif

Contact: Andy Maloney     [Documentation generated by doxygen]