Return value is a key for lookup in a config file */
| 1489 | |
| 1490 | /* Return value is a key for lookup in a config file */ |
| 1491 | RegistryPath PluginManager::SettingsPath( |
| 1492 | ConfigurationType type, const PluginID & ID) |
| 1493 | { |
| 1494 | bool shared = (type == ConfigurationType::Shared); |
| 1495 | |
| 1496 | // All the strings reported by PluginDescriptor and used in this function |
| 1497 | // persist in the plugin settings configuration file, so they should not |
| 1498 | // be changed across Audacity versions, or else compatibility of the |
| 1499 | // configuration files will break. |
| 1500 | |
| 1501 | if (auto iter = mRegisteredPlugins.find(ID); iter == mRegisteredPlugins.end()) |
| 1502 | return {}; |
| 1503 | else { |
| 1504 | const PluginDescriptor & plug = iter->second; |
| 1505 | |
| 1506 | wxString id = GetPluginTypeString(plug.GetPluginType()) + |
| 1507 | wxT("_") + |
| 1508 | plug.GetEffectFamily() + // is empty for non-Effects |
| 1509 | wxT("_") + |
| 1510 | plug.GetVendor() + |
| 1511 | wxT("_") + |
| 1512 | (shared ? wxString{} : plug.GetSymbol().Internal()); |
| 1513 | |
| 1514 | return SETROOT + |
| 1515 | ConvertID(id) + |
| 1516 | wxCONFIG_PATH_SEPARATOR + |
| 1517 | (shared ? wxT("shared") : wxT("private")) + |
| 1518 | wxCONFIG_PATH_SEPARATOR; |
| 1519 | } |
| 1520 | } |
| 1521 | |
| 1522 | /* Return value is a key for lookup in a config file */ |
| 1523 | RegistryPath PluginManager::Group( ConfigurationType type, |
nothing calls this directly
no test coverage detected