mirror of
https://github.com/cookiengineer/audacity
synced 2025-05-06 14:52:34 +02:00
Removed ZoomInfo::GetZoom() which I added in my previous commit
Just wasn't thinking.
This commit is contained in:
parent
1fa97a4b37
commit
fc2628de4d
@ -5682,15 +5682,12 @@ void AudacityProject::OnZoomThousandthSecond()
|
||||
|
||||
void AudacityProject::OnZoomPreset(double newZoom)
|
||||
{
|
||||
double currentZoom = mViewInfo.GetZoom();
|
||||
double zoomFactor = newZoom * mViewInfo.OffsetTimeByPixels(0.0, 1);
|
||||
|
||||
if (currentZoom != 0.0) {
|
||||
double ratio = newZoom/currentZoom;
|
||||
if (ratio > 1.0 )
|
||||
ZoomInByFactor(ratio);
|
||||
else if (ratio < 1.0)
|
||||
ZoomOutByFactor(ratio);
|
||||
}
|
||||
if (zoomFactor > 1.0 )
|
||||
ZoomInByFactor(zoomFactor);
|
||||
else if (zoomFactor < 1.0)
|
||||
ZoomOutByFactor(zoomFactor);
|
||||
}
|
||||
|
||||
void AudacityProject::OnZoomFit()
|
||||
|
@ -86,9 +86,6 @@ public:
|
||||
|
||||
// There is NO GetZoom()!
|
||||
// Use TimeToPosition and PositionToTime and OffsetTimeByPixels!
|
||||
// DB added GetZoom() - needed for zoom presets.
|
||||
|
||||
double GetZoom() const {return zoom; }
|
||||
|
||||
// Limits zoom to certain bounds
|
||||
void SetZoom(double pixelsPerSecond);
|
||||
|
Loading…
x
Reference in New Issue
Block a user