removed stuff which now lives in gui/gui.c, removed global variable

2001-04-27  Michael Natterer  <mitch@gimp.org>

	* app/app_procs.[ch]: removed stuff which now lives in gui/gui.c,
	removed global variable "we_are_exiting", made app_init() static.

	* app/appenv.h: removed "we_are_exiting".

	* app/colormaps.c: don't #include "app_procs.h"

	* app/file-open.[ch]
	* app/file-save.[ch]: removed the *_pre_init() functions and
	renamed the *_post_init() functions to *_menu_init().

	* app/gui/gui.c: added more GUI init and shutdown code from
	app_procs.c
This commit is contained in:
Michael Natterer 2001-04-27 15:31:50 +00:00 committed by Michael Natterer
parent bcfeb4ac7b
commit 3aec225624
14 changed files with 42 additions and 56 deletions

View File

@ -1,3 +1,19 @@
2001-04-27 Michael Natterer <mitch@gimp.org>
* app/app_procs.[ch]: removed stuff which now lives in gui/gui.c,
removed global variable "we_are_exiting", made app_init() static.
* app/appenv.h: removed "we_are_exiting".
* app/colormaps.c: don't #include "app_procs.h"
* app/file-open.[ch]
* app/file-save.[ch]: removed the *_pre_init() functions and
renamed the *_post_init() functions to *_menu_init().
* app/gui/gui.c: added more GUI init and shutdown code from
app_procs.c
2001-04-26 Michael Natterer <mitch@gimp.org>
* app/widgets/gimpcontainermenuimpl.c: only work around option

View File

@ -56,12 +56,7 @@
#include "gui/color-notebook.h"
#include "gui/color-select.h"
#include "gui/colormap-dialog.h"
#include "gui/brush-select.h"
#include "gui/gui.h"
#include "gui/gradient-select.h"
#include "gui/palette-editor.h"
#include "gui/pattern-select.h"
#include "gui/splash.h"
#include "gui/tips-dialog.h"
@ -71,9 +66,7 @@
#include "color_transfer.h"
#include "colormaps.h"
#include "context_manager.h"
#include "errorconsole.h"
#include "file-open.h"
#include "file-save.h"
#include "gdisplay.h"
#include "gdisplay_ops.h"
#include "gimpcontext.h"
@ -103,11 +96,11 @@
#include "libgimp/gimpintl.h"
static void app_init (void);
static void toast_old_temp_files (void);
static gboolean is_app_exit_finish_done = FALSE;
gboolean we_are_exiting = FALSE;
void
@ -147,7 +140,7 @@ app_init_update_status (const gchar *text1,
/* #define RESET_BAR() app_init_update_status("", "", 0) */
#define RESET_BAR()
void
static void
app_init (void)
{
const gchar *gtkrc;
@ -219,10 +212,6 @@ app_init (void)
splash_logo_load ();
}
RESET_BAR();
file_open_pre_init (); /* pre-initialize the file types */
file_save_pre_init ();
RESET_BAR();
xcf_init (); /* initialize the xcf file format routines */
@ -252,8 +241,6 @@ app_init (void)
module_db_init (); /* load any modules we need */
RESET_BAR();
file_open_post_init (); /* post-initialize the file types */
file_save_post_init ();
/* Add the swap file */
if (swap_path == NULL)
@ -307,7 +294,6 @@ app_exit_finish (void)
is_app_exit_finish_done = TRUE;
message_handler = CONSOLE;
we_are_exiting = TRUE;
if (! no_interface)
{
@ -319,10 +305,6 @@ app_exit_finish (void)
global_edit_free ();
named_buffers_free ();
swapping_free ();
brush_dialog_free ();
pattern_dialog_free ();
palette_dialog_free ();
gradient_dialog_free ();
context_manager_free ();
hue_saturation_free ();
curves_free ();
@ -330,7 +312,6 @@ app_exit_finish (void)
paint_funcs_free ();
plug_in_kill ();
procedural_db_free ();
error_console_free ();
tile_swap_exit ();
save_unitrc ();
gimp_parasiterc_save ();

View File

@ -23,7 +23,6 @@
void gimp_init (gint gimp_argc,
gchar **gimp_argv);
void app_init (void);
void app_init_update_status (const gchar *label1,
const gchar *label2,
gdouble percentage);

View File

@ -37,7 +37,6 @@ extern gboolean use_debug_handler;
extern gboolean console_messages;
extern gboolean restore_session;
extern gboolean double_speed;
extern gboolean we_are_exiting; /* this is used in session_get_window_info() */
extern MessageHandlerType message_handler;

View File

@ -22,7 +22,6 @@
#include "apptypes.h"
#include "app_procs.h"
#include "colormaps.h"
#include "gimprc.h"

View File

@ -138,12 +138,7 @@ extern GSList *display_list; /* from gdisplay.c */
/* public functions */
void
file_open_pre_init (void)
{
}
void
file_open_post_init (void)
file_open_menu_init (void)
{
GimpItemFactoryEntry entry;
PlugInProcDef *file_proc;

View File

@ -23,8 +23,7 @@
extern GSList *load_procs;
void file_open_pre_init (void);
void file_open_post_init (void);
void file_open_menu_init (void);
void file_open_callback (GtkWidget *widget,
gpointer data);

View File

@ -127,12 +127,7 @@ static gboolean set_filename = TRUE;
/* public functions */
void
file_save_pre_init (void)
{
}
void
file_save_post_init (void)
file_save_menu_init (void)
{
GimpItemFactoryEntry entry;
PlugInProcDef *file_proc;

View File

@ -23,8 +23,7 @@
extern GSList *save_procs;
void file_save_pre_init (void);
void file_save_post_init (void);
void file_save_menu_init (void);
void file_save_callback (GtkWidget *widget,
gpointer data);

View File

@ -138,12 +138,7 @@ extern GSList *display_list; /* from gdisplay.c */
/* public functions */
void
file_open_pre_init (void)
{
}
void
file_open_post_init (void)
file_open_menu_init (void)
{
GimpItemFactoryEntry entry;
PlugInProcDef *file_proc;

View File

@ -23,8 +23,7 @@
extern GSList *load_procs;
void file_open_pre_init (void);
void file_open_post_init (void);
void file_open_menu_init (void);
void file_open_callback (GtkWidget *widget,
gpointer data);

View File

@ -127,12 +127,7 @@ static gboolean set_filename = TRUE;
/* public functions */
void
file_save_pre_init (void)
{
}
void
file_save_post_init (void)
file_save_menu_init (void)
{
GimpItemFactoryEntry entry;
PlugInProcDef *file_proc;

View File

@ -23,8 +23,7 @@
extern GSList *save_procs;
void file_save_pre_init (void);
void file_save_post_init (void);
void file_save_menu_init (void);
void file_save_callback (GtkWidget *widget,
gpointer data);

View File

@ -30,19 +30,26 @@
#include "widgets/gimpdialogfactory.h"
#include "brush-select.h"
#include "devices.h"
#include "dialogs.h"
#include "docindex.h"
#include "errorconsole.h"
#include "gimprc.h"
#include "gradient-select.h"
#include "gui.h"
#include "gximage.h"
#include "image_render.h"
#include "lc_dialog.h"
#include "menus.h"
#include "palette-editor.h"
#include "pattern-select.h"
#include "session.h"
#include "toolbox.h"
#include "app_procs.h"
#include "file-open.h"
#include "file-save.h"
#include "libgimp/gimpintl.h"
@ -57,6 +64,9 @@ static void really_quit_callback (GtkWidget *button,
void
gui_init (void)
{
file_open_menu_init ();
file_save_menu_init ();
menus_reorder_plugins ();
gximage_init ();
@ -110,6 +120,11 @@ gui_shutdown (void)
{
session_save ();
device_status_free ();
brush_dialog_free ();
pattern_dialog_free ();
palette_dialog_free ();
gradient_dialog_free ();
}
void
@ -124,6 +139,7 @@ gui_exit (void)
/* handle this in the dialog factory: */
lc_dialog_free ();
document_index_free ();
error_console_free ();
tool_options_dialog_free ();
toolbox_free ();
}