1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-10-19 09:01:15 +02:00

Remove AudacityProject::GetScreenEndTime

This commit is contained in:
Paul Licameli
2019-03-27 04:29:27 -04:00
parent ca5bb78abe
commit 69962f62d3
7 changed files with 24 additions and 22 deletions

View File

@@ -290,12 +290,13 @@ void OnGoSelStart(const CommandContext &context)
auto &project = context.project;
auto &viewInfo = project.GetViewInfo();
auto &selectedRegion = viewInfo.selectedRegion;
auto &trackPanel = *project.GetTrackPanel();
if (selectedRegion.isPoint())
return;
project.TP_ScrollWindow(
selectedRegion.t0() - ((project.GetScreenEndTime() - viewInfo.h) / 2));
selectedRegion.t0() - ((trackPanel.GetScreenEndTime() - viewInfo.h) / 2));
}
void OnGoSelEnd(const CommandContext &context)
@@ -303,12 +304,13 @@ void OnGoSelEnd(const CommandContext &context)
auto &project = context.project;
auto &viewInfo = project.GetViewInfo();
auto &selectedRegion = viewInfo.selectedRegion;
auto &trackPanel = *project.GetTrackPanel();
if (selectedRegion.isPoint())
return;
project.TP_ScrollWindow(
selectedRegion.t1() - ((project.GetScreenEndTime() - viewInfo.h) / 2));
selectedRegion.t1() - ((trackPanel.GetScreenEndTime() - viewInfo.h) / 2));
}
void OnHistory(const CommandContext &context)