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

Method Resize

Source/EnvelopeEditor.cpp:512–528  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

510}
511
512void EnvelopeEditor::Resize(float w, float h)
513{
514 w = MAX(w, 250);
515 h = MAX(h, 150);
516 mEnvelopeControl.SetDimensions(ofVec2f(w - 10, h - 105));
517
518 for (int i = 0; i < (int)mStageControls.size(); ++i)
519 {
520 mStageControls[i].mTargetSlider->Move(0, h - mHeight);
521 mStageControls[i].mTimeSlider->Move(0, h - mHeight);
522 mStageControls[i].mCurveSlider->Move(0, h - mHeight);
523 mStageControls[i].mSustainCheckbox->Move(0, h - mHeight);
524 }
525
526 mWidth = w;
527 mHeight = h;
528}
529
530void EnvelopeEditor::OnClicked(float x, float y, bool right)
531{

Callers

nothing calls this directly

Calls 4

ofVec2fClass · 0.85
sizeMethod · 0.80
MoveMethod · 0.80
SetDimensionsMethod · 0.45

Tested by

no test coverage detected