fix compilation
[ardour.git] / gtk2_ardour / ardour_ui.cc
index 18cba7af9b1a73661bf8334660f2174f687337de..43fd6bf11f97033b02ba41b9848d04fa64a367df 100644 (file)
@@ -214,6 +214,10 @@ ARDOUR_UI::ARDOUR_UI (int *argcp, char **argvp[], const char* localedir)
 
        ui_config = new UIConfiguration();
 
+       ui_config->ParameterChanged.connect (sigc::mem_fun (*this, &ARDOUR_UI::parameter_changed));
+       boost::function<void (string)> pc (boost::bind (&ARDOUR_UI::parameter_changed, this, _1));
+       ui_config->map_parameters (pc);
+
        editor = 0;
        mixer = 0;
        meterbridge = 0;
@@ -718,6 +722,7 @@ ARDOUR_UI::starting ()
 {
        Application* app = Application::instance ();
        char *nsm_url;
+       bool brand_new_user = ArdourStartup::required ();
 
        app->ShouldQuit.connect (sigc::mem_fun (*this, &ARDOUR_UI::queue_finish));
        app->ShouldLoad.connect (sigc::mem_fun (*this, &ARDOUR_UI::idle_load));
@@ -778,17 +783,17 @@ ARDOUR_UI::starting ()
                }
 
        } else  {
-
-               if (ArdourStartup::required()) {
+               
+               if (brand_new_user) {
                        ArdourStartup s;
                        s.present ();
                        main().run();
                        s.hide ();
                        switch (s.response ()) {
-                       case Gtk::RESPONSE_REJECT:
-                               return -1;
-                       default:
+                       case Gtk::RESPONSE_OK:
                                break;
+                       default:
+                               return -1;
                        }
                }
 
@@ -804,7 +809,9 @@ ARDOUR_UI::starting ()
 
                /* go get a session */
 
-               if (get_session_parameters (false, ARDOUR_COMMAND_LINE::new_session, ARDOUR_COMMAND_LINE::load_template)) {
+               const bool new_session_required = (ARDOUR_COMMAND_LINE::new_session || brand_new_user);
+
+               if (get_session_parameters (false, new_session_required, ARDOUR_COMMAND_LINE::load_template)) {
                        return -1;
                }
        }