summaryrefslogtreecommitdiff
path: root/gtk2_ardour
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2013-08-01 18:49:40 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2013-08-01 18:49:40 -0400
commitdf59a000b79f891f17ec8a05b390982dac67e5ff (patch)
tree79d0fd947618c2bf0192d10865ed477afc6da64b /gtk2_ardour
parent682ebad62bdc85df151ad0b81dc27cc9f3e71cec (diff)
start code reorganization needed to deal with backend choices. compiles, links and runs as far as the startup screen now
Diffstat (limited to 'gtk2_ardour')
-rw-r--r--gtk2_ardour/ardour_ui.cc14
1 files changed, 5 insertions, 9 deletions
diff --git a/gtk2_ardour/ardour_ui.cc b/gtk2_ardour/ardour_ui.cc
index dc9018fc62..12f3feafa1 100644
--- a/gtk2_ardour/ardour_ui.cc
+++ b/gtk2_ardour/ardour_ui.cc
@@ -395,30 +395,25 @@ ARDOUR_UI::create_engine ()
loading_message (_("Starting audio engine"));
- try {
- engine = ARDOUR::AudioEngine::create (ARDOUR_COMMAND_LINE::backend_client_name, ARDOUR_COMMAND_LINE::backend_session_uuid);
-
- } catch (...) {
-
- return -1;
- }
+ AudioEngine* engine = AudioEngine::instance();
engine->Stopped.connect (forever_connections, MISSING_INVALIDATOR, boost::bind (&ARDOUR_UI::engine_stopped, this), gui_context());
engine->Running.connect (forever_connections, MISSING_INVALIDATOR, boost::bind (&ARDOUR_UI::engine_running, this), gui_context());
engine->SampleRateChanged.connect (forever_connections, MISSING_INVALIDATOR, boost::bind (&ARDOUR_UI::update_sample_rate, this, _1), gui_context());
engine->Halted.connect_same_thread (forever_connections, boost::bind (&ARDOUR_UI::engine_halted, this, _1, false));
+ engine->BackendAvailable.connect_same_thread (forever_connections, boost::bind (&ARDOUR_UI::post_engine, this));
ARDOUR::Port::set_connecting_blocked (ARDOUR_COMMAND_LINE::no_connect_ports);
- post_engine ();
-
return 0;
}
void
ARDOUR_UI::post_engine ()
{
+ cerr << "Backend available!\n";
+
/* Things to be done once we create the AudioEngine
*/
@@ -689,6 +684,7 @@ ARDOUR_UI::startup ()
{
Application* app = Application::instance ();
char *nsm_url;
+
app->ShouldQuit.connect (sigc::mem_fun (*this, &ARDOUR_UI::queue_finish));
app->ShouldLoad.connect (sigc::mem_fun (*this, &ARDOUR_UI::idle_load));