Use bool return type for ARDOUR_UI::unload_session to indicate success/failure.

git-svn-id: svn://localhost/ardour2/trunk@1860 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Tim Mayberry 2007-05-18 02:41:10 +00:00
parent dbb8f65d8d
commit 00fc7b1fa2
3 changed files with 9 additions and 20 deletions

View file

@ -162,13 +162,14 @@ ARDOUR_UI::connect_to_session (Session *s)
point_zero_one_second_connection = Glib::signal_timeout().connect (mem_fun(*this, &ARDOUR_UI::every_point_zero_one_seconds), 40);
}
int
bool
ARDOUR_UI::unload_session ()
{
if (session && session->dirty()) {
switch (ask_about_saving_session (_("close"))) {
case -1:
return 1;
// cancel
return false;
case 1:
session->save_state ("");
@ -212,7 +213,7 @@ ARDOUR_UI::unload_session ()
update_buffer_load ();
return 0;
return true;
}
int