diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2012-07-09 21:54:21 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2012-07-09 21:54:21 +0000 |
commit | 3dcbdc0fe624f92121e9931365be75921f301b8c (patch) | |
tree | 895645a2fbc7050c44e6932af72bd631995c4d77 /gtk2_ardour/ardour_ui.cc | |
parent | c300fa98affc58a97fec1c7a0797c2c6e37d03cb (diff) |
cleaner version of splash display changes
git-svn-id: svn://localhost/ardour2/branches/3.0@13004 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/ardour_ui.cc')
-rw-r--r-- | gtk2_ardour/ardour_ui.cc | 54 |
1 files changed, 7 insertions, 47 deletions
diff --git a/gtk2_ardour/ardour_ui.cc b/gtk2_ardour/ardour_ui.cc index 959101ac57..1b108100d9 100644 --- a/gtk2_ardour/ardour_ui.cc +++ b/gtk2_ardour/ardour_ui.cc @@ -794,6 +794,8 @@ If you still wish to quit, please use the\n\n\ */ save_ardour_state (); + loading_message (_("Please wait while Ardour cleans up...")); + if (_session) { // _session->set_deletion_in_progress (); _session->set_clean (); @@ -2401,11 +2403,11 @@ ARDOUR_UI::loading_message (const std::string& msg) return; } - show_splash (); - if (splash) { - splash->message (msg); - flush_pending (); + if (!splash) { + show_splash (); } + + splash->message (msg); } /** @param quit_on_cancel true if exit() should be called if the user clicks `cancel' in the new session dialog */ @@ -2830,34 +2832,9 @@ ARDOUR_UI::about_signal_response (int /*response*/) hide_about(); } -bool -ARDOUR_UI::wakeup_from_splash_sleep (void* arg) -{ - cerr << "idle after splash\n"; - ((ARDOUR_UI*)arg)->_wakeup_from_splash_sleep (); - return false; -} - -void -ARDOUR_UI::_wakeup_from_splash_sleep () -{ - splash_done_visible = true; - cerr << "Set sdv to " << splash_done_visible << endl; -} - -bool -ARDOUR_UI::splash_visible (GdkEventAny*) -{ - cerr << "Splash now mapped\n"; - g_idle_add ((gboolean (*)(void*))ARDOUR_UI::wakeup_from_splash_sleep, this); - return false; -} - void ARDOUR_UI::show_splash () { - cerr << "Show splash!\n"; - if (splash == 0) { try { splash = new Splash; @@ -2866,24 +2843,7 @@ ARDOUR_UI::show_splash () } } - bool was_mapped = splash->is_mapped (); - - if (!was_mapped) { - splash_expose = splash->signal_map_event().connect (sigc::mem_fun (this, &ARDOUR_UI::splash_visible), false); - splash_done_visible = false; - } - - splash->pop_front (); - splash->present (); - - if (!was_mapped) { - while (!splash_done_visible) { - cerr << "nested iteration. sdv = " << splash_done_visible << endl; - gtk_main_iteration (); - } - } - - cerr << "show splash done\n"; + splash->display (); } void |