[beast: 13/28] BEAST: bstmain.cc: extract method main_splash_image
- From: Tim Janik <timj src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [beast: 13/28] BEAST: bstmain.cc: extract method main_splash_image
- Date: Tue, 29 Dec 2015 19:02:01 +0000 (UTC)
commit 8a7a4b6a59b53a54a0c364b3545be075158b3de8
Author: Tim Janik <timj gnu org>
Date: Tue Dec 1 23:34:52 2015 +0100
BEAST: bstmain.cc: extract method main_splash_image
Signed-off-by: Tim Janik <timj gnu org>
beast-gtk/bstmain.cc | 32 ++++++++++++++++++--------------
1 files changed, 18 insertions(+), 14 deletions(-)
---
diff --git a/beast-gtk/bstmain.cc b/beast-gtk/bstmain.cc
index bddd069..4ad56c8 100644
--- a/beast-gtk/bstmain.cc
+++ b/beast-gtk/bstmain.cc
@@ -60,6 +60,7 @@ server_registration (SfiProxy server,
}
}
+static void main_show_splash_image();
static void main_init_core_plugins();
static void main_init_ladspa();
static void main_sleep4gdb();
@@ -77,8 +78,6 @@ static void main_cleanup ();
int
main (int argc, char *argv[])
{
- GdkPixbufAnimation *anim;
- gchar *string;
GSource *source;
/* initialize i18n */
bindtextdomain (BST_GETTEXT_DOMAIN, bse_installpath (BSE_INSTALLPATH_LOCALEBASE).c_str());
@@ -154,18 +153,7 @@ main (int argc, char *argv[])
bst_splash_update_item (beast_splash, _("RC Files"));
bst_preferences_load_rc_files();
- /* show splash images */
- bst_splash_update_item (beast_splash, _("Splash Image"));
- string = g_strconcat (bse_installpath (BSE_INSTALLPATH_DATADIR_IMAGES).c_str(), G_DIR_SEPARATOR_S,
BST_SPLASH_IMAGE, NULL);
- anim = gdk_pixbuf_animation_new_from_file (string, NULL);
- g_free (string);
- bst_splash_update ();
- if (anim)
- {
- bst_splash_set_animation (beast_splash, anim);
- g_object_unref (anim);
- }
-
+ main_show_splash_image();
main_init_core_plugins();
main_init_ladspa();
main_sleep4gdb();
@@ -184,6 +172,22 @@ main (int argc, char *argv[])
}
static void
+main_show_splash_image()
+{
+ /* show splash images */
+ bst_splash_update_item (beast_splash, _("Splash Image"));
+ gchar *string = g_strconcat (bse_installpath (BSE_INSTALLPATH_DATADIR_IMAGES).c_str(), G_DIR_SEPARATOR_S,
BST_SPLASH_IMAGE, NULL);
+ GdkPixbufAnimation *anim = gdk_pixbuf_animation_new_from_file (string, NULL);
+ g_free (string);
+ bst_splash_update ();
+ if (anim)
+ {
+ bst_splash_set_animation (beast_splash, anim);
+ g_object_unref (anim);
+ }
+}
+
+static void
main_init_core_plugins()
{
bst_splash_update_item (beast_splash, _("BSE Core"));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]