Create ComponentInterface

It combines the old IdentInterface with the ParamsInterface, providing an identifier and parameters (if needed).
The main purpose of the change is to make the class hierarchy (as viewed via doxygen) much easier to follow.
This commit is contained in:
James Crook 2018-11-02 15:31:44 +00:00
parent c63dcbd3ca
commit 466e9c179e
161 changed files with 875 additions and 597 deletions

View File

@ -8,10 +8,10 @@ dist_doc_DATA = LICENSE.txt README.txt
dist_pkgdata_DATA = presets/EQDefaultCurves.xml
nobase_dist_pkgdata_DATA = \
include/audacity/ComponentInterface.h \
include/audacity/ConfigInterface.h \
include/audacity/EffectAutomationParameters.h \
include/audacity/EffectInterface.h \
include/audacity/IdentInterface.h \
include/audacity/ImporterInterface.h \
include/audacity/ModuleInterface.h \
include/audacity/PluginInterface.h \

View File

@ -526,10 +526,10 @@ bin_PROGRAMS = audacity$(EXEEXT)
dist_doc_DATA = LICENSE.txt README.txt
dist_pkgdata_DATA = presets/EQDefaultCurves.xml
nobase_dist_pkgdata_DATA = \
include/audacity/ComponentInterface.h \
include/audacity/ConfigInterface.h \
include/audacity/EffectAutomationParameters.h \
include/audacity/EffectInterface.h \
include/audacity/IdentInterface.h \
include/audacity/ImporterInterface.h \
include/audacity/ModuleInterface.h \
include/audacity/PluginInterface.h \

View File

@ -2,7 +2,7 @@
Audacity: A Digital Audio Editor
IdentInterface.h
ComponentInterface.h
Leland Lucius
@ -39,39 +39,39 @@
**********************************************************************/
#ifndef __AUDACITY_IDENTINTERFACE_H__
#define __AUDACITY_IDENTINTERFACE_H__
#ifndef __AUDACITY_COMPONENT_INTERFACE_H__
#define __AUDACITY_COMPONENT_INTERFACE_H__
#include "audacity/Types.h"
extern AUDACITY_DLL_API const wxString& GetCustomTranslation(const wxString& str1 );
/**************************************************************************//**
\brief IdentInterfaceSymbol pairs a persistent string identifier used internally
\brief ComponentInterfaceSymbol pairs a persistent string identifier used internally
with an optional, different string as msgid for lookup in a translation catalog.
\details If there is need to change a msgid in a later version of the
program, change the constructor call to supply a second argument but leave the
first the same, so that compatibility of older configuration files containing
that internal string is not broken.
********************************************************************************/
class IdentInterfaceSymbol
class ComponentInterfaceSymbol
{
public:
IdentInterfaceSymbol() = default;
ComponentInterfaceSymbol() = default;
// Allows implicit construction from a msgid re-used as an internal string
IdentInterfaceSymbol( const wxString &msgid )
ComponentInterfaceSymbol( const wxString &msgid )
: mInternal{ msgid }, mMsgid{ msgid }
{}
// Allows implicit construction from a msgid re-used as an internal string
IdentInterfaceSymbol( const wxChar *msgid )
ComponentInterfaceSymbol( const wxChar *msgid )
: mInternal{ msgid }, mMsgid{ msgid }
{}
// Two-argument version distinguishes internal from translatable string
// such as when the first squeezes spaces out
IdentInterfaceSymbol( const wxString &internal, const wxString &msgid )
ComponentInterfaceSymbol( const wxString &internal, const wxString &msgid )
: mInternal{ internal }
// Do not permit non-empty msgid with empty internal
, mMsgid{ internal.empty() ? wxString{} : msgid }
@ -85,11 +85,11 @@ public:
bool empty() const { return mInternal.empty(); }
friend inline bool operator == (
const IdentInterfaceSymbol &a, const IdentInterfaceSymbol &b )
const ComponentInterfaceSymbol &a, const ComponentInterfaceSymbol &b )
{ return a.mInternal == b.mInternal; }
friend inline bool operator != (
const IdentInterfaceSymbol &a, const IdentInterfaceSymbol &b )
const ComponentInterfaceSymbol &a, const ComponentInterfaceSymbol &b )
{ return !( a == b ); }
private:
@ -97,24 +97,29 @@ private:
wxString mMsgid;
};
class ShuttleParams;
/**************************************************************************//**
\brief IdentInterface provides name / vendor / version functions to identify
plugins. It is what makes a class a plug-in.
\brief ComponentInterface provides name / vendor / version functions to identify
plugins. It is what makes a class a plug-in. Additionally it provides an
optional parameter definitions function, for those components such as commands,
effects and (soon) preference pagess that define parameters.
********************************************************************************/
class AUDACITY_DLL_API IdentInterface /* not final */
class AUDACITY_DLL_API ComponentInterface /* not final */
{
public:
virtual ~IdentInterface() {};
virtual ~ComponentInterface() {};
// These should return an untranslated value
virtual wxString GetPath() = 0;
// The internal string persists in configuration files
// So config compatibility will break if it is changed across Audacity versions
virtual IdentInterfaceSymbol GetSymbol() = 0;
virtual ComponentInterfaceSymbol GetSymbol() = 0;
virtual IdentInterfaceSymbol GetVendor() = 0;
virtual ComponentInterfaceSymbol GetVendor() = 0;
virtual wxString GetVersion() = 0;
@ -124,6 +129,9 @@ public:
// non-virtual convenience function
const wxString& GetTranslatedName();
// Parameters, if defined. false means no defined parameters.
virtual bool DefineParams( ShuttleParams & WXUNUSED(S) ){ return false;};
};
#endif // __AUDACITY_IDENTINTERFACE_H__

View File

@ -50,7 +50,7 @@
#include <wx/intl.h>
#include <algorithm>
#include "IdentInterface.h"
#include "ComponentInterface.h"
/**
@ -164,7 +164,7 @@ public:
using ObsoleteMap = std::pair< wxString, size_t >;
bool ReadEnum(const wxString & key, int *pi,
const IdentInterfaceSymbol choices[], size_t nChoices,
const ComponentInterfaceSymbol choices[], size_t nChoices,
const ObsoleteMap obsoletes[] = nullptr,
size_t nObsoletes = 0) const
{
@ -174,7 +174,7 @@ public:
return false;
}
*pi = std::find( choices, choices + nChoices,
IdentInterfaceSymbol{ s, {} } ) - choices;
ComponentInterfaceSymbol{ s, {} } ) - choices;
if (*pi == (int)nChoices)
*pi = -1;
if (*pi < 0 && obsoletes) {
@ -189,7 +189,7 @@ public:
}
bool ReadEnum(const wxString & key, int *pi, int defVal,
const IdentInterfaceSymbol choices[], size_t nChoices,
const ComponentInterfaceSymbol choices[], size_t nChoices,
const ObsoleteMap obsoletes[] = nullptr,
size_t nObsoletes = 0) const
{
@ -201,7 +201,7 @@ public:
}
bool WriteEnum(const wxString & key, int value,
const IdentInterfaceSymbol choices[], size_t nChoices)
const ComponentInterfaceSymbol choices[], size_t nChoices)
{
if (value < 0 || value >= (int)nChoices)
{
@ -248,7 +248,7 @@ public:
}
bool ReadAndVerify(const wxString & key, int *val, int defVal,
const IdentInterfaceSymbol choices[], size_t nChoices,
const ComponentInterfaceSymbol choices[], size_t nChoices,
const ObsoleteMap obsoletes[] = nullptr,
size_t nObsoletes = 0) const
{

View File

@ -43,7 +43,7 @@
#define __AUDACITY_EFFECTINTERFACE_H__
#include "audacity/Types.h"
#include "audacity/IdentInterface.h"
#include "audacity/ComponentInterface.h"
#include "audacity/ConfigInterface.h"
#include "audacity/EffectAutomationParameters.h" // for command automation
@ -59,46 +59,18 @@ typedef enum EffectType : int
EffectTypeTool,
} EffectType;
using NumericFormatId = IdentInterfaceSymbol;
class ShuttleParams;
using NumericFormatId = ComponentInterfaceSymbol;
/*************************************************************************************//**
\class ParamsInterface
\brief ParamsInterface provides a DefineParameters virtual function,
that defines the parameters of the command.
*******************************************************************************************/
class AUDACITY_DLL_API ParamsInterface /* not final */
{
public:
virtual ~ParamsInterface() {};
// returns true if implemented.
virtual bool DefineParams( ShuttleParams & WXUNUSED(S) ){ return false;};
};
/*************************************************************************************//**
\class CommandDefinitionInterface
\brief CommandDefinitionInterface is an IdentInterface (to name the command) along with a
DefineParameters virtual function, that defines the parameters of the command.
*******************************************************************************************/
class AUDACITY_DLL_API CommandDefinitionInterface /* not final */ : public IdentInterface, public ParamsInterface
{
public:
virtual ~CommandDefinitionInterface() {};
};
/*************************************************************************************//**
\class EffectDefinitionInterface
\brief EffectDefinitionInterface is a CommandDefinitionInterface that additionally tracks
\brief EffectDefinitionInterface is a ComponentInterface that additionally tracks
flag-functions for interactivity, play-preview and whether the effect can run without a GUI.
*******************************************************************************************/
class AUDACITY_DLL_API EffectDefinitionInterface /* not final */ : public IdentInterface, public ParamsInterface
class AUDACITY_DLL_API EffectDefinitionInterface /* not final */ : public ComponentInterface
{
public:
virtual ~EffectDefinitionInterface() {};
@ -108,7 +80,7 @@ public:
// Classification determines which menu it appears in.
virtual EffectType GetClassification() { return GetType();};
virtual IdentInterfaceSymbol GetFamilyId() = 0;
virtual ComponentInterfaceSymbol GetFamilyId() = 0;
// These should move to the "EffectClientInterface" class once all
// effects have been converted.

View File

@ -44,7 +44,7 @@
#include "audacity/Types.h"
#include "audacity/ConfigInterface.h"
#include "audacity/IdentInterface.h"
#include "audacity/ComponentInterface.h"
// ============================================================================
//
@ -54,7 +54,7 @@
class ImporterHostInterface;
class ImporterClientInterface;
class ImporterInterface : public IdentInterface
class ImporterInterface : public ComponentInterface
{
public:
virtual ~ImporterInterface() {};

View File

@ -44,7 +44,7 @@
#include <functional>
#include "audacity/Types.h"
#include "audacity/IdentInterface.h"
#include "audacity/ComponentInterface.h"
#include "audacity/PluginInterface.h"
// ============================================================================
@ -64,7 +64,7 @@
///
// ============================================================================
class ModuleInterface /* not final */ : public IdentInterface
class ModuleInterface /* not final */ : public ComponentInterface
{
public:
virtual ~ModuleInterface() {};
@ -113,7 +113,7 @@ public:
// Return value is the number of plugins found.
using RegistrationCallback =
std::function<
const PluginID &(ModuleInterface *, IdentInterface *) >;
const PluginID &(ModuleInterface *, ComponentInterface *) >;
virtual unsigned DiscoverPluginsAtPath(
const wxString & path, wxString &errMsg,
const RegistrationCallback &callback )
@ -124,10 +124,10 @@ public:
virtual bool IsPluginValid(const wxString & path, bool bFast) = 0;
// When appropriate, CreateInstance() will be called to instantiate the plugin.
virtual IdentInterface *CreateInstance(const wxString & path) = 0;
virtual ComponentInterface *CreateInstance(const wxString & path) = 0;
// When appropriate, DeleteInstance() will be called to delete the plugin.
virtual void DeleteInstance(IdentInterface *instance) = 0;
virtual void DeleteInstance(ComponentInterface *instance) = 0;
};
// ============================================================================

View File

@ -44,7 +44,7 @@
#include "audacity/ConfigInterface.h"
#include "audacity/EffectInterface.h"
#include "audacity/IdentInterface.h"
#include "audacity/ComponentInterface.h"
#include "audacity/ImporterInterface.h"
#include "audacity/ModuleInterface.h"
@ -57,9 +57,9 @@ class PluginManagerInterface /* not final */
public:
static const PluginID &DefaultRegistrationCallback(
ModuleInterface *provider, IdentInterface *ident );
ModuleInterface *provider, ComponentInterface *ident );
static const PluginID &AudacityCommandRegistrationCallback(
ModuleInterface *provider, IdentInterface *ident );
ModuleInterface *provider, ComponentInterface *ident );
virtual bool IsPluginRegistered(const wxString & path) = 0;

