| 87 | } |
| 88 | |
| 89 | void PulseTrain::DrawModule() |
| 90 | { |
| 91 | if (Minimized() || IsVisible() == false) |
| 92 | return; |
| 93 | |
| 94 | ofSetColor(255, 255, 255, gModuleDrawAlpha); |
| 95 | |
| 96 | mIntervalSelector->Draw(); |
| 97 | mLengthSlider->Draw(); |
| 98 | mVelocityGrid->Draw(); |
| 99 | |
| 100 | for (int i = 0; i < kMaxSteps; ++i) |
| 101 | { |
| 102 | if (i < mLength) |
| 103 | { |
| 104 | ofVec2f pos = mVelocityGrid->GetCellPosition(i, 0) + mVelocityGrid->GetPosition(true); |
| 105 | pos.x += mVelocityGrid->GetWidth() / float(mLength) * .5f; |
| 106 | pos.y += mVelocityGrid->GetHeight() + 8; |
| 107 | mStepCables[i]->SetManualPosition(pos.x, pos.y); |
| 108 | mStepCables[i]->SetEnabled(true); |
| 109 | } |
| 110 | else |
| 111 | { |
| 112 | mStepCables[i]->SetEnabled(false); |
| 113 | } |
| 114 | } |
| 115 | } |
| 116 | |
| 117 | void PulseTrain::CheckboxUpdated(Checkbox* checkbox, double time) |
| 118 | { |
nothing calls this directly
no test coverage detected