mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-07 22:25:46 +01:00
[Summary] Fixed several issues which made session dirty when it's just loaded or created from scratch
This commit is contained in:
parent
b76231f0de
commit
c25e35f2d4
5 changed files with 34 additions and 18 deletions
|
|
@ -1260,6 +1260,8 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
|
|||
int immediately_post_engine ();
|
||||
void remove_empty_sounds ();
|
||||
|
||||
void session_loaded ();
|
||||
|
||||
void setup_midi_control ();
|
||||
int midi_read (MIDI::Port *);
|
||||
|
||||
|
|
|
|||
|
|
@ -430,7 +430,7 @@ Session::Session (AudioEngine &eng,
|
|||
|
||||
_is_new = false;
|
||||
|
||||
SessionLoaded();
|
||||
session_loaded ();
|
||||
BootMessage (_("Session loading complete"));
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -344,23 +344,31 @@ Session::post_engine_init ()
|
|||
ltc_tx_initialize();
|
||||
/* initial program change will be delivered later; see ::config_changed() */
|
||||
|
||||
_state_of_the_state = Clean;
|
||||
|
||||
|
||||
Port::set_connecting_blocked (false);
|
||||
|
||||
DirtyChanged (); /* EMIT SIGNAL */
|
||||
|
||||
if (_is_new) {
|
||||
save_state ("");
|
||||
} else if (state_was_pending) {
|
||||
save_state ("");
|
||||
remove_pending_capture_state ();
|
||||
state_was_pending = false;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void
|
||||
Session::session_loaded ()
|
||||
{
|
||||
SessionLoaded();
|
||||
|
||||
_state_of_the_state = Clean;
|
||||
|
||||
DirtyChanged (); /* EMIT SIGNAL */
|
||||
|
||||
if (_is_new) {
|
||||
save_state ("");
|
||||
} else if (state_was_pending) {
|
||||
save_state ("");
|
||||
remove_pending_capture_state ();
|
||||
state_was_pending = false;
|
||||
}
|
||||
}
|
||||
|
||||
string
|
||||
Session::raid_path () const
|
||||
{
|
||||
|
|
@ -2995,6 +3003,10 @@ Session::set_dirty ()
|
|||
if (_state_of_the_state & Loading) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (_state_of_the_state & Deletion) {
|
||||
return;
|
||||
}
|
||||
|
||||
bool was_dirty = dirty();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue