uint32_t nphysin = (uint32_t) new_session_dialog->input_limit_count();
uint32_t nphysout = (uint32_t) new_session_dialog->output_limit_count();
- if (build_session (session_path,
+ if (!build_session (session_path,
session_name,
cchns,
mchns,
return 0;
}
-int
+bool
ARDOUR_UI::build_session (const string & path, const string & snap_name,
uint32_t control_channels,
uint32_t master_channels,
Session *new_session;
if (!check_audioengine()) {
- return -1;
+ return false;
}
session_loaded = false;
- if (!unload_session ()) return -1;
+ if (!unload_session ()) return false;
_session_is_new = true;
MessageDialog msg (string_compose(_("Could not create session in \"%1\""), path));
msg.run ();
- return -1;
+ return false;
}
connect_to_session (new_session);
session_loaded = true;
- return 0;
+ return true;
}
void
int load_session (const string & path, const string & snapshot, string* mix_template = 0);
bool session_loaded;
- int build_session (const string & path, const string & snapshot,
+ /// @return true if building the session was successful
+ bool build_session (const string & path, const string & snapshot,
uint32_t ctl_chns,
uint32_t master_chns,
ARDOUR::AutoConnectOption input_connect,