mirror of
https://github.com/cookiengineer/audacity
synced 2025-08-02 17:09:26 +02:00
Separate files for PluginRegistrationDialog...
... so that PluginManager can avoid using GUI
This commit is contained in:
parent
710ec976ff
commit
50b384adae
@ -202,6 +202,7 @@ list( APPEND SOURCES
|
|||||||
PlaybackSchedule.h
|
PlaybackSchedule.h
|
||||||
PluginManager.cpp
|
PluginManager.cpp
|
||||||
PluginManager.h
|
PluginManager.h
|
||||||
|
PluginRegistrationDialog.cpp
|
||||||
PluginRegistrationDialog.h
|
PluginRegistrationDialog.h
|
||||||
Prefs.cpp
|
Prefs.cpp
|
||||||
Prefs.h
|
Prefs.h
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -293,8 +293,6 @@ public:
|
|||||||
|
|
||||||
void CheckForUpdates(bool bFast = false);
|
void CheckForUpdates(bool bFast = false);
|
||||||
|
|
||||||
bool ShowManager(wxWindow *parent, EffectType type = EffectTypeNone);
|
|
||||||
|
|
||||||
//! Used only by Nyquist Workbench module
|
//! Used only by Nyquist Workbench module
|
||||||
const PluginID & RegisterPlugin(
|
const PluginID & RegisterPlugin(
|
||||||
std::unique_ptr<EffectDefinitionInterface> effect, PluginType type );
|
std::unique_ptr<EffectDefinitionInterface> effect, PluginType type );
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -6,6 +6,7 @@
|
|||||||
#include "../CommonCommandFlags.h"
|
#include "../CommonCommandFlags.h"
|
||||||
#include "../Menus.h"
|
#include "../Menus.h"
|
||||||
#include "../PluginManager.h"
|
#include "../PluginManager.h"
|
||||||
|
#include "../PluginRegistrationDialog.h"
|
||||||
#include "../Prefs.h"
|
#include "../Prefs.h"
|
||||||
#include "../Project.h"
|
#include "../Project.h"
|
||||||
#include "../ProjectSettings.h"
|
#include "../ProjectSettings.h"
|
||||||
@ -36,10 +37,20 @@ AudacityProject::AttachedWindows::RegisteredFactory sMacrosWindowKey{
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
bool ShowManager(
|
||||||
|
PluginManager &pm, wxWindow *parent, EffectType type)
|
||||||
|
{
|
||||||
|
pm.CheckForUpdates();
|
||||||
|
|
||||||
|
PluginRegistrationDialog dlg(parent, type);
|
||||||
|
return dlg.ShowModal() == wxID_OK;
|
||||||
|
}
|
||||||
|
|
||||||
void DoManagePluginsMenu(AudacityProject &project, EffectType type)
|
void DoManagePluginsMenu(AudacityProject &project, EffectType type)
|
||||||
{
|
{
|
||||||
auto &window = GetProjectFrame( project );
|
auto &window = GetProjectFrame( project );
|
||||||
if (PluginManager::Get().ShowManager(&window, type))
|
auto &pm = PluginManager::Get();
|
||||||
|
if (ShowManager(pm, &window, type))
|
||||||
MenuCreator::RebuildAllMenuBars();
|
MenuCreator::RebuildAllMenuBars();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user