"reactivate_window()" is used only by stuff in the "gtk" directory, and

has an API that depends on GTK+.  "set_main_window_name()" is
UI-toolkit-independent.  Declare the former in a new "gtk/ui_util.h"
file, rather than in "ui_util.h"; this helps separate
UI-toolkit-independent stuff from UI-toolkit-dependent stuff.

svn path=/trunk/; revision=3181
This commit is contained in:
Guy Harris 2001-03-24 02:23:08 +00:00
parent 8ac0e6618a
commit 9b85728d1d
4 changed files with 42 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.34 2001/03/22 23:54:47 gram Exp $
# $Id: Makefile.am,v 1.35 2001/03/24 02:23:08 guy Exp $
#
# Ethereal - Network traffic analyzer
# By Gerald Combs <gerald@zing.org>
@ -89,7 +89,8 @@ libui_a_SOURCES = \
stream_prefs.h \
summary_dlg.c \
summary_dlg.h \
ui_util.c
ui_util.c \
ui_util.h
EXTRA_DIST = \
Makefile.nmake

View File

@ -1,7 +1,7 @@
/* ui_util.c
* UI utility routines
*
* $Id: ui_util.c,v 1.3 2000/01/03 06:59:25 guy Exp $
* $Id: ui_util.c,v 1.4 2001/03/24 02:23:08 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
@ -33,6 +33,7 @@
#include "gtkglobals.h"
#include "ui_util.h"
#include "../ui_util.h"
/* Set the name of the top-level window and its icon.
XXX - for some reason, KWM insists on making the icon name be just

36
gtk/ui_util.h Normal file
View File

@ -0,0 +1,36 @@
/* ui_util.h
* Definitions for UI utility routines
*
* $Id: ui_util.h,v 1.1 2001/03/24 02:23:08 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
* 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 __GTKGUIUI_UTIL_H__
#define __GTKGUIUI_UTIL_H__
/* Given a pointer to a GtkWidget for a top-level window, raise it and
de-iconify it. This routine is used if the user has done something to
ask that a window of a certain type be popped up when there can be only
one such window and such a window has already been popped up - we
pop up the existing one rather than creating a new one. */
void reactivate_window(GtkWidget *);
#endif /* __GTKGUIUI_UTIL_H__ */

View File

@ -1,7 +1,7 @@
/* ui_util.h
* Definitions for UI utility routines
*
* $Id: ui_util.h,v 1.8 2001/03/24 02:14:54 guy Exp $
* $Id: ui_util.h,v 1.9 2001/03/24 02:23:07 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
@ -33,13 +33,6 @@ extern "C" {
/* Set the name of the top-level window and its icon. */
void set_main_window_name(gchar *);
/* Given a pointer to a GtkWidget for a top-level window, raise it and
de-iconify it. This routine is used if the user has done something to
ask that a window of a certain type be popped up when there can be only
one such window and such a window has already been popped up - we
pop up the existing one rather than creating a new one. */
void reactivate_window(GtkWidget *);
#ifdef __cplusplus
}
#endif /* __cplusplus */