View File

@ -1,7 +1,7 @@
include/audacity/ComponentInterface.h
include/audacity/ConfigInterface.h
include/audacity/EffectAutomationParameters.h
include/audacity/EffectInterface.h
include/audacity/IdentInterface.h
include/audacity/ImporterInterface.h
include/audacity/ModuleInterface.h
include/audacity/PluginInterface.h

View File

@ -31,7 +31,7 @@ and on Mac OS X for the filesystem.
#include "FileNames.h"
#include "widgets/ErrorDialog.h"
#include "Internat.h"
#include "../include/audacity/IdentInterface.h"
#include "../include/audacity/ComponentInterface.h"
// in order for the static member variables to exist, they must appear here
// (_outside_) the class definition, in order to be allocated some storage.
@ -301,10 +301,10 @@ wxString Internat::StripAccelerators(const wxString &s)
}
wxArrayString LocalizedStrings(
const IdentInterfaceSymbol strings[], size_t nStrings)
const ComponentInterfaceSymbol strings[], size_t nStrings)
{
wxArrayString results;
std::transform( strings, strings + nStrings, std::back_inserter(results),
std::mem_fn( &IdentInterfaceSymbol::Translation ) );
std::mem_fn( &ComponentInterfaceSymbol::Translation ) );
return results;
}

View File

@ -179,9 +179,9 @@ private:
#define UTF8CTOWX(X) wxString((X), wxConvUTF8)
#define LAT1CTOWX(X) wxString((X), wxConvISO8859_1)
class IdentInterfaceSymbol;
class ComponentInterfaceSymbol;
wxArrayString LocalizedStrings(
const IdentInterfaceSymbol strings[], size_t nStrings);
const ComponentInterfaceSymbol strings[], size_t nStrings);
// This object pairs an internal string, maybe empty, with a translated string.
// Any internal string may be written to configuration or other files and,

View File

