ayttm-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Ayttm-commits] CVS: ayttm/src account_parser.y,1.1.1.1,1.2 account_scan


From: Andy Maloney <address@hidden>
Subject: [Ayttm-commits] CVS: ayttm/src account_parser.y,1.1.1.1,1.2 account_scanner.l,1.1.1.1,1.2 away_window.c,1.4,1.5 chat_room.h,1.1.1.1,1.2 chat_window.h,1.2,1.3 contact_actions.c,1.2,1.3 contact_parser.y,1.3,1.4 contact_scanner.l,1.1.1.1,1.2 dialog.c,1.4,1.5 gtk_eb_html.c,1.1.1.1,1.2 info_window.c,1.3,1.4 info_window.h,1.2,1.3 input_list.c,1.2,1.3 message_parse.h,1.1.1.1,1.2 nomodule.c,1.2,1.3 nomodule.h,1.1.1.1,1.2 status.h,1.2,1.3
Date: Tue, 07 Jan 2003 20:55:24 -0500

Update of /cvsroot/ayttm/ayttm/src
In directory subversions:/tmp/cvs-serv13855

Modified Files:
        account_parser.y account_scanner.l away_window.c chat_room.h 
        chat_window.h contact_actions.c contact_parser.y 
        contact_scanner.l dialog.c gtk_eb_html.c info_window.c 
        info_window.h input_list.c message_parse.h nomodule.c 
        nomodule.h status.h 
Log Message:
Yet more header cleanups
Some minor code cleanups


