1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-05-02 16:49:41 +02:00

Bug1544: clipboard space usage in History updates after cut/copy...

This should be tested for Cut, Split Cut, Copy, and also for the same
commands in the Labeled Audio sub-menu of Edit.
This commit is contained in:
Paul Licameli 2016-11-08 22:40:19 -05:00
parent 3f8751d9a2
commit 53a5c930a4
2 changed files with 15 additions and 3 deletions

View File

@ -4109,6 +4109,9 @@ void AudacityProject::OnCut()
RedrawProject();
mViewInfo.selectedRegion.collapseToT0();
if (mHistoryWindow)
mHistoryWindow->UpdateDisplay();
}
@ -4151,6 +4154,9 @@ void AudacityProject::OnSplitCut()
PushState(_("Split-cut to the clipboard"), _("Split Cut"));
RedrawProject();
if (mHistoryWindow)
mHistoryWindow->UpdateDisplay();
}
@ -4195,6 +4201,9 @@ void AudacityProject::OnCopy()
//Make sure the menus/toolbar states get updated
mTrackPanel->Refresh(false);
if (mHistoryWindow)
mHistoryWindow->UpdateDisplay();
}
void AudacityProject::OnPaste()
@ -4212,7 +4221,7 @@ void AudacityProject::OnPaste()
double t1 = mViewInfo.selectedRegion.t1();
TrackListIterator iter(GetTracks());
TrackListIterator clipIter(msClipboard.get());
TrackListConstIterator clipIter(msClipboard.get());
Track *n = iter.First();
const Track *c = clipIter.First();
@ -4457,8 +4466,8 @@ bool AudacityProject::HandlePasteNothingSelected()
return false;
else
{
TrackListIterator iterClip(msClipboard.get());
Track* pClip = iterClip.First();
TrackListConstIterator iterClip(msClipboard.get());
auto pClip = iterClip.First();
if (!pClip)
return true; // nothing to paste

View File

@ -4861,6 +4861,9 @@ void AudacityProject::EditClipboardByLabel( EditDestFunction action )
msClipT0 = regions.front().start;
msClipT1 = regions.back().end;
if (mHistoryWindow)
mHistoryWindow->UpdateDisplay();
}