@ -127,7 +127,7 @@ CommandItem::CommandItem(const wxString &name_,
CommandItem::~CommandItem() {}
CommandGroupItem::CommandGroupItem(const wxString &name_,
const IdentInterfaceSymbol items_[],
const ComponentInterfaceSymbol items_[],
size_t nItems_,
CommandHandlerFinder finder_,
CommandFunctorPointer callback_,

View File

@ -552,7 +552,7 @@ bool ModuleManager::RegisterEffectPlugin(const PluginID & providerID, const wxSt
return nFound > 0;
}
IdentInterface *ModuleManager::CreateProviderInstance(const PluginID & providerID,
ComponentInterface *ModuleManager::CreateProviderInstance(const PluginID & providerID,
const wxString & path)
{
if (path.IsEmpty() && mDynModules.find(providerID) != mDynModules.end())
@ -563,7 +563,7 @@ IdentInterface *ModuleManager::CreateProviderInstance(const PluginID & providerI
return LoadModule(path);
}
IdentInterface *ModuleManager::CreateInstance(const PluginID & providerID,
ComponentInterface *ModuleManager::CreateInstance(const PluginID & providerID,
const wxString & path)
{
if (mDynModules.find(providerID) == mDynModules.end())
@ -575,7 +575,7 @@ IdentInterface *ModuleManager::CreateInstance(const PluginID & providerID,
}
void ModuleManager::DeleteInstance(const PluginID & providerID,
IdentInterface *instance)
ComponentInterface *instance)
{
if (mDynModules.find(providerID) == mDynModules.end())
{

View File

@ -102,9 +102,9 @@ public:
bool RegisterEffectPlugin(const PluginID & provider, const wxString & path,
wxString &errMsg);
IdentInterface *CreateProviderInstance(const PluginID & provider, const wxString & path);
IdentInterface *CreateInstance(const PluginID & provider, const wxString & path);
void DeleteInstance(const PluginID & provider, IdentInterface *instance);
ComponentInterface *CreateProviderInstance(const PluginID & provider, const wxString & path);
ComponentInterface *CreateInstance(const PluginID & provider, const wxString & path);
void DeleteInstance(const PluginID & provider, ComponentInterface *instance);
bool IsProviderValid(const PluginID & provider, const wxString & path);
bool IsPluginValid(const PluginID & provider, const wxString & path, bool bFast);

View File

@ -1106,7 +1106,7 @@ bool PluginDescriptor::IsInstantiated() const
return mInstance != NULL;
}
IdentInterface *PluginDescriptor::GetInstance()
ComponentInterface *PluginDescriptor::GetInstance()
{
if (!mInstance)
{
@ -1123,7 +1123,7 @@ IdentInterface *PluginDescriptor::GetInstance()
return mInstance;
}
void PluginDescriptor::SetInstance(IdentInterface *instance)
void PluginDescriptor::SetInstance(ComponentInterface *instance)
{
if (mInstance && mInstance != instance)
{
@ -1156,7 +1156,7 @@ const wxString & PluginDescriptor::GetPath() const
return mPath;
}
const IdentInterfaceSymbol & PluginDescriptor::GetSymbol() const
const ComponentInterfaceSymbol & PluginDescriptor::GetSymbol() const
{
return mSymbol;
}
@ -1201,7 +1201,7 @@ void PluginDescriptor::SetPath(const wxString & path)
mPath = path;
}
void PluginDescriptor::SetSymbol(const IdentInterfaceSymbol & symbol)
void PluginDescriptor::SetSymbol(const ComponentInterfaceSymbol & symbol)
{
mSymbol = symbol;
}
@ -1380,12 +1380,12 @@ void PluginDescriptor::SetImporterExtensions(const wxArrayString & extensions)
// ============================================================================
const PluginID &PluginManagerInterface::DefaultRegistrationCallback(
ModuleInterface *provider, IdentInterface *pInterface )
ModuleInterface *provider, ComponentInterface *pInterface )
{
EffectDefinitionInterface * pEInterface = dynamic_cast<EffectDefinitionInterface*>(pInterface);
if( pEInterface )
return PluginManager::Get().RegisterPlugin(provider, pEInterface, PluginTypeEffect);
CommandDefinitionInterface * pCInterface = dynamic_cast<CommandDefinitionInterface*>(pInterface);
ComponentInterface * pCInterface = dynamic_cast<ComponentInterface*>(pInterface);
if( pCInterface )
return PluginManager::Get().RegisterPlugin(provider, pCInterface);
static wxString empty;
@ -1393,9 +1393,9 @@ const PluginID &PluginManagerInterface::DefaultRegistrationCallback(
}
const PluginID &PluginManagerInterface::AudacityCommandRegistrationCallback(
ModuleInterface *provider, IdentInterface *pInterface )
ModuleInterface *provider, ComponentInterface *pInterface )
{
CommandDefinitionInterface * pCInterface = dynamic_cast<CommandDefinitionInterface*>(pInterface);
ComponentInterface * pCInterface = dynamic_cast<ComponentInterface*>(pInterface);
if( pCInterface )
return PluginManager::Get().RegisterPlugin(provider, pCInterface);
static wxString empty;
@ -1426,7 +1426,7 @@ const PluginID & PluginManager::RegisterPlugin(ModuleInterface *module)
return plug.GetID();
}
const PluginID & PluginManager::RegisterPlugin(ModuleInterface *provider, CommandDefinitionInterface *command)
const PluginID & PluginManager::RegisterPlugin(ModuleInterface *provider, ComponentInterface *command)
{
PluginDescriptor & plug = CreatePlugin(GetID(command), command, (PluginType)PluginTypeAudacityCommand);
@ -1845,7 +1845,7 @@ bool PluginManager::DropFile(const wxString &fileName)
std::vector<PluginID> ids;
std::vector<wxString> names;
nPlugIns = module->DiscoverPluginsAtPath(dstPath, errMsg,
[&](ModuleInterface *provider, IdentInterface *ident)
[&](ModuleInterface *provider, ComponentInterface *ident)
-> const PluginID& {
// Register as by default, but also collecting the PluginIDs
// and names
@ -2615,18 +2615,18 @@ void PluginManager::EnablePlugin(const PluginID & ID, bool enable)
return mPlugins[ID].SetEnabled(enable);
}
const IdentInterfaceSymbol & PluginManager::GetSymbol(const PluginID & ID)
const ComponentInterfaceSymbol & PluginManager::GetSymbol(const PluginID & ID)
{
if (mPlugins.find(ID) == mPlugins.end())
{
static IdentInterfaceSymbol empty;
static ComponentInterfaceSymbol empty;
return empty;
}
return mPlugins[ID].GetSymbol();
}
IdentInterface *PluginManager::GetInstance(const PluginID & ID)
ComponentInterface *PluginManager::GetInstance(const PluginID & ID)
{
if (mPlugins.find(ID) == mPlugins.end())
{
@ -2659,7 +2659,7 @@ PluginID PluginManager::GetID(ModuleInterface *module)
module->GetPath());
}
PluginID PluginManager::GetID(CommandDefinitionInterface *command)
PluginID PluginManager::GetID(ComponentInterface *command)
{
return wxString::Format(wxT("%s_%s_%s_%s_%s"),
GetPluginTypeString(PluginTypeAudacityCommand),
@ -2725,7 +2725,7 @@ wxString PluginManager::GetPluginTypeString(PluginType type)
}
PluginDescriptor & PluginManager::CreatePlugin(const PluginID & id,
IdentInterface *ident,
ComponentInterface *ident,
PluginType type)
{
// This will either create a NEW entry or replace an existing entry
@ -3192,9 +3192,9 @@ int PluginManager::b64decode(const wxString &in, void *out)
return p - (unsigned char *) out;
}
// These are defined out-of-line here, to keep IdentInterface free of other
// These are defined out-of-line here, to keep ComponentInterface free of other
// #include directives.
const wxString& IdentInterface::GetTranslatedName()
const wxString& ComponentInterface::GetTranslatedName()
{
return GetSymbol().Translation();
}

View File

@ -48,8 +48,8 @@ public:
virtual ~PluginDescriptor();
bool IsInstantiated() const;
IdentInterface *GetInstance();
void SetInstance(IdentInterface *instance);
ComponentInterface *GetInstance();
void SetInstance(ComponentInterface *instance);
PluginType GetPluginType() const;
void SetPluginType(PluginType type);
@ -60,7 +60,7 @@ public:
const wxString & GetID() const;
const wxString & GetProviderID() const;
const wxString & GetPath() const;
const IdentInterfaceSymbol & GetSymbol() const;
const ComponentInterfaceSymbol & GetSymbol() const;
wxString GetUntranslatedVersion() const;
// There is no translated version
@ -74,7 +74,7 @@ public:
void SetID(const PluginID & ID);
void SetProviderID(const PluginID & providerID);
void SetPath(const wxString & path);
void SetSymbol(const IdentInterfaceSymbol & symbol);
void SetSymbol(const ComponentInterfaceSymbol & symbol);
// These should be passed an untranslated value wrapped in XO() so
// the value will still be extracted for translation
@ -127,13 +127,13 @@ private:
// Among other purposes, PluginDescriptor acts as the resouce handle,
// or smart pointer, to a resource created in a plugin library, and is responsible
// for a cleanup of this pointer.
IdentInterface *mInstance;
ComponentInterface *mInstance;
PluginType mPluginType;
wxString mID;
wxString mPath;
IdentInterfaceSymbol mSymbol;
ComponentInterfaceSymbol mSymbol;
wxString mVersion;
wxString mVendor;
wxString mProviderID;
@ -178,7 +178,7 @@ public:
bool IsPluginRegistered(const wxString & path) override;
const PluginID & RegisterPlugin(ModuleInterface *module) override;
const PluginID & RegisterPlugin(ModuleInterface *provider, CommandDefinitionInterface *command);
const PluginID & RegisterPlugin(ModuleInterface *provider, ComponentInterface *command);
const PluginID & RegisterPlugin(ModuleInterface *provider, EffectDefinitionInterface *effect, int type) override;
const PluginID & RegisterPlugin(ModuleInterface *provider, ImporterInterface *importer) override;
@ -233,7 +233,7 @@ public:
static PluginManager & Get();
static PluginID GetID(ModuleInterface *module);
static PluginID GetID(CommandDefinitionInterface *command);
static PluginID GetID(ComponentInterface *command);
static PluginID GetID(EffectDefinitionInterface *effect);
static PluginID GetID(ImporterInterface *importer);
@ -253,8 +253,8 @@ public:
bool IsPluginEnabled(const PluginID & ID);
void EnablePlugin(const PluginID & ID, bool enable);
const IdentInterfaceSymbol & GetSymbol(const PluginID & ID);
IdentInterface *GetInstance(const PluginID & ID);
const ComponentInterfaceSymbol & GetSymbol(const PluginID & ID);
ComponentInterface *GetInstance(const PluginID & ID);
void CheckForUpdates(bool bFast = false);
@ -273,7 +273,7 @@ private:
void Save();
void SaveGroup(wxFileConfig *pRegistry, PluginType type);
PluginDescriptor & CreatePlugin(const PluginID & id, IdentInterface *ident, PluginType type);
PluginDescriptor & CreatePlugin(const PluginID & id, ComponentInterface *ident, PluginType type);
wxFileConfig *GetSettings();

View File

@ -397,7 +397,7 @@ wxString EnumSetting::Read() const
size_t EnumSetting::Find( const wxString &value ) const
{
return size_t(
std::find( begin(), end(), IdentInterfaceSymbol{ value, {} } )
std::find( begin(), end(), ComponentInterfaceSymbol{ value, {} } )
- mSymbols );
}

View File

@ -30,7 +30,7 @@
#define __AUDACITY_PREFS__
#include "Audacity.h"
#include "../include/audacity/IdentInterface.h"
#include "../include/audacity/ComponentInterface.h"
#include <wx/config.h>
#include <wx/fileconf.h>
@ -65,7 +65,7 @@ class EnumSetting
public:
EnumSetting(
const wxString &key,
const IdentInterfaceSymbol symbols[], size_t nSymbols,
const ComponentInterfaceSymbol symbols[], size_t nSymbols,
size_t defaultSymbol
)
: mKey{ key }
@ -79,10 +79,10 @@ public:
}
const wxString &Key() const { return mKey; }
const IdentInterfaceSymbol &Default() const
const ComponentInterfaceSymbol &Default() const
{ return mSymbols[mDefaultSymbol]; }
const IdentInterfaceSymbol *begin() const { return mSymbols; }
const IdentInterfaceSymbol *end() const { return mSymbols + mnSymbols; }
const ComponentInterfaceSymbol *begin() const { return mSymbols; }
const ComponentInterfaceSymbol *end() const { return mSymbols + mnSymbols; }
wxString Read() const;
bool Write( const wxString &value ); // you flush gPrefs afterward
@ -93,7 +93,7 @@ protected:
const wxString mKey;
const IdentInterfaceSymbol *mSymbols;
const ComponentInterfaceSymbol *mSymbols;
const size_t mnSymbols;
// stores an internal value
@ -111,7 +111,7 @@ class EncodedEnumSetting : public EnumSetting
public:
EncodedEnumSetting(
const wxString &key,
const IdentInterfaceSymbol symbols[], size_t nSymbols,
const ComponentInterfaceSymbol symbols[], size_t nSymbols,
size_t defaultSymbol,
const int intValues[] = nullptr, // must have same size as symbols

View File

@ -24,7 +24,7 @@ responsible for calling the appropriate callback functions.
#include "MemoryX.h"
class LoadableModule;
class CommandDefinitionInterface;
class ComponentInterface;
class Effect;
class AUDACITY_DLL_API Registrar
@ -40,7 +40,7 @@ public:
bool bWantsCommands;
bool bWantsCommandTypes;
bool bWantsEffects;
virtual void AddCommandType(std::unique_ptr<CommandDefinitionInterface> && WXUNUSED(comDef) ){;};
virtual void AddCommandType(std::unique_ptr<ComponentInterface> && WXUNUSED(comDef) ){;};
virtual void AddCommand(std::unique_ptr<AudacityCommand> && WXUNUSED(command) ){;};
virtual void AddModule(std::unique_ptr<LoadableModule> && WXUNUSED(module) ){;};
virtual void AddEffect(std::unique_ptr<Effect> && WXUNUSED(effect) ){;};

View File

@ -26,7 +26,7 @@
#include "Prefs.h"
#include "TranslatableStringArray.h"
#include "Internat.h"
#include "../include/audacity/IdentInterface.h"
#include "../include/audacity/ComponentInterface.h"
#include <soxr.h>
@ -52,7 +52,7 @@ Resample::~Resample()
}
//////////
static const IdentInterfaceSymbol methodNames[] = {
static const ComponentInterfaceSymbol methodNames[] = {
{ wxT("LowQuality"), XO("Low Quality (Fastest)") },
{ wxT("MediumQuality"), XO("Medium Quality") },
{ wxT("HighQuality"), XO("High Quality") },

View File

@ -342,12 +342,12 @@ void ShuttleParams::Define( float & var, const wxChar * key, const float vdef
void ShuttleParams::Define( double & var, const wxChar * key, const float vdefault, const float vmin, const float vmax, const float vscl ){;};
void ShuttleParams::Define( double & var, const wxChar * key, const double vdefault, const double vmin, const double vmax, const double vscl ){;};
void ShuttleParams::Define( wxString &var, const wxChar * key, const wxString vdefault, const wxString vmin, const wxString vmax, const wxString vscl ){;};
void ShuttleParams::DefineEnum( int &var, const wxChar * key, const int vdefault, const IdentInterfaceSymbol strings[], size_t nStrings ){;};
void ShuttleParams::DefineEnum( int &var, const wxChar * key, const int vdefault, const ComponentInterfaceSymbol strings[], size_t nStrings ){;};
/*
void ShuttleParams::DefineEnum( int &var, const wxChar * key, const int vdefault, const IdentInterfaceSymbol strings[], size_t nStrings )
void ShuttleParams::DefineEnum( int &var, const wxChar * key, const int vdefault, const ComponentInterfaceSymbol strings[], size_t nStrings )
{
}
*/
@ -402,7 +402,7 @@ void ShuttleGetAutomation::Define( wxString &var, const wxChar * key, const wxSt
}
void ShuttleGetAutomation::DefineEnum( int &var, const wxChar * key, const int vdefault, const IdentInterfaceSymbol strings[], size_t nStrings )
void ShuttleGetAutomation::DefineEnum( int &var, const wxChar * key, const int vdefault, const ComponentInterfaceSymbol strings[], size_t nStrings )
{
if( !ShouldSet() ) return;
mpEap->Write(key, strings[var].Internal());
@ -512,7 +512,7 @@ void ShuttleSetAutomation::Define( wxString &var, const wxChar * key, const wxSt
}
void ShuttleSetAutomation::DefineEnum( int &var, const wxChar * key, const int vdefault, const IdentInterfaceSymbol strings[], size_t nStrings )
void ShuttleSetAutomation::DefineEnum( int &var, const wxChar * key, const int vdefault, const ComponentInterfaceSymbol strings[], size_t nStrings )
{
CouldGet( key );
if( !bOK )
@ -629,7 +629,7 @@ void ShuttleGetDefinition::Define( wxString &var, const wxChar * key, const wxSt
void ShuttleGetDefinition::DefineEnum( int &var,
const wxChar * key, const int vdefault,
const IdentInterfaceSymbol strings[], size_t nStrings )
const ComponentInterfaceSymbol strings[], size_t nStrings )
{
StartStruct();
AddItem( wxString(key), "key" );

View File

@ -12,9 +12,9 @@
#define __AUDACITY_SHUTTLE__
#include "commands/CommandTargets.h"
#include "../include/audacity/IdentInterface.h"
#include "../include/audacity/ComponentInterface.h"
class IdentInterfaceSymbol;
class ComponentInterfaceSymbol;
class WrappedType;
class Shuttle /* not final */ {
@ -78,7 +78,7 @@ public:
virtual void Define( double & var, const wxChar * key, const double vdefault, const double vmin, const double vmax, const double vscl=1.0f );
virtual void Define( wxString &var, const wxChar * key, const wxString vdefault, const wxString vmin="", const wxString vmax="", const wxString vscl="" );
virtual void DefineEnum( int &var, const wxChar * key, const int vdefault,
const IdentInterfaceSymbol strings[], size_t nStrings );
const ComponentInterfaceSymbol strings[], size_t nStrings );
};
/**************************************************************************//**
@ -96,7 +96,7 @@ public:
void Define( double & var, const wxChar * key, const double vdefault, const double vmin, const double vmax, const double vscl ) override;
void Define( wxString &var, const wxChar * key, const wxString vdefault, const wxString vmin, const wxString vmax, const wxString vscl ) override;
void DefineEnum( int &var, const wxChar * key, const int vdefault,
const IdentInterfaceSymbol strings[], size_t nStrings ) override;
const ComponentInterfaceSymbol strings[], size_t nStrings ) override;
};
/**************************************************************************//**
@ -120,7 +120,7 @@ public:
void Define( double & var, const wxChar * key, const double vdefault, const double vmin, const double vmax, const double vscl ) override;
void Define( wxString &var, const wxChar * key, const wxString vdefault, const wxString vmin, const wxString vmax, const wxString vscl ) override;
void DefineEnum( int &var, const wxChar * key, const int vdefault,
const IdentInterfaceSymbol strings[], size_t nStrings ) override;
const ComponentInterfaceSymbol strings[], size_t nStrings ) override;
};
/**************************************************************************//**
@ -141,7 +141,7 @@ public:
void Define( double & var, const wxChar * key, const double vdefault, const double vmin, const double vmax, const double vscl ) override;
void Define( wxString &var, const wxChar * key, const wxString vdefault, const wxString vmin, const wxString vmax, const wxString vscl ) override;
void DefineEnum( int &var, const wxChar * key, const int vdefault,
const IdentInterfaceSymbol strings[], size_t nStrings ) override;
const ComponentInterfaceSymbol strings[], size_t nStrings ) override;
};
@ -178,7 +178,7 @@ public:
const wxString WXUNUSED(vmin), const wxString WXUNUSED(vmax), const wxString WXUNUSED(vscl) )
override { var = vdefault;};
void DefineEnum( int &var, const wxChar * WXUNUSED(key), const int vdefault,
const IdentInterfaceSymbol WXUNUSED(strings) [], size_t WXUNUSED( nStrings ) )
const ComponentInterfaceSymbol WXUNUSED(strings) [], size_t WXUNUSED( nStrings ) )
override { var = vdefault;};
};

View File

@ -107,7 +107,7 @@ for registering for changes.
#include <wx/treectrl.h>
#include <wx/spinctrl.h>
#include <wx/bmpbuttn.h>
#include "../include/audacity/IdentInterface.h"
#include "../include/audacity/ComponentInterface.h"
#include "Internat.h"
#include "WrappedType.h"
#include "widgets/wxPanelWrapper.h"

View File

@ -80,7 +80,7 @@ AudacityCommand::~AudacityCommand()
wxString AudacityCommand::GetPath(){ return BUILTIN_GENERIC_COMMAND_PREFIX + GetSymbol().Internal(); }
IdentInterfaceSymbol AudacityCommand::GetVendor(){ return XO("Audacity");}
ComponentInterfaceSymbol AudacityCommand::GetVendor(){ return XO("Audacity");}
wxString AudacityCommand::GetVersion(){ return AUDACITY_VERSION_STRING;}

View File

@ -35,7 +35,7 @@ class wxWindow;
#include "../Shuttle.h"
#include "../Internat.h"
#include "../widgets/ProgressDialog.h"
#include "../include/audacity/IdentInterface.h"
#include "../include/audacity/ComponentInterface.h"
#include "../include/audacity/EffectAutomationParameters.h" // for command automation
#include "../Track.h"
@ -51,7 +51,7 @@ class CommandContext;
class AUDACITY_DLL_API AudacityCommand /* not final */ : public wxEvtHandler,
public CommandDefinitionInterface
public ComponentInterface
{
public:
//std::unique_ptr<CommandOutputTargets> mOutput;
@ -60,16 +60,16 @@ class AUDACITY_DLL_API AudacityCommand /* not final */ : public wxEvtHandler,
AudacityCommand();
virtual ~AudacityCommand();
// IdentInterface implementation
// ComponentInterface implementation
//These four can be defaulted....
wxString GetPath() override;
IdentInterfaceSymbol GetVendor() override;
ComponentInterfaceSymbol GetVendor() override;
wxString GetVersion() override;
// virtual wxString GetFamily();
//These two must be implemented by instances.
IdentInterfaceSymbol GetSymbol() override = 0;
ComponentInterfaceSymbol GetSymbol() override = 0;
virtual wxString GetDescription() override
{wxFAIL_MSG( "Implement a Description for this command");return "FAIL";};

View File

@ -17,7 +17,7 @@
#include "BatchEvalCommand.h"
#include "CommandContext.h"
IdentInterfaceSymbol BatchEvalCommandType::BuildName()
ComponentInterfaceSymbol BatchEvalCommandType::BuildName()
{
return { wxT("BatchCommand"), XO("Batch Command") };
}

View File

@ -29,7 +29,7 @@ to that system.
class BatchEvalCommandType final : public OldStyleCommandType
{
public:
IdentInterfaceSymbol BuildName() override;
ComponentInterfaceSymbol BuildName() override;
void BuildSignature(CommandSignature &signature) override;
OldStyleCommandPointer Create(std::unique_ptr<CommandOutputTargets> &&target) override;
};

View File

@ -106,7 +106,7 @@ DecoratedCommand::~DecoratedCommand()
{
}
IdentInterfaceSymbol DecoratedCommand::GetSymbol()
ComponentInterfaceSymbol DecoratedCommand::GetSymbol()
{
return mCommand->GetSymbol();
}
@ -246,7 +246,7 @@ wxString CommandImplementation::GetString(const wxString &paramName)
}
/// Get the name of the command
IdentInterfaceSymbol CommandImplementation::GetSymbol()
ComponentInterfaceSymbol CommandImplementation::GetSymbol()
{
return mType.GetSymbol();
}

View File

@ -35,7 +35,7 @@ class OldStyleCommand /* not final */
public:
OldStyleCommand() {};
virtual ~OldStyleCommand() { }
virtual IdentInterfaceSymbol GetSymbol() = 0;
virtual ComponentInterfaceSymbol GetSymbol() = 0;
virtual CommandSignature &GetSignature() = 0;
virtual bool SetParameter(const wxString &paramName, const wxVariant &paramValue);
virtual bool Apply()=0;
@ -57,7 +57,7 @@ public:
wxASSERT(cmd != NULL);
}
virtual ~DecoratedCommand();
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
CommandSignature &GetSignature() override;
bool SetParameter(const wxString &paramName, const wxVariant &paramValue) override;
};
@ -105,7 +105,7 @@ public:
virtual ~CommandImplementation();
/// An instance method for getting the command name (for consistency)
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
/// Get the signature of the command
CommandSignature &GetSignature() override;

View File

@ -805,7 +805,7 @@ void CommandManager::AddItem(const wxChar *name,
/// When you call Enable on this command name, it will enable or disable
/// all of the items at once.
void CommandManager::AddItemList(const wxString & name,
const IdentInterfaceSymbol items[],
const ComponentInterfaceSymbol items[],
size_t nItems,
CommandHandlerFinder finder,
CommandFunctorPointer callback,

View File

@ -179,7 +179,7 @@ class AUDACITY_DLL_API CommandManager final : public XMLTagHandler
};
void AddItemList(const wxString & name,
const IdentInterfaceSymbol items[],
const ComponentInterfaceSymbol items[],
size_t nItems,
CommandHandlerFinder finder,
CommandFunctorPointer callback,
@ -528,7 +528,7 @@ namespace MenuTable {
struct CommandGroupItem final : BaseItem {
CommandGroupItem(const wxString &name_,
const IdentInterfaceSymbol items_[],
const ComponentInterfaceSymbol items_[],
size_t nItems_,
CommandHandlerFinder finder_,
CommandFunctorPointer callback_,
@ -537,7 +537,7 @@ namespace MenuTable {
~CommandGroupItem() override;
const wxString name;
const std::vector<IdentInterfaceSymbol> items;
const std::vector<ComponentInterfaceSymbol> items;
CommandHandlerFinder finder;
CommandFunctorPointer callback;
CommandFlag flags;
@ -620,7 +620,7 @@ namespace MenuTable {
inline std::unique_ptr<CommandGroupItem> CommandGroup(
const wxString &name,
const IdentInterfaceSymbol items[], size_t nItems,
const ComponentInterfaceSymbol items[], size_t nItems,
CommandHandlerFinder finder, CommandFunctorPointer callback,
CommandFlag flags, bool isEffect = false)
{

View File

@ -31,7 +31,7 @@ OldStyleCommandType::~OldStyleCommandType()
{
}
IdentInterfaceSymbol OldStyleCommandType::GetSymbol()
ComponentInterfaceSymbol OldStyleCommandType::GetSymbol()
{
if (mSymbol.empty())
mSymbol = BuildName();

View File

@ -44,13 +44,13 @@ class wxString;
class OldStyleCommandType : public AudacityCommand
{
private:
IdentInterfaceSymbol mSymbol;
ComponentInterfaceSymbol mSymbol;
Maybe<CommandSignature> mSignature;
public:
OldStyleCommandType();
virtual ~OldStyleCommandType();
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
CommandSignature &GetSignature();
wxString Describe(); // for debugging only ?
@ -58,7 +58,7 @@ public:
// =========================================
// Return the name of the command type
virtual IdentInterfaceSymbol BuildName() = 0;
virtual ComponentInterfaceSymbol BuildName() = 0;
/// Postcondition: signature is a 'signature' map containing parameter
// names, validators and default values.

View File

@ -23,13 +23,13 @@ classes
class WaveTrack;
#define COMPARE_AUDIO_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Compare Audio") }
#define COMPARE_AUDIO_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Compare Audio") }
class CompareAudioCommand final : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return XO("Compare Audio");}
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return XO("Compare Audio");}
wxString GetDescription() override {return _("Compares a range on two tracks.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -20,13 +20,13 @@
class ShuttleGui;
#define DEMO_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Demo") }
#define DEMO_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Demo") }
class DemoCommand final : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return DEMO_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return DEMO_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Does the demo action.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -38,7 +38,7 @@ enum kCoordTypes
nCoordTypes
};
static const IdentInterfaceSymbol kCoordTypeStrings[nCoordTypes] =
static const ComponentInterfaceSymbol kCoordTypeStrings[nCoordTypes] =
{
{ XO("Panel") },
{ wxT("App"), XO("Application") },

View File

@ -19,14 +19,14 @@
#include "Command.h"
#include "CommandType.h"
#define DRAG_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Drag") }
#define DRAG_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Drag") }
class DragCommand : public AudacityCommand
{
public:
DragCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return DRAG_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return DRAG_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Drags mouse from one place to another.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -55,7 +55,7 @@ enum {
nTypes
};
static const IdentInterfaceSymbol kTypes[nTypes] =
static const ComponentInterfaceSymbol kTypes[nTypes] =
{
{ XO("Commands") },
//{ wxT("CommandsPlus"), XO("Commands Plus") },
@ -75,7 +75,7 @@ enum {
nFormats
};
static const IdentInterfaceSymbol kFormats[nFormats] =
static const ComponentInterfaceSymbol kFormats[nFormats] =
{
// These are acceptable dual purpose internal/visible names

View File

@ -26,13 +26,13 @@ channel.
class wxMenuBar;
class wxPoint;
#define GET_INFO_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Get Info") }
#define GET_INFO_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Get Info") }
class GetInfoCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return GET_INFO_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return GET_INFO_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Gets information in JSON format.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -27,7 +27,7 @@
#include "CommandContext.h"
const int nTypes =3;
static const IdentInterfaceSymbol kTypes[nTypes] =
static const ComponentInterfaceSymbol kTypes[nTypes] =
{
{ XO("Tracks") },
{ XO("Clips") },

View File

@ -19,14 +19,14 @@
#include "Command.h"
#include "CommandType.h"
#define GET_TRACK_INFO_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Get Track Info") }
#define GET_TRACK_INFO_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Get Track Info") }
class GetTrackInfoCommand final : public AudacityCommand
{
public:
GetTrackInfoCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return GET_TRACK_INFO_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return GET_TRACK_INFO_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Gets track values as JSON.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -23,13 +23,13 @@
#include "CommandType.h"
#include "Command.h"
#define HELP_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Help") }
#define HELP_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Help") }
class HelpCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return HELP_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return HELP_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Gives help on a command.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -23,13 +23,13 @@
// Import
#define IMPORT_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Import2") }
#define IMPORT_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Import2") }
class ImportCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return IMPORT_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return IMPORT_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Imports from a file.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;
@ -41,13 +41,13 @@ public:
wxString mFileName;
};
#define EXPORT_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Export2") }
#define EXPORT_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Export2") }
class ExportCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return EXPORT_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return EXPORT_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Exports to a file.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -170,7 +170,7 @@ BuiltinCommandsModule::~BuiltinCommandsModule()
}
// ============================================================================
// IdentInterface implementation
// ComponentInterface implementation
// ============================================================================
wxString BuiltinCommandsModule::GetPath()
@ -178,12 +178,12 @@ wxString BuiltinCommandsModule::GetPath()
return mPath;
}
IdentInterfaceSymbol BuiltinCommandsModule::GetSymbol()
ComponentInterfaceSymbol BuiltinCommandsModule::GetSymbol()
{
return XO("Builtin Commands");
}
IdentInterfaceSymbol BuiltinCommandsModule::GetVendor()
ComponentInterfaceSymbol BuiltinCommandsModule::GetVendor()
{
return XO("The Audacity Team");
}
@ -280,14 +280,14 @@ bool BuiltinCommandsModule::IsPluginValid(const wxString & path, bool bFast)
return mNames.Index(path) != wxNOT_FOUND;
}
IdentInterface *BuiltinCommandsModule::CreateInstance(const wxString & path)
ComponentInterface *BuiltinCommandsModule::CreateInstance(const wxString & path)
{
// Acquires a resource for the application.
// Safety of this depends on complementary calls to DeleteInstance on the module manager side.
return Instantiate(path).release();
}
void BuiltinCommandsModule::DeleteInstance(IdentInterface *instance)
void BuiltinCommandsModule::DeleteInstance(ComponentInterface *instance)
{
// Releases the resource.
std::unique_ptr < AudacityCommand > {

View File

@ -28,11 +28,11 @@ public:
BuiltinCommandsModule(ModuleManagerInterface *moduleManager, const wxString *path);
virtual ~BuiltinCommandsModule();
// IdentInterface implementation
// ComponentInterface implementation
wxString GetPath() override;
IdentInterfaceSymbol GetSymbol() override;
IdentInterfaceSymbol GetVendor() override;
ComponentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetVendor() override;
wxString GetVersion() override;
wxString GetDescription() override;
@ -53,8 +53,8 @@ public:
bool IsPluginValid(const wxString & path, bool bFast) override;
IdentInterface *CreateInstance(const wxString & path) override;
void DeleteInstance(IdentInterface *instance) override;
ComponentInterface *CreateInstance(const wxString & path) override;
void DeleteInstance(ComponentInterface *instance) override;
private:
// BuiltinEffectModule implementation

View File

@ -24,13 +24,13 @@
#include "CommandType.h"
#include "Command.h"
#define MESSAGE_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Message") }
#define MESSAGE_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Message") }
class MessageCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return MESSAGE_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return MESSAGE_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Echos a message.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -21,13 +21,13 @@
#include "Command.h"
#include "CommandType.h"
#define OPEN_PROJECT_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Open Project2") }
#define OPEN_PROJECT_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Open Project2") }
class OpenProjectCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return OPEN_PROJECT_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return OPEN_PROJECT_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Opens a project.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;
@ -41,13 +41,13 @@ public:
bool bHasAddToHistory;
};
#define SAVE_PROJECT_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Save Project2") }
#define SAVE_PROJECT_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Save Project2") }
class SaveProjectCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SAVE_PROJECT_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SAVE_PROJECT_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Saves a project.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -26,14 +26,14 @@
// GetPreference
#define GET_PREFERENCE_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Get Preference") }
#define SET_PREFERENCE_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Set Preference") }
#define GET_PREFERENCE_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Get Preference") }
#define SET_PREFERENCE_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Set Preference") }
class GetPreferenceCommand final : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return GET_PREFERENCE_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return GET_PREFERENCE_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Gets the value of a single preference.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;
@ -50,8 +50,8 @@ public:
class SetPreferenceCommand final : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SET_PREFERENCE_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SET_PREFERENCE_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Sets the value of a single preference.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -47,7 +47,7 @@ small calculations of rectangles.
#include "CommandManager.h"
static const IdentInterfaceSymbol
static const ComponentInterfaceSymbol
kCaptureWhatStrings[ ScreenshotCommand::nCaptureWhats ] =
{
{ XO("Window") },
@ -85,7 +85,7 @@ kCaptureWhatStrings[ ScreenshotCommand::nCaptureWhats ] =
};
static const IdentInterfaceSymbol
static const ComponentInterfaceSymbol
kBackgroundStrings[ ScreenshotCommand::nBackgrounds ] =
{
// These are acceptable dual purpose internal/visible names

View File

@ -28,7 +28,7 @@ class AdornedRulerPanel;
class AudacityProject;
class CommandContext;
#define SCREENSHOT_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Screenshot") }
#define SCREENSHOT_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Screenshot") }
class ScreenshotCommand : public AudacityCommand
{
@ -79,8 +79,8 @@ public:
};
ScreenshotCommand(){ mbBringToTop=true;mIgnore=NULL;};
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SCREENSHOT_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SCREENSHOT_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Takes screenshots.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -44,7 +44,7 @@ explicitly code all three.
// Relative to project and relative to selection cover MOST options, since you can already
// set a selection to a clip.
const int nRelativeTos =6;
static const IdentInterfaceSymbol kRelativeTo[nRelativeTos] =
static const ComponentInterfaceSymbol kRelativeTo[nRelativeTos] =
{
{ wxT("ProjectStart"), XO("Project Start") },
{ XO("Project") },
@ -167,7 +167,7 @@ bool SelectFrequenciesCommand::Apply(const CommandContext & context){
}
const int nModes =3;
static const IdentInterfaceSymbol kModes[nModes] =
static const ComponentInterfaceSymbol kModes[nModes] =
{
// These are acceptable dual purpose internal/visible names

View File

@ -25,16 +25,16 @@
//#include "../commands/AudacityCommand.h"
#define SELECT_TIME_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Select Time") }
#define SELECT_FREQUENCIES_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Select Frequencies") }
#define SELECT_TRACKS_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Select Tracks") }
#define SELECT_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Select") }
#define SELECT_TIME_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Select Time") }
#define SELECT_FREQUENCIES_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Select Frequencies") }
#define SELECT_TRACKS_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Select Tracks") }
#define SELECT_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Select") }
class SelectTimeCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SELECT_TIME_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SELECT_TIME_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Selects a time range.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;
@ -57,8 +57,8 @@ public:
class SelectFrequenciesCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SELECT_FREQUENCIES_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SELECT_FREQUENCIES_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Selects a frequency range.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;
@ -78,8 +78,8 @@ public:
class SelectTracksCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SELECT_TRACKS_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SELECT_TRACKS_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Selects a range of tracks.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;
@ -100,8 +100,8 @@ public:
class SelectCommand : public AudacityCommand
{
public:
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SELECT_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SELECT_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Selects Audio.");};
bool DefineParams( ShuttleParams & S ) override {
return

View File

@ -38,7 +38,7 @@ enum kColours
nColours
};
static const IdentInterfaceSymbol kColourStrings[nColours] =
static const ComponentInterfaceSymbol kColourStrings[nColours] =
{
{ wxT("Color0"), XO("Color 0") },
{ wxT("Color1"), XO("Color 1") },

View File

@ -20,14 +20,14 @@
#include "CommandType.h"
#include "SetTrackInfoCommand.h"
#define SET_CLIP_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Set Clip") }
#define SET_CLIP_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Set Clip") }
class SetClipCommand : public SetTrackBase
{
public:
SetClipCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SET_CLIP_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SET_CLIP_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Sets various values for a clip.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -20,14 +20,14 @@
#include "CommandType.h"
#include "SetTrackInfoCommand.h"
#define SET_ENVELOPE_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Set Envelope") }
#define SET_ENVELOPE_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Set Envelope") }
class SetEnvelopeCommand : public SetTrackBase
{
public:
SetEnvelopeCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SET_ENVELOPE_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SET_ENVELOPE_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Sets an envelope point position.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -19,14 +19,14 @@
#include "Command.h"
#include "CommandType.h"
#define SET_LABEL_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Set Label") }
#define SET_LABEL_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Set Label") }
class SetLabelCommand : public AudacityCommand
{
public:
SetLabelCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SET_LABEL_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SET_LABEL_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Sets various values for a label.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -20,14 +20,14 @@
#include "Command.h"
#include "CommandType.h"
#define SET_PROJECT_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Set Project") }
#define SET_PROJECT_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Set Project") }
class SetProjectCommand : public AudacityCommand
{
public:
SetProjectCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SET_PROJECT_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SET_PROJECT_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Sets various values for a project.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;

View File

@ -234,7 +234,7 @@ enum kColours
nColours
};
static const IdentInterfaceSymbol kColourStrings[nColours] =
static const ComponentInterfaceSymbol kColourStrings[nColours] =
{
{ wxT("Color0"), XO("Color 0") },
{ wxT("Color1"), XO("Color 1") },
@ -250,7 +250,7 @@ enum kDisplayTypes
nDisplayTypes
};
static const IdentInterfaceSymbol kDisplayTypeStrings[nDisplayTypes] =
static const ComponentInterfaceSymbol kDisplayTypeStrings[nDisplayTypes] =
{
// These are acceptable dual purpose internal/visible names
{ XO("Waveform") },
@ -264,7 +264,7 @@ enum kScaleTypes
nScaleTypes
};
static const IdentInterfaceSymbol kScaleTypeStrings[nScaleTypes] =
static const ComponentInterfaceSymbol kScaleTypeStrings[nScaleTypes] =
{
// These are acceptable dual purpose internal/visible names
{ XO("Linear") },
@ -280,7 +280,7 @@ enum kZoomTypes
nZoomTypes
};
static const IdentInterfaceSymbol kZoomTypeStrings[nZoomTypes] =
static const ComponentInterfaceSymbol kZoomTypeStrings[nZoomTypes] =
{
{ XO("Reset") },
{ wxT("Times2"), XO("Times 2") },

View File

@ -20,10 +20,10 @@
#include "Command.h"
#include "CommandType.h"
#define SET_TRACK_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Set Track") }
#define SET_TRACK_STATUS_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Set Track Status") }
#define SET_TRACK_AUDIO_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Set Track Audio") }
#define SET_TRACK_VISUALS_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Set Track Visuals") }
#define SET_TRACK_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Set Track") }
#define SET_TRACK_STATUS_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Set Track Status") }
#define SET_TRACK_AUDIO_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Set Track Audio") }
#define SET_TRACK_VISUALS_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Set Track Visuals") }
class Track;
@ -50,8 +50,8 @@ class SetTrackStatusCommand : public SetTrackBase
{
public:
//SetTrackStatusCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SET_TRACK_STATUS_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SET_TRACK_STATUS_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Sets various values for a track.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;
@ -75,8 +75,8 @@ class SetTrackAudioCommand : public SetTrackBase
{
public:
//SetTrackAudioCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SET_TRACK_AUDIO_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SET_TRACK_AUDIO_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Sets various values for a track.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;
@ -102,8 +102,8 @@ class SetTrackVisualsCommand : public SetTrackBase
{
public:
//SetTrackVisualsCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SET_TRACK_VISUALS_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SET_TRACK_VISUALS_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Sets various values for a track.");};
bool DefineParams( ShuttleParams & S ) override;
void PopulateOrExchange(ShuttleGui & S) override;
@ -139,8 +139,8 @@ class SetTrackCommand : public SetTrackBase
{
public:
SetTrackCommand();
// CommandDefinitionInterface overrides
IdentInterfaceSymbol GetSymbol() override {return SET_TRACK_PLUGIN_SYMBOL;};
// ComponentInterface overrides
ComponentInterfaceSymbol GetSymbol() override {return SET_TRACK_PLUGIN_SYMBOL;};
wxString GetDescription() override {return _("Sets various values for a track.");};
// AudacityCommand overrides
wxString ManualPage() override {return wxT("Extra_Menu:_Scriptables_II#set_track");};

View File

@ -78,9 +78,9 @@ EffectAmplify::~EffectAmplify()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectAmplify::GetSymbol()
ComponentInterfaceSymbol EffectAmplify::GetSymbol()
{
return AMPLIFY_PLUGIN_SYMBOL;
}

View File

@ -23,7 +23,7 @@
#include "Effect.h"
#define AMPLIFY_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Amplify") }
#define AMPLIFY_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Amplify") }
class ShuttleGui;
@ -33,9 +33,9 @@ public:
EffectAmplify();
virtual ~EffectAmplify();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -100,9 +100,9 @@ EffectAutoDuck::~EffectAutoDuck()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectAutoDuck::GetSymbol()
ComponentInterfaceSymbol EffectAutoDuck::GetSymbol()
{
return AUTODUCK_PLUGIN_SYMBOL;
}

View File

@ -26,7 +26,7 @@ class ShuttleGui;
#define AUTO_DUCK_PANEL_NUM_CONTROL_POINTS 5
#define AUTODUCK_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Auto Duck") }
#define AUTODUCK_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Auto Duck") }
class EffectAutoDuck final : public Effect
{
@ -34,9 +34,9 @@ public:
EffectAutoDuck();
virtual ~EffectAutoDuck();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -77,9 +77,9 @@ EffectBassTreble::~EffectBassTreble()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectBassTreble::GetSymbol()
ComponentInterfaceSymbol EffectBassTreble::GetSymbol()
{
return BASSTREBLE_PLUGIN_SYMBOL;
}

View File

@ -23,7 +23,7 @@
class ShuttleGui;
#define BASSTREBLE_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Bass and Treble") }
#define BASSTREBLE_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Bass and Treble") }
class EffectBassTrebleState
{
@ -45,9 +45,9 @@ public:
EffectBassTreble();
virtual ~EffectBassTreble();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -127,9 +127,9 @@ EffectChangePitch::~EffectChangePitch()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectChangePitch::GetSymbol()
ComponentInterfaceSymbol EffectChangePitch::GetSymbol()
{
return CHANGEPITCH_PLUGIN_SYMBOL;
}

View File

@ -36,7 +36,7 @@ the pitch without changing the tempo.
class ShuttleGui;
#define CHANGEPITCH_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Change Pitch") }
#define CHANGEPITCH_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Change Pitch") }
class EffectChangePitch final : public EffectSoundTouch
{
@ -44,9 +44,9 @@ public:
EffectChangePitch();
virtual ~EffectChangePitch();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -103,9 +103,9 @@ EffectChangeSpeed::~EffectChangeSpeed()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectChangeSpeed::GetSymbol()
ComponentInterfaceSymbol EffectChangeSpeed::GetSymbol()
{
return CHANGESPEED_PLUGIN_SYMBOL;
}

View File

@ -25,7 +25,7 @@
class ShuttleGui;
#define CHANGESPEED_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Change Speed") }
#define CHANGESPEED_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Change Speed") }
class EffectChangeSpeed final : public Effect
{
@ -33,9 +33,9 @@ public:
EffectChangeSpeed();
virtual ~EffectChangeSpeed();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -104,9 +104,9 @@ EffectChangeTempo::~EffectChangeTempo()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectChangeTempo::GetSymbol()
ComponentInterfaceSymbol EffectChangeTempo::GetSymbol()
{
return CHANGETEMPO_PLUGIN_SYMBOL;
}

View File

@ -30,7 +30,7 @@
class ShuttleGui;
#define CHANGETEMPO_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Change Tempo") }
#define CHANGETEMPO_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Change Tempo") }
class EffectChangeTempo final : public EffectSoundTouch
{
@ -38,9 +38,9 @@ public:
EffectChangeTempo();
virtual ~EffectChangeTempo();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -73,9 +73,9 @@ EffectClickRemoval::~EffectClickRemoval()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectClickRemoval::GetSymbol()
ComponentInterfaceSymbol EffectClickRemoval::GetSymbol()
{
return CLICKREMOVAL_PLUGIN_SYMBOL;
}

View File

@ -26,7 +26,7 @@
class Envelope;
class ShuttleGui;
#define CLICKREMOVAL_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Click Removal") }
#define CLICKREMOVAL_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Click Removal") }
class EffectClickRemoval final : public Effect
{
@ -34,9 +34,9 @@ public:
EffectClickRemoval();
virtual ~EffectClickRemoval();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -94,9 +94,9 @@ EffectCompressor::~EffectCompressor()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectCompressor::GetSymbol()
ComponentInterfaceSymbol EffectCompressor::GetSymbol()
{
return COMPRESSOR_PLUGIN_SYMBOL;
}

View File

@ -27,7 +27,7 @@
class EffectCompressorPanel;
class ShuttleGui;
#define COMPRESSOR_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Compressor") }
#define COMPRESSOR_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Compressor") }
class EffectCompressor final : public EffectTwoPassSimpleMono
{
@ -36,9 +36,9 @@ public:
EffectCompressor();
virtual ~EffectCompressor();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -57,7 +57,7 @@ enum kTableType
nTableTypes
};
static const IdentInterfaceSymbol kTableTypeStrings[nTableTypes] =
static const ComponentInterfaceSymbol kTableTypeStrings[nTableTypes] =
{
{ XO("Hard Clipping") },
{ XO("Soft Clipping") },
@ -188,9 +188,9 @@ EffectDistortion::~EffectDistortion()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectDistortion::GetSymbol()
ComponentInterfaceSymbol EffectDistortion::GetSymbol()
{
return DISTORTION_PLUGIN_SYMBOL;
}

View File

@ -23,7 +23,7 @@
class ShuttleGui;
#define DISTORTION_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Distortion") }
#define DISTORTION_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Distortion") }
#define STEPS 1024 // number of +ve or -ve steps in lookup tabe
#define TABLESIZE 2049 // size of lookup table (steps * 2 + 1)
@ -62,9 +62,9 @@ public:
int mRepeats;
};
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -89,9 +89,9 @@ EffectDtmf::~EffectDtmf()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectDtmf::GetSymbol()
ComponentInterfaceSymbol EffectDtmf::GetSymbol()
{
return DTMFTONES_PLUGIN_SYMBOL;
}

View File

@ -25,7 +25,7 @@
class ShuttleGui;
#define DTMFTONES_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("DTMF Tones") }
#define DTMFTONES_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("DTMF Tones") }
class EffectDtmf final : public Effect
{
@ -33,9 +33,9 @@ public:
EffectDtmf();
virtual ~EffectDtmf();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -50,9 +50,9 @@ EffectEcho::~EffectEcho()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectEcho::GetSymbol()
ComponentInterfaceSymbol EffectEcho::GetSymbol()
{
return ECHO_PLUGIN_SYMBOL;
}

View File

@ -21,7 +21,7 @@
class ShuttleGui;
#define ECHO_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Echo") }
#define ECHO_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Echo") }
class EffectEcho final : public Effect
{
@ -29,9 +29,9 @@ public:
EffectEcho();
virtual ~EffectEcho();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -168,7 +168,7 @@ wxString Effect::GetPath()
return BUILTIN_EFFECT_PREFIX + GetSymbol().Internal();
}
IdentInterfaceSymbol Effect::GetSymbol()
ComponentInterfaceSymbol Effect::GetSymbol()
{
if (mClient)
{
@ -178,7 +178,7 @@ IdentInterfaceSymbol Effect::GetSymbol()
return {};
}
IdentInterfaceSymbol Effect::GetVendor()
ComponentInterfaceSymbol Effect::GetVendor()
{
if (mClient)
{
@ -208,7 +208,7 @@ wxString Effect::GetDescription()
return wxEmptyString;
}
IdentInterfaceSymbol Effect::GetFamilyId()
ComponentInterfaceSymbol Effect::GetFamilyId()
{
if (mClient)
{

View File

@ -76,20 +76,20 @@ class AUDACITY_DLL_API Effect /* not final */ : public wxEvtHandler,
Effect();
virtual ~Effect();
// IdentInterface implementation
// ComponentInterface implementation
wxString GetPath() override;
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
IdentInterfaceSymbol GetVendor() override;
ComponentInterfaceSymbol GetVendor() override;
wxString GetVersion() override;
wxString GetDescription() override;
// EffectDefinitionInterface implementation
EffectType GetType() override;
IdentInterfaceSymbol GetFamilyId() override;
ComponentInterfaceSymbol GetFamilyId() override;
bool IsInteractive() override;
bool IsDefault() override;
bool IsLegacy() override;

View File

@ -142,7 +142,7 @@ bool EffectManager::DoAudacityCommand(const PluginID & ID,
return res;
}
IdentInterfaceSymbol EffectManager::GetCommandSymbol(const PluginID & ID)
ComponentInterfaceSymbol EffectManager::GetCommandSymbol(const PluginID & ID)
{
return PluginManager::Get().GetSymbol(ID);
}
@ -231,7 +231,7 @@ wxString EffectManager::GetCommandTip(const PluginID & ID)
void EffectManager::GetCommandDefinition(const PluginID & ID, const CommandContext & context, int flags)
{
ParamsInterface *command;
ComponentInterface *command;
command = GetEffect(ID);
if( !command )
command = GetAudacityCommand( ID );

View File

@ -89,7 +89,7 @@ public:
bool shouldPrompt = true );
// Renamed from 'Effect' to 'Command' prior to moving out of this class.
IdentInterfaceSymbol GetCommandSymbol(const PluginID & ID);
ComponentInterfaceSymbol GetCommandSymbol(const PluginID & ID);
wxString GetCommandName(const PluginID & ID); // translated
wxString GetCommandIdentifier(const PluginID & ID);
wxString GetCommandDescription(const PluginID & ID);

View File

@ -144,7 +144,7 @@ enum kInterpolations
#define EQCURVES_REVISION 0
#define UPDATE_ALL 0 // 0 = merge NEW presets only, 1 = Update all factory presets.
static const IdentInterfaceSymbol kInterpStrings[nInterpolations] =
static const ComponentInterfaceSymbol kInterpStrings[nInterpolations] =
{
// These are acceptable dual purpose internal/visible names
@ -280,9 +280,9 @@ EffectEqualization::~EffectEqualization()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectEqualization::GetSymbol()
ComponentInterfaceSymbol EffectEqualization::GetSymbol()
{
return EQUALIZATION_PLUGIN_SYMBOL;
}

View File

@ -43,7 +43,7 @@
#include "../RealFFTf.h"
#include "../SampleFormat.h"
#define EQUALIZATION_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Equalization") }
#define EQUALIZATION_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Equalization") }
class Envelope;
@ -103,9 +103,9 @@ public:
EffectEqualization();
virtual ~EffectEqualization();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -28,9 +28,9 @@ EffectFade::~EffectFade()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectFade::GetSymbol()
ComponentInterfaceSymbol EffectFade::GetSymbol()
{
return mFadeIn
? FADEIN_PLUGIN_SYMBOL

View File

@ -15,8 +15,8 @@
#include "Effect.h"
#define FADEIN_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Fade In") }
#define FADEOUT_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Fade Out") }
#define FADEIN_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Fade In") }
#define FADEOUT_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Fade Out") }
class EffectFade final : public Effect
{
@ -24,9 +24,9 @@ public:
EffectFade(bool fadeIn = false);
virtual ~EffectFade();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
// EffectDefinitionInterface implementation

View File

@ -50,9 +50,9 @@ EffectFindClipping::~EffectFindClipping()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectFindClipping::GetSymbol()
ComponentInterfaceSymbol EffectFindClipping::GetSymbol()
{
return FINDCLIPPING_PLUGIN_SYMBOL;
}

View File

@ -20,7 +20,7 @@ class LabelTrack;
#include "Effect.h"
#define FINDCLIPPING_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Find Clipping") }
#define FINDCLIPPING_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Find Clipping") }
class EffectFindClipping final : public Effect
{
@ -28,9 +28,9 @@ public:
EffectFindClipping();
virtual ~EffectFindClipping();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -28,9 +28,9 @@ EffectInvert::~EffectInvert()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectInvert::GetSymbol()
ComponentInterfaceSymbol EffectInvert::GetSymbol()
{
return INVERT_PLUGIN_SYMBOL;
}

View File

@ -17,7 +17,7 @@
#include "Effect.h"
#define INVERT_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Invert") }
#define INVERT_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Invert") }
class EffectInvert final : public Effect
{
@ -25,9 +25,9 @@ public:
EffectInvert();
virtual ~EffectInvert();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
// EffectDefinitionInterface implementation

View File

@ -233,7 +233,7 @@ BuiltinEffectsModule::~BuiltinEffectsModule()
}
// ============================================================================
// IdentInterface implementation
// ComponentInterface implementation
// ============================================================================
wxString BuiltinEffectsModule::GetPath()
@ -241,12 +241,12 @@ wxString BuiltinEffectsModule::GetPath()
return mPath;
}
IdentInterfaceSymbol BuiltinEffectsModule::GetSymbol()
ComponentInterfaceSymbol BuiltinEffectsModule::GetSymbol()
{
return XO("Builtin Effects");
}
IdentInterfaceSymbol BuiltinEffectsModule::GetVendor()
ComponentInterfaceSymbol BuiltinEffectsModule::GetVendor()
{
return XO("The Audacity Team");
}
@ -338,14 +338,14 @@ bool BuiltinEffectsModule::IsPluginValid(const wxString & path, bool bFast)
return mNames.Index(path) != wxNOT_FOUND;
}
IdentInterface *BuiltinEffectsModule::CreateInstance(const wxString & path)
ComponentInterface *BuiltinEffectsModule::CreateInstance(const wxString & path)
{
// Acquires a resource for the application.
// Safety of this depends on complementary calls to DeleteInstance on the module manager side.
return Instantiate(path).release();
}
void BuiltinEffectsModule::DeleteInstance(IdentInterface *instance)
void BuiltinEffectsModule::DeleteInstance(ComponentInterface *instance)
{
// Releases the resource.
std::unique_ptr < Effect > {

View File

@ -27,11 +27,11 @@ public:
BuiltinEffectsModule(ModuleManagerInterface *moduleManager, const wxString *path);
virtual ~BuiltinEffectsModule();
// IdentInterface implementation
// ComponentInterface implementation
wxString GetPath() override;
IdentInterfaceSymbol GetSymbol() override;
IdentInterfaceSymbol GetVendor() override;
ComponentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetVendor() override;
wxString GetVersion() override;
wxString GetDescription() override;
@ -52,8 +52,8 @@ public:
bool IsPluginValid(const wxString & path, bool bFast) override;
IdentInterface *CreateInstance(const wxString & path) override;
void DeleteInstance(IdentInterface *instance) override;
ComponentInterface *CreateInstance(const wxString & path) override;
void DeleteInstance(ComponentInterface *instance) override;
private:
// BuiltinEffectModule implementation

View File

@ -35,7 +35,7 @@ enum kTypes
nTypes
};
static const IdentInterfaceSymbol kTypeStrings[nTypes] =
static const ComponentInterfaceSymbol kTypeStrings[nTypes] =
{
// These are acceptable dual purpose internal/visible names
{ XO("White") },
@ -67,9 +67,9 @@ EffectNoise::~EffectNoise()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectNoise::GetSymbol()
ComponentInterfaceSymbol EffectNoise::GetSymbol()
{
return NOISE_PLUGIN_SYMBOL;
}

View File

@ -21,7 +21,7 @@
class ShuttleGui;
#define NOISE_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Noise") }
#define NOISE_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Noise") }
class EffectNoise final : public Effect
{
@ -29,9 +29,9 @@ public:
EffectNoise();
virtual ~EffectNoise();
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
wxString ManualPage() override;

View File

@ -427,9 +427,9 @@ EffectNoiseReduction::~EffectNoiseReduction()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectNoiseReduction::GetSymbol()
ComponentInterfaceSymbol EffectNoiseReduction::GetSymbol()
{
return NOISEREDUCTION_PLUGIN_SYMBOL;
}

View File

@ -17,7 +17,7 @@
#include "../MemoryX.h"
#define NOISEREDUCTION_PLUGIN_SYMBOL IdentInterfaceSymbol{ XO("Noise Reduction") }
#define NOISEREDUCTION_PLUGIN_SYMBOL ComponentInterfaceSymbol{ XO("Noise Reduction") }
class EffectNoiseReduction final : public Effect {
public:
@ -27,9 +27,9 @@ public:
using Effect::TrackProgress;
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol GetSymbol() override;
ComponentInterfaceSymbol GetSymbol() override;
wxString GetDescription() override;
// EffectDefinitionInterface implementation

View File

@ -108,9 +108,9 @@ EffectNoiseRemoval::~EffectNoiseRemoval()
{
}
// IdentInterface implementation
// ComponentInterface implementation
IdentInterfaceSymbol EffectNoiseRemoval::GetSymbol()
ComponentInterfaceSymbol EffectNoiseRemoval::GetSymbol()
{
return XO("Noise Removal");
}

Some files were not shown because too many files have changed in this diff Show More