Index: account_parser.y
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/account_parser.y,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- account_parser.y    23 Dec 2002 22:05:29 -0000      1.1.1.1
+++ account_parser.y    8 Jan 2003 01:55:19 -0000       1.2
@@ -1,15 +1,11 @@
 %token ACCOUNT END_ACCOUNT
 
 %{
-       #include <gtk/gtk.h>
-       #include <stdio.h>
        #include <stdlib.h>
        #include <string.h>
 
        #include "globals.h"
-       #include "account.h"
        #include "value_pair.h"
-       #include "service.h"
        #include "util.h"
 
        extern void save_account_info(char *service, GList *pairs);

Index: account_scanner.l
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/account_scanner.l,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- account_scanner.l   23 Dec 2002 22:05:29 -0000      1.1.1.1
+++ account_scanner.l   8 Jan 2003 01:55:19 -0000       1.2
@@ -1,12 +1,11 @@
 A [^\n\t"<>/= ]
 
 %{
-       #include<string.h>
-       #include<gtk/gtk.h>
+       #include <string.h>
+
        #include "value_pair.h"
        #include "account.h"
        #include "account_parser.h"
-       #include<stdio.h>
 
        #define accountwrap() 1
        int Line = 1;

Index: away_window.c
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/away_window.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- away_window.c       2 Jan 2003 09:37:54 -0000       1.4
+++ away_window.c       8 Jan 2003 01:55:19 -0000       1.5
@@ -27,15 +27,16 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
-#include <gtk/gtk.h>
 #include <glib.h>
 #include <fcntl.h>
 #include <sys/stat.h>
 #include <sys/types.h>
+
 #include "away_window.h"
 #include "dialog.h"
 #include "gtk_globals.h"
 #include "service.h"
+
 #include "pixmaps/ok.xpm"
 #include "pixmaps/cancel.xpm"
 
@@ -43,14 +44,20 @@
 #define MIN(x, y)      ((x)<(y)?(x):(y))
 #endif
 
-static GtkWidget *awaybox = NULL;
-GtkWidget * away_window;
-GtkWidget * away_message;
-GtkWidget * title;
-GtkWidget * save_later;
-GList *away_messages;
+/* globals */
+GtkWidget *away_message = NULL;
 gint is_away = 0;
-gint away_open = 0;
+
+
+static GtkWidget *awaybox = NULL;
+static GtkWidget *away_window = NULL;
+
+static GtkWidget *title = NULL;
+static GtkWidget *save_later = NULL;
+static GList *away_messages = NULL;
+
+static gint away_open = 0;
+
 
 static void destroy_away()
 {

Index: chat_room.h
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/chat_room.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- chat_room.h 23 Dec 2002 22:05:30 -0000      1.1.1.1
+++ chat_room.h 8 Jan 2003 01:55:19 -0000       1.2
@@ -1,9 +1,29 @@
-#include <gtk/gtk.h>
-#include "account.h"
-#include "service.h"
+/*
+ * Yattm
+ *
+ * Copyright (C) 1999, Torrey Searle <address@hidden>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ *
+ */
 
 #ifndef __CHAT_ROOM_H__
 #define __CHAT_ROOM_H__
+
+#include "account.h"
+
 
 typedef struct _eb_chat_room_buddy
 {

Index: chat_window.h
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/chat_window.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- chat_window.h       3 Jan 2003 23:26:07 -0000       1.2
+++ chat_window.h       8 Jan 2003 01:55:19 -0000       1.3
@@ -28,13 +28,16 @@
 #ifndef __CHAT_WINDOW_H__
 #define __CHAT_WINDOW_H__
 
-#include <gtk/gtk.h>
 #include <stdio.h>
 #include <time.h>
 
-#include "contact.h"
 #include "log_window.h"
-#include "service.h"
+#include "account.h"
+
+/* forward declarations */
+struct contact;
+struct service;
+
 
 typedef struct _chat_window
 {

Index: contact_actions.c
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/contact_actions.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- contact_actions.c   2 Jan 2003 09:37:54 -0000       1.2
+++ contact_actions.c   8 Jan 2003 01:55:19 -0000       1.3
@@ -1,16 +1,35 @@
+/*
+ * Yattm
+ *
+ * Copyright (C) 1999, Torrey Searle <address@hidden>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ *
+ */
+
 #ifdef HAVE_CONFIG_H
 #  include <config.h>
 #endif
 
-#include <glib.h>
 #include <string.h>
-#include "account.h"
+
 #include "util.h"
-#include "plugin.h"
 #include "intl.h"
 #include "message_parse.h"
-#include "file_select.h"
 #include "log_window.h"
+
 
 static void send_file_callback(char *selected_filename, gpointer data)
 {

Index: contact_parser.y
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/contact_parser.y,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- contact_parser.y    5 Jan 2003 08:32:16 -0000       1.3
+++ contact_parser.y    8 Jan 2003 01:55:19 -0000       1.4
@@ -1,14 +1,10 @@
 %token ACCOUNT END_ACCOUNT GROUP END_GROUP CONTACT END_CONTACT
 %{
-       #include <gtk/gtk.h>
-       #include <stdio.h>
        #include <stdlib.h>
        #include <string.h>
 
        #include "globals.h"
-       #include "account.h"
        #include "value_pair.h"
-       #include "service.h"
        #include "util.h"
        
        extern int Line_contact;

Index: contact_scanner.l
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/contact_scanner.l,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- contact_scanner.l   23 Dec 2002 22:05:31 -0000      1.1.1.1
+++ contact_scanner.l   8 Jan 2003 01:55:19 -0000       1.2
@@ -1,13 +1,13 @@
 A [^\n\t"<>/= ]
 
 %{
-       #include<string.h>
-       #include<gtk/gtk.h>
+       #include <string.h>
+
        #include "value_pair.h"
        #include "account.h"
        #include "contact_parser.h"
-       #include<stdio.h>
 
+       
        #define contactwrap() 1
     int Line_contact = 1;
 %}

Index: dialog.c
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/dialog.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- dialog.c    6 Jan 2003 15:23:16 -0000       1.4
+++ dialog.c    8 Jan 2003 01:55:19 -0000       1.5
@@ -25,12 +25,13 @@
 
 #include "intl.h"
 #include <string.h>
-#include <gtk/gtk.h>
 #include <gdk/gdkprivate.h>
 #include <stdlib.h>
+
 #include "dialog.h"
 #include "util.h"
 #include "status.h"
+
 #include "pixmaps/yattm.xpm"
 #include "pixmaps/tb_yes.xpm"
 #include "pixmaps/tb_no.xpm"

Index: gtk_eb_html.c
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/gtk_eb_html.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- gtk_eb_html.c       23 Dec 2002 22:05:36 -0000      1.1.1.1
+++ gtk_eb_html.c       8 Jan 2003 01:55:19 -0000       1.2
@@ -24,26 +24,23 @@
 #endif
 
 #include "intl.h"
-#include <gtk/gtk.h>
 #include <string.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <ctype.h>
-#include "pixmaps/aol_icon.xpm"
-#include "pixmaps/free_icon.xpm"
-#include "pixmaps/dt_icon.xpm"
-#include "pixmaps/admin_icon.xpm"
-#include "pixmaps/no_such_smiley.xpm"
-#include "extgtktext.h"
-#include "browser.h"
-#include "globals.h"
-#include "smileys.h"
 
 #ifdef HAVE_LIBXFT
 #include <gdk/gdkprivate.h>
 #include <X11/Xft/Xft.h>
 #endif
 
+#include "extgtktext.h"
+#include "globals.h"
+#include "smileys.h"
+
+#include "pixmaps/aol_icon.xpm"
+#include "pixmaps/free_icon.xpm"
+#include "pixmaps/dt_icon.xpm"
+#include "pixmaps/admin_icon.xpm"
+#include "pixmaps/no_such_smiley.xpm"
+
 static GData * font_cache;
 static gboolean cache_init = FALSE;
 
@@ -55,7 +52,7 @@
 
 #define DEBUG
 
-int _adjust_font_metrics(int size)
+static int _adjust_font_metrics(int size)
 {
 #ifndef HAVE_LIBXFT
        size = font_size + 2 + (size*2);
@@ -74,7 +71,7 @@
        return size;
 }
 
-char * _unescape_string(char * input)
+static char * _unescape_string(char * input)
 {
        int i = 0;
        int j = 0;

Index: info_window.c
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/info_window.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- info_window.c       2 Jan 2003 09:37:54 -0000       1.3
+++ info_window.c       8 Jan 2003 01:55:19 -0000       1.4
@@ -30,18 +30,13 @@
 #endif
 
 #include "intl.h"
-#include <string.h>
-#include <time.h>
-#include <stdio.h>
 #include <stdlib.h>
-#include <gtk/gtk.h>
-#include <gdk/gdkkeysyms.h>
-#include <ctype.h>
-#include "util.h"
+
 #include "gtk_eb_html.h"
-#include "pixmaps/cancel.xpm"
 #include "info_window.h"
-#include "dialog.h"
+
+#include "pixmaps/cancel.xpm"
+
 
 static void iw_destroy_event(GtkWidget *widget, gpointer data)
 {
@@ -153,7 +148,7 @@
        
        if(remote_account->infowindow)
        {
-    gtk_eb_html_add(EXT_GTK_TEXT(remote_account->infowindow->info), 
text,ignore_bg,ignore_fg,ignore_font);
-  }
+               gtk_eb_html_add(EXT_GTK_TEXT(remote_account->infowindow->info), 
text,ignore_bg,ignore_fg,ignore_font);
+       }
 }
 

Index: info_window.h
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/info_window.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- info_window.h       3 Jan 2003 23:26:07 -0000       1.2
+++ info_window.h       8 Jan 2003 01:55:19 -0000       1.3
@@ -28,10 +28,6 @@
 #ifndef __INFO_WINDOW_H__
 #define __INFO_WINDOW_H__
 
-
-
-#include <gtk/gtk.h>
-#include <stdio.h>
 #include "account.h"
 
 

Index: input_list.c
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/input_list.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- input_list.c        4 Jan 2003 09:04:49 -0000       1.2
+++ input_list.c        8 Jan 2003 01:55:19 -0000       1.3
@@ -20,14 +20,12 @@
  */
 
 #include "intl.h"
-#include <gtk/gtk.h>
 #include <string.h>
-#include <stdlib.h>
+
 #include "globals.h"
-#include "debug.h"
-#include "dialog.h"
 #include "input_list.h"
 #include "value_pair.h"
+
 
 void eb_input_render(input_list * il, GtkWidget * box)
 {

Index: message_parse.h
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/message_parse.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- message_parse.h     23 Dec 2002 22:05:36 -0000      1.1.1.1
+++ message_parse.h     8 Jan 2003 01:55:19 -0000       1.2
@@ -24,13 +24,15 @@
  *
  */
 
-#ifndef __PARSE_MESSAGE__
-#define __PARSE_MESSAGE__
+#ifndef __MESSAGE_PARSE_H__
+#define __MESSAGE_PARSE_H__
 
-#include <gtk/gtk.h>
-#include "account.h"
 #include "contact.h"
-#include "service.h"
+
+
+/* forward declarations */
+struct service;
+
 
 #ifdef __cplusplus
 extern "C" {

Index: nomodule.c
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/nomodule.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- nomodule.c  2 Jan 2003 09:37:55 -0000       1.2
+++ nomodule.c  8 Jan 2003 01:55:19 -0000       1.3
@@ -29,16 +29,14 @@
 #endif
 
 #include "intl.h"
-#include <gtk/gtk.h>
-#include <assert.h>
 #include <stdlib.h>
 #include <string.h>
-#include <time.h>
+
 #if defined( _WIN32 ) && !defined(__MINGW32__)
 typedef unsigned long u_long;
 typedef unsigned long ulong;
 #endif
-#include "service.h"
+
 #include "chat_window.h"
 #include "away_window.h"
 #include "util.h"
@@ -46,11 +44,9 @@
 #include "gtk_globals.h"
 #include "dialog.h"
 #include "message_parse.h"
-#include "chat_room.h"
 #include "value_pair.h"
 #include "info_window.h"
 #include "gtk_eb_html.h"
-#include "input_list.h"
 
 /* Can never be online */
 /* #include "pixmaps/nomodule_online.xpm" */
@@ -62,12 +58,12 @@
 
 struct eb_nomodule_account_data {
        gint status;
-        gint logged_in_time;
+       gint logged_in_time;
        gint evil;
 };
 
 struct eb_nomodule_local_account_data {
-        char password[255];
+       char password[255];
        int input;
        int keep_alive;
        gint status;
@@ -80,22 +76,6 @@
 
 
 
-/* here is the list of locally stored buddies */
-
-
-eb_account * eb_nomodule_new_account( gchar * account );
-void eb_nomodule_add_user( eb_account * account );
-void eb_nomodule_login( eb_local_account * account );
-void eb_nomodule_logout( eb_local_account * account );
-
-
-/*********
- * the following variable is a hack, it if we are changing the selection
- * don't let the corresponding set_current_state get called again
- */
-
-
-
 /*   callbacks used by Yattm    */
 
 static gint pixmaps = 0;
@@ -171,22 +151,10 @@
 GList * eb_nomodule_write_local_config( eb_local_account * account )
 {
        GList * list = NULL;
-       value_pair * vp;
-       struct eb_nomodule_local_account_data * alad = 
account->protocol_local_account_data; 
-
-       vp = g_new0(value_pair, 1);
-
-       strcpy(vp->key, "SCREEN_NAME");
-       strcpy(vp->value, escape_string(account->handle) );
-
-       list = g_list_append( list, vp );
-
-       vp = g_new0(value_pair, 1);
-
-       strcpy(vp->key, "PASSWORD");
-       strcpy(vp->value, escape_string(alad->password) );
+       struct eb_nomodule_local_account_data * alad = 
account->protocol_local_account_data;
 
-       list = g_list_append(list, vp);
+       list = value_pair_add( list, "SCREEN_NAME", account->handle );
+       list = value_pair_add( list, "PASSWORD", alad->password );
 
        return list;
 }

Index: nomodule.h
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/nomodule.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -r1.1.1.1 -r1.2
--- nomodule.h  23 Dec 2002 22:05:36 -0000      1.1.1.1
+++ nomodule.h  8 Jan 2003 01:55:19 -0000       1.2
@@ -20,8 +20,10 @@
  */
 
 
-#ifndef _NOMODULE_H
-#define _NOMODULE_H
+#ifndef __NOMODULE_H__
+#define __NOMODULE_H__
+
+
 extern struct service_callbacks * eb_nomodule_query_callbacks();
 extern struct service nomodule_SERVICE_INFO;
 

Index: status.h
===================================================================
RCS file: /cvsroot/ayttm/ayttm/src/status.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- status.h    2 Jan 2003 11:16:44 -0000       1.2
+++ status.h    8 Jan 2003 01:55:19 -0000       1.3
@@ -23,11 +23,15 @@
  * status.h
  */
 
-#ifndef __STATUS__
-#define __STATUS__
+#ifndef __STATUS_H__
+#define __STATUS_H__
 
-#include <gtk/gtk.h>
 #include "account.h"
+
+
+/* forward declarations */
+struct contact;
+
 
 enum list_type
 {





reply via email to

[Prev in Thread] Current Thread [Next in Thread]