| 1010 | } |
| 1011 | |
| 1012 | void SongBuilder::SongScene::TargetControlUpdated(SongBuilder::ControlTarget* target, int targetIndex, bool wasManuallyPatched) |
| 1013 | { |
| 1014 | IUIControl* control = target->GetTarget(); |
| 1015 | if (control != nullptr) |
| 1016 | { |
| 1017 | if (!target->mHadTarget) |
| 1018 | { |
| 1019 | mValues[targetIndex]->mFloatValue = control->GetValue(); |
| 1020 | mValues[targetIndex]->mBoolValue = control->GetValue() > 0; |
| 1021 | mValues[targetIndex]->mIntValue = (int)control->GetValue(); |
| 1022 | |
| 1023 | mValues[targetIndex]->UpdateDropdownContents(target); |
| 1024 | } |
| 1025 | } |
| 1026 | else if (wasManuallyPatched) //user intentionally deleted connection |
| 1027 | { |
| 1028 | mValues[targetIndex]->CleanUp(); |
| 1029 | mValues.erase(mValues.begin() + targetIndex); |
| 1030 | } |
| 1031 | } |
| 1032 | |
| 1033 | void SongBuilder::SongScene::Draw(SongBuilder* owner, float x, float y, int sceneIndex) |
| 1034 | { |
no test coverage detected