mirror of
https://github.com/cookiengineer/audacity
synced 2025-11-23 09:20:16 +01:00
Auto-enable list of regularly shipped modules (except script-pipe)
This commit is contained in:
@@ -12,8 +12,18 @@
|
||||
|
||||
#include "Prefs.h"
|
||||
|
||||
#include <unordered_set>
|
||||
#include <wx/filename.h>
|
||||
|
||||
static const std::unordered_set<wxString> &autoEnabledModules()
|
||||
{
|
||||
// Add names to this list, of modules that are expected to ship
|
||||
// with Audacity and enable automatically.
|
||||
static std::unordered_set<wxString> modules{
|
||||
};
|
||||
return modules;
|
||||
}
|
||||
|
||||
// static function that tells us about a module.
|
||||
int ModuleSettings::GetModuleStatus(const FilePath &fname)
|
||||
{
|
||||
@@ -54,6 +64,11 @@ int ModuleSettings::GetModuleStatus(const FilePath &fname)
|
||||
gPrefs->DeleteEntry( DateTimePref );
|
||||
}
|
||||
|
||||
if (iStatus == kModuleNew) {
|
||||
if (autoEnabledModules().count(ShortName))
|
||||
iStatus = kModuleEnabled;
|
||||
}
|
||||
|
||||
return iStatus;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user