From 9514af19f4699128541db1877a63df5443765a55 Mon Sep 17 00:00:00 2001 From: Tobias Doerffel Date: Mon, 30 Jun 2008 22:07:04 +0000 Subject: [PATCH] * send posted events after creating a new project - makes project not being marked as modified right after it's been created * create empty sample-track and automation-track in new projects git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@1253 0778d3d1-df1d-0410-868b-ea421aaaa00d --- ChangeLog | 5 +++++ src/core/song.cpp | 5 ++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 20dffd583..6c19e0c19 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,10 @@ 2008-06-30 Tobias Doerffel + * src/core/song.cpp: + - send posted events after creating a new project - makes project not + being marked as modified right after it's been created + - create empty sample-track and automation-track in new projects + * src/core/engine.cpp: clear whole project before deleting everything - fixes segfault when quitting with controllers added diff --git a/src/core/song.cpp b/src/core/song.cpp index 42f36d4d4..b58796c15 100644 --- a/src/core/song.cpp +++ b/src/core/song.cpp @@ -779,12 +779,13 @@ void song::createNewProject( void ) t = track::create( track::InstrumentTrack, this ); dynamic_cast< instrumentTrack * >( t )->loadInstrument( "tripleoscillator" ); -// track::create( track::SampleTrack, this ); t = track::create( track::InstrumentTrack, engine::getBBTrackContainer() ); dynamic_cast< instrumentTrack * >( t )->loadInstrument( "tripleoscillator" ); + track::create( track::SampleTrack, this ); track::create( track::BBTrack, this ); + track::create( track::AutomationTrack, this ); m_tempoModel.setInitValue( DefaultTempo ); m_timeSigModel.reset(); @@ -799,6 +800,8 @@ void song::createNewProject( void ) engine::getProjectJournal()->setJournalling( TRUE ); + QCoreApplication::sendPostedEvents(); + m_modified = FALSE; if( engine::getMainWindow() )