mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
* src/bin/gnucash-bin.c: update splash screen while loading modules.
Granted, this has no effect because the splash screen isn't /UP/ when we're loading the modules. But still, once we initialize the gnome application earlier this will let us update the splash screen. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@12925 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
@@ -1,3 +1,11 @@
|
|||||||
|
2006-01-21 Derek Atkins <derek@ihtfp.com>
|
||||||
|
|
||||||
|
* src/bin/gnucash-bin.c: update splash screen while loading modules.
|
||||||
|
Granted, this has no effect because the splash screen isn't
|
||||||
|
/UP/ when we're loading the modules. But still, once we
|
||||||
|
initialize the gnome application earlier this will let us
|
||||||
|
update the splash screen.
|
||||||
|
|
||||||
2006-01-21 David Hampton <hampton@employees.org>
|
2006-01-21 David Hampton <hampton@employees.org>
|
||||||
|
|
||||||
* src/gnome-utils/*.glade: Move glade files to a new subdirectory.
|
* src/gnome-utils/*.glade: Move glade files to a new subdirectory.
|
||||||
|
|||||||
@@ -41,6 +41,7 @@
|
|||||||
#include "top-level.h"
|
#include "top-level.h"
|
||||||
#include "gfec.h"
|
#include "gfec.h"
|
||||||
#include "gnc-main.h"
|
#include "gnc-main.h"
|
||||||
|
#include "gnc-splash.h"
|
||||||
|
|
||||||
static int gnucash_show_version;
|
static int gnucash_show_version;
|
||||||
/* GNUCASH_SVN is defined whenever we're building from an SVN tree */
|
/* GNUCASH_SVN is defined whenever we're building from an SVN tree */
|
||||||
@@ -122,6 +123,13 @@ try_load_config_array(const gchar *fns[])
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
update_message(const gchar *msg)
|
||||||
|
{
|
||||||
|
gnc_update_splash_screen(msg);
|
||||||
|
g_message(msg);
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
load_system_config(void)
|
load_system_config(void)
|
||||||
{
|
{
|
||||||
@@ -130,7 +138,7 @@ load_system_config(void)
|
|||||||
|
|
||||||
if (is_system_config_loaded) return;
|
if (is_system_config_loaded) return;
|
||||||
|
|
||||||
g_message("loading system configuration");
|
update_message("loading system configuration");
|
||||||
system_config = g_build_filename(config_path, "config", NULL);
|
system_config = g_build_filename(config_path, "config", NULL);
|
||||||
is_system_config_loaded = try_load(system_config);
|
is_system_config_loaded = try_load(system_config);
|
||||||
g_free(system_config);
|
g_free(system_config);
|
||||||
@@ -156,13 +164,13 @@ load_user_config(void)
|
|||||||
return;
|
return;
|
||||||
else is_user_config_loaded = TRUE;
|
else is_user_config_loaded = TRUE;
|
||||||
|
|
||||||
g_message("loading user configuration");
|
update_message("loading user configuration");
|
||||||
try_load_config_array(user_config_files);
|
try_load_config_array(user_config_files);
|
||||||
g_message("loading auto configuration");
|
update_message("loading auto configuration");
|
||||||
try_load_config_array(auto_config_files);
|
try_load_config_array(auto_config_files);
|
||||||
g_message("loading saved reports");
|
update_message("loading saved reports");
|
||||||
try_load_config_array(saved_report_files);
|
try_load_config_array(saved_report_files);
|
||||||
g_message("loading stylesheets");
|
update_message("loading stylesheets");
|
||||||
try_load_config_array(stylesheet_files);
|
try_load_config_array(stylesheet_files);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -261,29 +269,47 @@ static void
|
|||||||
inner_main (void *closure, int argc, char **argv)
|
inner_main (void *closure, int argc, char **argv)
|
||||||
{
|
{
|
||||||
SCM main_mod;
|
SCM main_mod;
|
||||||
|
int i, len;
|
||||||
|
struct {
|
||||||
|
gchar * name;
|
||||||
|
int version;
|
||||||
|
gboolean optional;
|
||||||
|
} modules[] = {
|
||||||
|
{ "gnucash/app-utils", 0, FALSE },
|
||||||
|
{ "gnucash/engine", 0, FALSE },
|
||||||
|
{ "gnucash/register/ledger-core", 0, FALSE },
|
||||||
|
{ "gnucash/register/register-core", 0, FALSE },
|
||||||
|
{ "gnucash/register/register-gnome", 0, FALSE },
|
||||||
|
{ "gnucash/import-export/binary-import", 0, FALSE },
|
||||||
|
{ "gnucash/import-export/qif-import", 0, FALSE },
|
||||||
|
{ "gnucash/import-export/ofx", 0, TRUE },
|
||||||
|
{ "gnucash/import-export/mt940", 0, TRUE },
|
||||||
|
{ "gnucash/import-export/log-replay", 0, TRUE },
|
||||||
|
{ "gnucash/import-export/hbci", 0, TRUE },
|
||||||
|
{ "gnucash/report/report-system", 0, FALSE },
|
||||||
|
{ "gnucash/report/stylesheets", 0, FALSE },
|
||||||
|
{ "gnucash/report/standard-reports", 0, FALSE },
|
||||||
|
{ "gnucash/report/utility-reports", 0, FALSE },
|
||||||
|
{ "gnucash/report/locale-specific/us", 0, FALSE },
|
||||||
|
{ "gnucash/report/report-gnome", 0, FALSE },
|
||||||
|
{ "gnucash/business-gnome", 0, TRUE }
|
||||||
|
};
|
||||||
|
|
||||||
main_mod = scm_c_resolve_module("gnucash main");
|
main_mod = scm_c_resolve_module("gnucash main");
|
||||||
scm_set_current_module(main_mod);
|
scm_set_current_module(main_mod);
|
||||||
|
|
||||||
|
/* Can't show splash screen here unless we init gnome first */
|
||||||
|
//gnc_show_splash_screen();
|
||||||
|
|
||||||
/* module initializations go here */
|
/* module initializations go here */
|
||||||
gnc_module_load("gnucash/app-utils", 0);
|
len = sizeof(modules) / sizeof(*modules);
|
||||||
gnc_module_load("gnucash/engine", 0);
|
for (i = 0; i < len; i++) {
|
||||||
gnc_module_load("gnucash/register/ledger-core", 0);
|
gnc_update_splash_screen(modules[i].name);
|
||||||
gnc_module_load("gnucash/register/register-core", 0);
|
if (modules[i].optional)
|
||||||
gnc_module_load("gnucash/register/register-gnome", 0);
|
gnc_module_load_optional(modules[i].name, modules[i].version);
|
||||||
gnc_module_load("gnucash/import-export/binary-import", 0);
|
else
|
||||||
gnc_module_load("gnucash/import-export/qif-import", 0);
|
gnc_module_load(modules[i].name, modules[i].version);
|
||||||
gnc_module_load_optional("gnucash/import-export/ofx", 0);
|
}
|
||||||
gnc_module_load_optional("gnucash/import-export/mt940", 0);
|
|
||||||
gnc_module_load_optional("gnucash/import-export/log-replay", 0);
|
|
||||||
gnc_module_load_optional("gnucash/import-export/hbci", 0);
|
|
||||||
gnc_module_load("gnucash/report/report-system", 0);
|
|
||||||
gnc_module_load("gnucash/report/stylesheets", 0);
|
|
||||||
gnc_module_load("gnucash/report/standard-reports", 0);
|
|
||||||
gnc_module_load("gnucash/report/utility-reports", 0);
|
|
||||||
gnc_module_load("gnucash/report/locale-specific/us", 0);
|
|
||||||
gnc_module_load("gnucash/report/report-gnome", 0);
|
|
||||||
gnc_module_load_optional("gnucash/business-gnome", 0);
|
|
||||||
|
|
||||||
load_system_config();
|
load_system_config();
|
||||||
load_user_config();
|
load_user_config();
|
||||||
|
|||||||
Reference in New Issue
Block a user