/* gmysql -- a graphical frontend to MySQL databases Copyright (C) 1998, 1999 Stephen R. Dodd This program is free software; you can redistribute it and/or modify it under the terms of version 2 of the GNU General Public License as published by the Free Software Foundation. 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 __TABLELIST_H__ #define __TABLELIST_H__ #include #include typedef struct _DBConn DBConn; struct _DBConn { gchar *host; gchar *user; gchar *pw; MYSQL mysql; }; typedef struct _TableList TableList; struct _TableList { GtkWidget *window; GtkWidget *status_bar; GtkWidget *menu_bar; GtkWidget *menu_popup; GtkWidget *table_list; GHashTable *conns; gint selected_row; }; TableList *table_list_new( void ); void table_list_show( TableList *table_list ); void table_list_connect( TableList *table_list, gchar *host, gchar *user, gchar *pw ); void table_list_createdb( TableList *table_list, gchar *host, gchar *db ); void table_list_refresh( TableList *table_list ); DBConn *db_conn_new( gchar *ghost, gchar *user, gchar *pw ); void db_conn_destroy( DBConn *db_conn ); void table_list_create_db( TableList *table_list, gchar *host, gchar *db ); #endif /* __TABLELIST_H__ */