| 1332 | } |
| 1333 | |
| 1334 | void RealtimeEffectPanel::ShowPanel(SampleTrack* track, bool focus) |
| 1335 | { |
| 1336 | if(track == nullptr) |
| 1337 | { |
| 1338 | ResetTrack(); |
| 1339 | return; |
| 1340 | } |
| 1341 | |
| 1342 | wxWindowUpdateLocker freeze(this); |
| 1343 | |
| 1344 | SetTrack(track->SharedPointer<SampleTrack>()); |
| 1345 | |
| 1346 | auto &projectWindow = ProjectWindow::Get(mProject); |
| 1347 | const auto pContainerWindow = projectWindow.GetContainerWindow(); |
| 1348 | if (pContainerWindow->GetWindow1() != this) |
| 1349 | { |
| 1350 | //Restore previous effects window size |
| 1351 | pContainerWindow->SplitVertically( |
| 1352 | this, |
| 1353 | projectWindow.GetTrackListWindow(), |
| 1354 | this->GetSize().GetWidth()); |
| 1355 | } |
| 1356 | if(focus) |
| 1357 | SetFocus(); |
| 1358 | projectWindow.Layout(); |
| 1359 | } |
| 1360 | |
| 1361 | void RealtimeEffectPanel::HidePanel() |
| 1362 | { |
no test coverage detected