mirror of
https://github.com/cookiengineer/audacity
synced 2025-07-24 08:28:04 +02:00
Fix for bug #334
This commit is contained in:
parent
f83a79f198
commit
0e12ab6760
@ -3293,10 +3293,28 @@ void AudacityProject::UnlockAllBlocks()
|
||||
}
|
||||
}
|
||||
|
||||
class ProjectDisabler
|
||||
{
|
||||
public:
|
||||
ProjectDisabler(wxWindow *w)
|
||||
: mWindow(w)
|
||||
{
|
||||
mWindow->GetEventHandler()->SetEvtHandlerEnabled(false);
|
||||
}
|
||||
~ProjectDisabler()
|
||||
{
|
||||
mWindow->GetEventHandler()->SetEvtHandlerEnabled(true);
|
||||
}
|
||||
private:
|
||||
wxWindow *mWindow;
|
||||
};
|
||||
|
||||
bool AudacityProject::Save(bool overwrite /* = true */ ,
|
||||
bool fromSaveAs /* = false */,
|
||||
bool bWantSaveCompressed /*= false*/)
|
||||
{
|
||||
ProjectDisabler disabler(this);
|
||||
|
||||
if (bWantSaveCompressed)
|
||||
wxASSERT(fromSaveAs);
|
||||
else
|
||||
|
Loading…
x
Reference in New Issue
Block a user