| 1814 | } |
| 1815 | |
| 1816 | bool ModularSynth::ShouldDimModule(IDrawableModule* module) |
| 1817 | { |
| 1818 | if (TheSynth->GetGroupSelectedModules().empty() == false) |
| 1819 | { |
| 1820 | if (!VectorContains(module->GetModuleParent(), TheSynth->GetGroupSelectedModules())) |
| 1821 | return true; |
| 1822 | } |
| 1823 | |
| 1824 | if (PatchCable::sActivePatchCable && |
| 1825 | (PatchCable::sActivePatchCable->GetConnectionType() != kConnectionType_Modulator && PatchCable::sActivePatchCable->GetConnectionType() != kConnectionType_UIControl && PatchCable::sActivePatchCable->GetConnectionType() != kConnectionType_ValueSetter) && |
| 1826 | !PatchCable::sActivePatchCable->IsValidTarget(module)) |
| 1827 | { |
| 1828 | return true; |
| 1829 | } |
| 1830 | |
| 1831 | if (TheSynth->GetHeldSample() != nullptr && !module->CanDropSample()) |
| 1832 | return true; |
| 1833 | |
| 1834 | if (ScriptModule::sHasLoadedUntrustedScript && |
| 1835 | dynamic_cast<ScriptModule*>(module) == nullptr && |
| 1836 | dynamic_cast<ScriptWarningPopup*>(module) == nullptr) |
| 1837 | return true; |
| 1838 | |
| 1839 | return false; |
| 1840 | } |
| 1841 | |
| 1842 | void ModularSynth::RegisterPatchCable(PatchCable* cable) |
| 1843 | { |
no test coverage detected