MCPcopy Create free account
hub / github.com/BespokeSynth/BespokeSynth / GetPush2OverrideControls

Method GetPush2OverrideControls

Source/EffectChain.cpp:318–349  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

316}
317
318void EffectChain::GetPush2OverrideControls(std::vector<IUIControl*>& controls) const
319{
320 int effectIndex = -1;
321 if (mPush2DisplayEffect != nullptr)
322 {
323 for (int i = 0; i < (int)mEffects.size(); ++i)
324 {
325 if (mEffects[i] == mPush2DisplayEffect)
326 effectIndex = i;
327 }
328 }
329
330 if (effectIndex == -1)
331 {
332 controls.push_back(mVolumeSlider);
333 controls.push_back(mEffectSpawnList);
334 for (int i = 0; i < (int)mEffects.size(); ++i)
335 controls.push_back(mEffectControls[i].mPush2DisplayEffectButton);
336 if (mSpawnIndex != -1)
337 controls.push_back(mSpawnEffectButton);
338 }
339 else
340 {
341 controls.push_back(mEffectControls[effectIndex].mDryWetSlider);
342 controls.push_back(mPush2ExitEffectButton);
343 controls.push_back(mEffectControls[effectIndex].mMoveLeftButton);
344 controls.push_back(mEffectControls[effectIndex].mMoveRightButton);
345 controls.push_back(mEffectControls[effectIndex].mDeleteButton);
346 for (auto* control : mPush2DisplayEffect->GetUIControls())
347 controls.push_back(control);
348 }
349}
350
351void EffectChain::GetModuleDimensions(float& width, float& height)
352{

Callers

nothing calls this directly

Calls 2

sizeMethod · 0.80
GetUIControlsMethod · 0.80

Tested by

no test coverage detected