summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2013-10-27 20:48:48 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2013-10-27 20:48:48 -0400
commit5eaafaa3af5e2ab0cbcf4e4d947351fd133e381f (patch)
treec43b46e9d61231d46f02236115fa121014386b53
parent632f5d523169e1d41e6aad2bb7d850efc369bbe5 (diff)
further fixes for NSM-based startup
Most, move initialization of Audio/MIDI setup window before NSM initialization, to make sure it is available if/when needed
-rw-r--r--gtk2_ardour/ardour_ui.cc24
1 files changed, 11 insertions, 13 deletions
diff --git a/gtk2_ardour/ardour_ui.cc b/gtk2_ardour/ardour_ui.cc
index 5dbdc32961..127927e80a 100644
--- a/gtk2_ardour/ardour_ui.cc
+++ b/gtk2_ardour/ardour_ui.cc
@@ -718,7 +718,7 @@ int
ARDOUR_UI::starting ()
{
Application* app = Application::instance ();
- char *nsm_url;
+ const char *nsm_url;
bool brand_new_user = ArdourStartup::required ();
app->ShouldQuit.connect (sigc::mem_fun (*this, &ARDOUR_UI::queue_finish));
@@ -730,9 +730,17 @@ ARDOUR_UI::starting ()
app->ready ();
- nsm_url = getenv ("NSM_URL");
+ /* we need to create this early because it may need to set the
+ * audio backend end up.
+ */
+
+ try {
+ audio_midi_setup.get (true);
+ } catch (...) {
+ return -1;
+ }
- if (nsm_url) {
+ if ((nsm_url = g_getenv ("NSM_URL")) != 0) {
nsm = new NSM_Client;
if (!nsm->init (nsm_url)) {
nsm->announce (PROGRAM_NAME, ":dirty:", "ardour3");
@@ -809,16 +817,6 @@ ARDOUR_UI::starting ()
}
}
- /* we need to create this early because it may need to set the
- * audio backend end up.
- */
-
- try {
- audio_midi_setup.get (true);
- } catch (...) {
- return -1;
- }
-
/* go get a session */
const bool new_session_required = (ARDOUR_COMMAND_LINE::new_session || brand_new_user);