| 58 | } |
| 59 | |
| 60 | void CInstrumentEditorFDS::SelectInstrument(std::shared_ptr<CInstrument> pInst) |
| 61 | { |
| 62 | m_pInstrument = std::dynamic_pointer_cast<CInstrumentFDS>(pInst); |
| 63 | ASSERT(m_pInstrument); |
| 64 | |
| 65 | if (m_pWaveEditor) |
| 66 | m_pWaveEditor->SetInstrument(m_pInstrument); |
| 67 | |
| 68 | if (m_pModSequenceEditor) |
| 69 | m_pModSequenceEditor->SetInstrument(m_pInstrument); |
| 70 | |
| 71 | static_cast<CSpinButtonCtrl*>(GetDlgItem(IDC_MOD_RATE_SPIN))->SetPos(m_pInstrument->GetModulationSpeed()); |
| 72 | static_cast<CSpinButtonCtrl*>(GetDlgItem(IDC_MOD_DEPTH_SPIN))->SetPos(m_pInstrument->GetModulationDepth()); |
| 73 | static_cast<CSpinButtonCtrl*>(GetDlgItem(IDC_MOD_DELAY_SPIN))->SetPos(m_pInstrument->GetModulationDelay()); |
| 74 | |
| 75 | // CheckDlgButton(IDC_ENABLE_FM, m_pInstrument->GetModulationEnable() ? 1 : 0); |
| 76 | |
| 77 | EnableModControls(m_pInstrument->GetModulationEnable()); |
| 78 | } |
| 79 | |
| 80 | |
| 81 | BEGIN_MESSAGE_MAP(CInstrumentEditorFDS, CInstrumentEditPanel) |
nothing calls this directly
no test coverage detected