2004-05-20 12:01:13 +00:00
|
|
|
/* about_dlg.c
|
|
|
|
*
|
2004-07-18 00:24:25 +00:00
|
|
|
* $Id$
|
2004-05-20 12:01:13 +00:00
|
|
|
*
|
|
|
|
* Ulf Lamping <ulf.lamping@web.de>
|
|
|
|
*
|
|
|
|
* Ethereal - Network traffic analyzer
|
|
|
|
* By Gerald Combs <gerald@ethereal.com>
|
|
|
|
* Copyright 2000 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.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifdef HAVE_CONFIG_H
|
|
|
|
# include "config.h"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <gtk/gtk.h>
|
|
|
|
|
|
|
|
#include <epan/filesystem.h>
|
2004-05-20 13:48:25 +00:00
|
|
|
#include <epan/plugins.h>
|
2004-05-21 08:44:45 +00:00
|
|
|
#include "about_dlg.h"
|
2005-08-20 12:09:48 +00:00
|
|
|
#include "gui_utils.h"
|
2004-05-20 12:01:13 +00:00
|
|
|
#include "dlg_utils.h"
|
|
|
|
#include "compat_macros.h"
|
2004-05-20 13:48:25 +00:00
|
|
|
#include "globals.h"
|
2004-05-22 07:32:11 +00:00
|
|
|
#if GTK_MAJOR_VERSION >= 2 || GTK_MINOR_VERSION >= 3
|
|
|
|
#include "text_page.h"
|
|
|
|
#endif
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-05-20 18:23:38 +00:00
|
|
|
#include "../image/eicon3d64.xpm"
|
2004-07-04 12:15:41 +00:00
|
|
|
#include "gtkglobals.h"
|
2005-08-16 06:45:17 +00:00
|
|
|
#include "version_info.h"
|
2005-08-20 14:02:00 +00:00
|
|
|
#include "main.h"
|
|
|
|
#include "plugins_dlg.h"
|
2004-05-20 18:23:38 +00:00
|
|
|
|
2004-05-20 12:01:13 +00:00
|
|
|
static void about_ethereal_destroy_cb(GtkWidget *, gpointer);
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Keep a static pointer to the current "About Ethereal" window, if any, so
|
|
|
|
* that if somebody tries to do "About Ethereal" while there's already an
|
|
|
|
* "About Ethereal" window up, we just pop up the existing one, rather than
|
|
|
|
* creating a new one.
|
|
|
|
*/
|
|
|
|
static GtkWidget *about_ethereal_w;
|
|
|
|
|
|
|
|
|
2004-07-04 20:49:38 +00:00
|
|
|
static void
|
2004-07-04 12:15:41 +00:00
|
|
|
about_ethereal(GtkWidget *parent, GtkWidget *main_vb, const char *title)
|
2004-05-20 12:01:13 +00:00
|
|
|
{
|
2004-07-04 12:15:41 +00:00
|
|
|
GtkWidget *msg_label, *icon;
|
|
|
|
#if GTK_MAJOR_VERSION >= 2
|
2004-05-20 12:01:13 +00:00
|
|
|
gchar *message;
|
2004-07-04 12:15:41 +00:00
|
|
|
#endif
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-07-04 12:15:41 +00:00
|
|
|
icon = xpm_to_widget_from_parent(parent, eicon3d64_xpm);
|
2004-05-20 18:23:38 +00:00
|
|
|
gtk_container_add(GTK_CONTAINER(main_vb), icon);
|
|
|
|
|
|
|
|
msg_label = gtk_label_new(title);
|
|
|
|
#if GTK_MAJOR_VERSION >= 2
|
|
|
|
message = g_strdup_printf("<span size=\"x-large\" weight=\"bold\">%s</span>", title);
|
|
|
|
gtk_label_set_markup(GTK_LABEL(msg_label), message);
|
|
|
|
g_free(message);
|
|
|
|
#endif
|
|
|
|
gtk_container_add(GTK_CONTAINER(main_vb), msg_label);
|
2004-07-04 12:15:41 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2004-07-06 19:16:04 +00:00
|
|
|
GtkWidget *
|
|
|
|
splash_new(char *message)
|
2004-07-04 12:15:41 +00:00
|
|
|
{
|
|
|
|
GtkWidget *win;
|
|
|
|
GtkWidget *main_lb;
|
|
|
|
|
|
|
|
GtkWidget *main_vb;
|
|
|
|
|
2004-07-07 05:36:10 +00:00
|
|
|
win = splash_window_new();
|
2004-07-04 12:15:41 +00:00
|
|
|
|
2004-07-07 07:01:37 +00:00
|
|
|
/* When calling about_ethereal(), we must realize the top-level
|
|
|
|
widget for the window, otherwise GTK will throw a warning
|
|
|
|
because we don't have a colormap associated with that window and
|
|
|
|
can't handle the pixmap. */
|
|
|
|
gtk_widget_realize(win);
|
|
|
|
|
2004-07-04 12:15:41 +00:00
|
|
|
main_vb = gtk_vbox_new(FALSE, 6);
|
2004-07-05 05:32:04 +00:00
|
|
|
gtk_container_border_width(GTK_CONTAINER(main_vb), 24);
|
2004-07-04 12:15:41 +00:00
|
|
|
gtk_container_add(GTK_CONTAINER(win), main_vb);
|
|
|
|
|
|
|
|
about_ethereal(win, main_vb, "Ethereal - Network Protocol Analyzer");
|
|
|
|
|
|
|
|
main_lb = gtk_label_new(message);
|
|
|
|
gtk_container_add(GTK_CONTAINER(main_vb), main_lb);
|
|
|
|
OBJECT_SET_DATA(win, "splash_label", main_lb);
|
|
|
|
|
|
|
|
gtk_widget_show_all(win);
|
|
|
|
|
|
|
|
splash_update(win, message);
|
|
|
|
|
|
|
|
return win;
|
|
|
|
}
|
|
|
|
|
2004-07-06 19:16:04 +00:00
|
|
|
void
|
|
|
|
splash_update(GtkWidget *win, char *message)
|
2004-07-04 12:15:41 +00:00
|
|
|
{
|
|
|
|
GtkWidget *main_lb;
|
|
|
|
|
2004-07-06 19:16:04 +00:00
|
|
|
if (win == NULL) return;
|
|
|
|
|
2004-07-04 12:15:41 +00:00
|
|
|
main_lb = OBJECT_GET_DATA(win, "splash_label");
|
|
|
|
gtk_label_set_text(GTK_LABEL(main_lb), message);
|
|
|
|
|
2004-07-07 07:01:37 +00:00
|
|
|
/* Process all pending GUI events before continuing, so that
|
|
|
|
the splash screen window gets updated. */
|
2004-07-04 12:15:41 +00:00
|
|
|
while (gtk_events_pending()) gtk_main_iteration();
|
|
|
|
}
|
|
|
|
|
2004-07-06 19:16:04 +00:00
|
|
|
guint
|
|
|
|
splash_destroy(GtkWidget *win)
|
2004-07-04 12:15:41 +00:00
|
|
|
{
|
2004-07-06 19:16:04 +00:00
|
|
|
if (win == NULL) return FALSE;
|
|
|
|
|
2004-07-04 12:15:41 +00:00
|
|
|
gtk_widget_destroy(win);
|
|
|
|
return FALSE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
static GtkWidget *
|
|
|
|
about_ethereal_page_new(void)
|
|
|
|
{
|
|
|
|
GtkWidget *main_vb, *msg_label /*, *icon*/;
|
|
|
|
gchar *message;
|
|
|
|
const char title[] = "Ethereal - Network Protocol Analyzer";
|
|
|
|
|
|
|
|
main_vb = gtk_vbox_new(FALSE, 6);
|
|
|
|
gtk_container_border_width(GTK_CONTAINER(main_vb), 12);
|
|
|
|
|
|
|
|
about_ethereal(top_level, main_vb, title);
|
2004-05-20 18:23:38 +00:00
|
|
|
|
|
|
|
/* Construct the message string */
|
|
|
|
message = g_strdup_printf(
|
2005-12-21 08:59:52 +00:00
|
|
|
"Version " VERSION "%s\n"
|
|
|
|
"\n"
|
|
|
|
"%s"
|
|
|
|
"\n"
|
|
|
|
"%s"
|
|
|
|
"\n"
|
|
|
|
"%s"
|
|
|
|
"\n"
|
|
|
|
"Ethereal is Open Source Software released under the GNU General Public License.\n"
|
|
|
|
"\n"
|
2005-01-03 19:58:04 +00:00
|
|
|
"Check the man page and http://www.ethereal.com for more information.",
|
2005-12-21 08:59:52 +00:00
|
|
|
svnversion, get_copyright_info(), comp_info_str->str,
|
|
|
|
runtime_info_str->str);
|
2004-05-20 12:01:13 +00:00
|
|
|
|
|
|
|
msg_label = gtk_label_new(message);
|
|
|
|
g_free(message);
|
|
|
|
gtk_label_set_justify(GTK_LABEL(msg_label), GTK_JUSTIFY_FILL);
|
2005-01-03 19:58:04 +00:00
|
|
|
#if GTK_MAJOR_VERSION >= 2
|
|
|
|
gtk_label_set_selectable(GTK_LABEL(msg_label), TRUE);
|
|
|
|
#endif
|
2004-05-20 18:23:38 +00:00
|
|
|
gtk_container_add(GTK_CONTAINER(main_vb), msg_label);
|
2004-05-20 12:01:13 +00:00
|
|
|
|
|
|
|
return main_vb;
|
|
|
|
}
|
|
|
|
|
2004-05-22 07:32:11 +00:00
|
|
|
#if GTK_MAJOR_VERSION >= 2 || GTK_MINOR_VERSION >= 3
|
2004-05-21 08:55:07 +00:00
|
|
|
static GtkWidget *
|
|
|
|
about_authors_page_new(void)
|
|
|
|
{
|
|
|
|
GtkWidget *page;
|
|
|
|
char *absolute_path;
|
|
|
|
|
2004-05-21 17:35:43 +00:00
|
|
|
absolute_path = get_datafile_path("AUTHORS-SHORT");
|
2004-05-21 08:55:07 +00:00
|
|
|
page = text_page_new(absolute_path);
|
|
|
|
|
|
|
|
return page;
|
|
|
|
}
|
2004-05-22 07:32:11 +00:00
|
|
|
#endif
|
2004-05-20 12:01:13 +00:00
|
|
|
|
|
|
|
static void
|
2004-05-20 18:23:38 +00:00
|
|
|
about_folders_row(GtkWidget *table, const char *label, const char *dir, const char *tip)
|
2004-05-20 12:01:13 +00:00
|
|
|
{
|
2004-05-20 18:23:38 +00:00
|
|
|
simple_list_append(table, 0, label, 1, dir, 2, tip, -1);
|
2004-05-20 12:01:13 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
static GtkWidget *
|
2004-05-20 18:23:38 +00:00
|
|
|
about_folders_page_new(void)
|
2004-05-20 12:01:13 +00:00
|
|
|
{
|
|
|
|
GtkWidget *table;
|
"gtk_entry_get_text()" returns a "const char *" - assign the result to
one.
"get_basename()" doesn't modify its argument, and its callers don't
modify the substring pointed to by the result, so make it take a "const
char *" as an argument and return a "const char *".
"find_last_pathname_separator()" doesn't modify its argument, so make it
a "const char *" - but some of its callers pass a non-"const" "char *"
and modify the result, so don't make its return value a "const char *".
And, as none of its callers are outside "filesystem.c", make it static.
In "about_folders_page_new()", have separate variables for pathnames
returned as "const char *" (which are cached by the routine that returns
them, so you can't modify them - and can't free them, so get rid of the
commented-out "g_free()" calls for them) and pathnames returned as "char
*" (which are allocated anew for each call, and can be modified, but
have to be freed).
Clean up white space.
svn path=/trunk/; revision=12881
2004-12-31 00:26:36 +00:00
|
|
|
const char *constpath;
|
|
|
|
char *path;
|
2005-08-05 20:59:08 +00:00
|
|
|
const gchar *titles[] = { "Name", "Folder", "Typical Files"};
|
2004-05-20 18:23:38 +00:00
|
|
|
GtkWidget *scrolledwindow;
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-05-20 18:23:38 +00:00
|
|
|
scrolledwindow = scrolled_window_new(NULL, NULL);
|
|
|
|
#if GTK_MAJOR_VERSION >= 2
|
|
|
|
gtk_scrolled_window_set_shadow_type(GTK_SCROLLED_WINDOW(scrolledwindow),
|
|
|
|
GTK_SHADOW_IN);
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/* Container for our data */
|
|
|
|
table = simple_list_new(3, titles);
|
2004-05-20 13:48:25 +00:00
|
|
|
|
|
|
|
/* "file open" */
|
2004-06-01 17:33:37 +00:00
|
|
|
about_folders_row(table, "\"File\" dialogs", get_last_open_dir(),
|
2004-05-20 13:48:25 +00:00
|
|
|
"capture files");
|
|
|
|
|
|
|
|
/* temp */
|
|
|
|
path = get_tempfile_path("");
|
2004-05-20 18:23:38 +00:00
|
|
|
about_folders_row(table, "Temp", path,
|
2004-05-20 13:48:25 +00:00
|
|
|
"untitled capture files");
|
|
|
|
g_free((void *) path);
|
|
|
|
|
|
|
|
/* pers conf */
|
2004-05-20 12:01:13 +00:00
|
|
|
path = get_persconffile_path("", FALSE);
|
2004-05-20 18:23:38 +00:00
|
|
|
about_folders_row(table, "Personal configuration", path,
|
2004-05-20 13:48:25 +00:00
|
|
|
"\"dfilters\", \"preferences\", \"ethers\", ...");
|
2004-05-20 12:01:13 +00:00
|
|
|
g_free((void *) path);
|
|
|
|
|
2004-05-20 13:48:25 +00:00
|
|
|
/* global conf */
|
"gtk_entry_get_text()" returns a "const char *" - assign the result to
one.
"get_basename()" doesn't modify its argument, and its callers don't
modify the substring pointed to by the result, so make it take a "const
char *" as an argument and return a "const char *".
"find_last_pathname_separator()" doesn't modify its argument, so make it
a "const char *" - but some of its callers pass a non-"const" "char *"
and modify the result, so don't make its return value a "const char *".
And, as none of its callers are outside "filesystem.c", make it static.
In "about_folders_page_new()", have separate variables for pathnames
returned as "const char *" (which are cached by the routine that returns
them, so you can't modify them - and can't free them, so get rid of the
commented-out "g_free()" calls for them) and pathnames returned as "char
*" (which are allocated anew for each call, and can be modified, but
have to be freed).
Clean up white space.
svn path=/trunk/; revision=12881
2004-12-31 00:26:36 +00:00
|
|
|
constpath = get_datafile_dir();
|
|
|
|
about_folders_row(table, "Global configuration", constpath,
|
2004-05-20 13:48:25 +00:00
|
|
|
"\"dfilters\", \"preferences\", \"manuf\", ...");
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-05-20 13:48:25 +00:00
|
|
|
/* system */
|
"gtk_entry_get_text()" returns a "const char *" - assign the result to
one.
"get_basename()" doesn't modify its argument, and its callers don't
modify the substring pointed to by the result, so make it take a "const
char *" as an argument and return a "const char *".
"find_last_pathname_separator()" doesn't modify its argument, so make it
a "const char *" - but some of its callers pass a non-"const" "char *"
and modify the result, so don't make its return value a "const char *".
And, as none of its callers are outside "filesystem.c", make it static.
In "about_folders_page_new()", have separate variables for pathnames
returned as "const char *" (which are cached by the routine that returns
them, so you can't modify them - and can't free them, so get rid of the
commented-out "g_free()" calls for them) and pathnames returned as "char
*" (which are allocated anew for each call, and can be modified, but
have to be freed).
Clean up white space.
svn path=/trunk/; revision=12881
2004-12-31 00:26:36 +00:00
|
|
|
constpath = get_systemfile_dir();
|
|
|
|
about_folders_row(table, "System", constpath,
|
2004-05-20 13:48:25 +00:00
|
|
|
"\"ethers\", \"ipxnets\"");
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-05-20 13:48:25 +00:00
|
|
|
/* program */
|
Add a routine to attempt to get the absolute pathname of the executable
file, strip off the last component to get the pathname of the directory
containing the executable file, and save it for future use. On Windows,
you can get that from the OS, but, on UN*X, you have to look at argv[0]
and derive the absolute path from that (argv[0] is not guaranteed to be
an absolute path, or even a path at all). (In addition, if you're
running from the build directory, you might have to strip off a ".libs/"
added to argv[0] as an artifact of the libtoolizing script.)
Use that in the About dialog, and use it to construct the path of
dumpcap.
Don't put quotes into the path of dumpcap; you don't have to quote
strings with spaces in them when handing them to execvp and, in fact,
you *mustn't* quote them, as the quotes will be treated as part of the
pathname.
svn path=/trunk/; revision=17267
2006-02-12 03:15:29 +00:00
|
|
|
constpath = get_progfile_dir();
|
|
|
|
about_folders_row(table, "Program", constpath,
|
2004-05-20 13:48:25 +00:00
|
|
|
"program files");
|
|
|
|
|
2004-05-20 18:23:38 +00:00
|
|
|
#ifdef HAVE_PLUGINS
|
2004-05-20 13:48:25 +00:00
|
|
|
/* pers plugins */
|
|
|
|
path = get_plugins_pers_dir();
|
2004-05-20 18:23:38 +00:00
|
|
|
about_folders_row(table, "Personal Plugins", path,
|
2004-05-20 13:48:25 +00:00
|
|
|
"dissector plugins");
|
|
|
|
g_free((void *) path);
|
|
|
|
|
|
|
|
/* global plugins */
|
|
|
|
path = get_plugins_global_dir(PLUGIN_DIR);
|
2004-05-20 18:23:38 +00:00
|
|
|
about_folders_row(table, "Global Plugins", path,
|
2004-05-20 13:48:25 +00:00
|
|
|
"dissector plugins");
|
2004-05-20 12:01:13 +00:00
|
|
|
g_free((void *) path);
|
2004-05-20 18:23:38 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
gtk_container_add(GTK_CONTAINER(scrolledwindow), table);
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-05-20 18:23:38 +00:00
|
|
|
return scrolledwindow;
|
2004-05-20 12:01:13 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
about_ethereal_cb( GtkWidget *w _U_, gpointer data _U_ )
|
|
|
|
{
|
|
|
|
GtkWidget *main_vb, *main_nb, *bbox, *ok_btn;
|
|
|
|
|
2004-05-21 17:35:43 +00:00
|
|
|
GtkWidget *page_lb, *about_page, *folders_page, *plugins_page;
|
2004-05-22 07:32:11 +00:00
|
|
|
#if GTK_MAJOR_VERSION >= 2 || GTK_MINOR_VERSION >= 3
|
2004-05-21 17:35:43 +00:00
|
|
|
GtkWidget *authors_page;
|
2004-05-22 07:32:11 +00:00
|
|
|
#endif
|
2004-05-20 12:01:13 +00:00
|
|
|
|
|
|
|
if (about_ethereal_w != NULL) {
|
|
|
|
/* There's already an "About Ethereal" dialog box; reactivate it. */
|
|
|
|
reactivate_window(about_ethereal_w);
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
/*
|
|
|
|
* XXX - use GtkDialog? The GNOME 2.x GnomeAbout widget does.
|
|
|
|
* Should we use GtkDialog for simple_dialog() as well? Or
|
|
|
|
* is the GTK+ 2.x GtkDialog appropriate but the 1.2[.x] one
|
|
|
|
* not? (The GNOME 1.x GnomeAbout widget uses GnomeDialog.)
|
|
|
|
*/
|
|
|
|
about_ethereal_w = dlg_window_new("About Ethereal");
|
2004-05-23 17:37:36 +00:00
|
|
|
/* set the initial position (must be done, before show is called!) */
|
|
|
|
/* default position is not appropriate for the about dialog */
|
|
|
|
#if GTK_MAJOR_VERSION >= 2
|
|
|
|
gtk_window_set_position(GTK_WINDOW(about_ethereal_w), GTK_WIN_POS_CENTER_ON_PARENT);
|
|
|
|
#else
|
|
|
|
gtk_window_set_position(GTK_WINDOW(about_ethereal_w), GTK_WIN_POS_CENTER);
|
|
|
|
#endif
|
|
|
|
/* setting the size is dangerous here, as making it too short will
|
|
|
|
* clip content on GTK1, so simply use the natural size */
|
|
|
|
/*gtk_window_set_default_size(GTK_WINDOW(about_ethereal_w), 600, 400);*/
|
2004-05-20 18:23:38 +00:00
|
|
|
gtk_container_border_width(GTK_CONTAINER(about_ethereal_w), 6);
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-05-20 18:23:38 +00:00
|
|
|
main_vb = gtk_vbox_new(FALSE, 12);
|
|
|
|
gtk_container_border_width(GTK_CONTAINER(main_vb), 6);
|
2004-05-20 12:01:13 +00:00
|
|
|
gtk_container_add(GTK_CONTAINER(about_ethereal_w), main_vb);
|
|
|
|
|
|
|
|
main_nb = gtk_notebook_new();
|
2004-05-20 18:23:38 +00:00
|
|
|
gtk_box_pack_start(GTK_BOX(main_vb), main_nb, TRUE, TRUE, 0);
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-05-20 18:23:38 +00:00
|
|
|
about_page = about_ethereal_page_new();
|
|
|
|
page_lb = gtk_label_new("Ethereal");
|
|
|
|
gtk_notebook_append_page(GTK_NOTEBOOK(main_nb), about_page, page_lb);
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-05-22 07:32:11 +00:00
|
|
|
#if GTK_MAJOR_VERSION >= 2 || GTK_MINOR_VERSION >= 3
|
2004-05-21 08:55:07 +00:00
|
|
|
authors_page = about_authors_page_new();
|
|
|
|
page_lb = gtk_label_new("Authors");
|
|
|
|
gtk_notebook_append_page(GTK_NOTEBOOK(main_nb), authors_page, page_lb);
|
2004-05-22 07:32:11 +00:00
|
|
|
#endif
|
2004-05-21 08:55:07 +00:00
|
|
|
|
2004-05-20 18:23:38 +00:00
|
|
|
folders_page = about_folders_page_new();
|
|
|
|
page_lb = gtk_label_new("Folders");
|
|
|
|
gtk_notebook_append_page(GTK_NOTEBOOK(main_nb), folders_page, page_lb);
|
|
|
|
|
|
|
|
#ifdef HAVE_PLUGINS
|
|
|
|
plugins_page = about_plugins_page_new();
|
|
|
|
page_lb = gtk_label_new("Plugins");
|
|
|
|
gtk_notebook_append_page(GTK_NOTEBOOK(main_nb), plugins_page, page_lb);
|
|
|
|
#endif
|
2004-05-20 12:01:13 +00:00
|
|
|
|
|
|
|
/* Button row */
|
|
|
|
bbox = dlg_button_row_new(GTK_STOCK_OK, NULL);
|
2004-05-20 18:23:38 +00:00
|
|
|
gtk_box_pack_start(GTK_BOX(main_vb), bbox, FALSE, FALSE, 0);
|
2004-05-20 12:01:13 +00:00
|
|
|
|
|
|
|
ok_btn = OBJECT_GET_DATA(bbox, GTK_STOCK_OK);
|
2004-05-23 17:37:36 +00:00
|
|
|
window_set_cancel_button(about_ethereal_w, ok_btn, window_cancel_button_cb);
|
2004-05-20 12:01:13 +00:00
|
|
|
|
2004-05-23 17:37:36 +00:00
|
|
|
SIGNAL_CONNECT(about_ethereal_w, "delete_event", window_delete_event_cb, NULL);
|
|
|
|
SIGNAL_CONNECT(about_ethereal_w, "destroy", about_ethereal_destroy_cb, NULL);
|
2004-05-20 12:01:13 +00:00
|
|
|
|
|
|
|
gtk_widget_show_all(about_ethereal_w);
|
2004-05-23 17:37:36 +00:00
|
|
|
window_present(about_ethereal_w);
|
2004-05-20 12:01:13 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
about_ethereal_destroy_cb(GtkWidget *win _U_, gpointer user_data _U_)
|
|
|
|
{
|
|
|
|
/* Note that we no longer have an "About Ethereal" dialog box. */
|
|
|
|
about_ethereal_w = NULL;
|
|
|
|
}
|
|
|
|
|
2004-06-21 17:27:35 +00:00
|
|
|
|