Declare "text_page_new()" in a "gtk/text_page.h" header, rather than

embedding a declaration in "gtk/about_dlg.c".

Do the Authors page in the About dialog on UN*X as well as on Windows.

svn path=/trunk/; revision=10951
This commit is contained in:
Guy Harris 2004-05-22 04:25:57 +00:00
parent 88d2d10fb4
commit ade058df51
4 changed files with 35 additions and 11 deletions

View File

@ -1,7 +1,7 @@
# Makefile.am
# Automake file for the GTK interface routines for Ethereal
#
# $Id: Makefile.am,v 1.97 2004/05/21 08:44:45 guy Exp $
# $Id: Makefile.am,v 1.98 2004/05/22 04:25:57 guy Exp $
#
# Ethereal - Network traffic analyzer
# By Gerald Combs <gerald@ethereal.com>
@ -83,6 +83,7 @@ noinst_HEADERS = \
supported_protos_dlg.h \
tap_dfilter_dlg.h \
tap_menu.h \
text_page.h \
toolbar.h \
ui_util.h

View File

@ -1,6 +1,6 @@
/* about_dlg.c
*
* $Id: about_dlg.c,v 1.7 2004/05/21 17:35:43 ulfl Exp $
* $Id: about_dlg.c,v 1.8 2004/05/22 04:25:57 guy Exp $
*
* Ulf Lamping <ulf.lamping@web.de>
*
@ -106,9 +106,6 @@ about_ethereal_page_new(void)
return main_vb;
}
#ifdef WIN32
extern GtkWidget * text_page_new(const char *absolute_path);
static GtkWidget *
about_authors_page_new(void)
{
@ -120,7 +117,6 @@ about_authors_page_new(void)
return page;
}
#endif
static void
about_folders_row(GtkWidget *table, const char *label, const char *dir, const char *tip)
@ -208,9 +204,7 @@ about_ethereal_cb( GtkWidget *w _U_, gpointer data _U_ )
GtkWidget *main_vb, *main_nb, *bbox, *ok_btn;
GtkWidget *page_lb, *about_page, *folders_page, *plugins_page;
#ifdef WIN32
GtkWidget *authors_page;
#endif
if (about_ethereal_w != NULL) {
/* There's already an "About Ethereal" dialog box; reactivate it. */
@ -239,11 +233,9 @@ about_ethereal_cb( GtkWidget *w _U_, gpointer data _U_ )
page_lb = gtk_label_new("Ethereal");
gtk_notebook_append_page(GTK_NOTEBOOK(main_nb), about_page, page_lb);
#ifdef WIN32
authors_page = about_authors_page_new();
page_lb = gtk_label_new("Authors");
gtk_notebook_append_page(GTK_NOTEBOOK(main_nb), authors_page, page_lb);
#endif
folders_page = about_folders_page_new();
WIDGET_SET_SIZE(folders_page, 500, 200);

View File

@ -1,6 +1,6 @@
/* help_dlg.c
*
* $Id: help_dlg.c,v 1.50 2004/05/21 08:55:07 ulfl Exp $
* $Id: help_dlg.c,v 1.51 2004/05/22 04:25:57 guy Exp $
*
* Laurent Deniel <laurent.deniel@free.fr>
*
@ -34,6 +34,7 @@
#include "epan/filesystem.h"
#include "help_dlg.h"
#include "text_page.h"
#include "prefs.h"
#include "gtkglobals.h"
#include "ui_util.h"

30
gtk/text_page.h Normal file
View File

@ -0,0 +1,30 @@
/* text_page.h
* Declarations of routine to construct a simple text page from a file.
*
* $Id: text_page.h,v 1.1 2004/05/22 04:25:57 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
* Copyright 1998 Gerald Combs
*
* 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 __TEXT_PAGE_H__
#define __TEXT_PAGE_H__
extern GtkWidget * text_page_new(const char *absolute_path);
#endif /* __TEXT_PAGE_H__ */