Skip to content

Commit bd4e558

Browse files
committed
Support JUCE 8.0.11 (addDefaultFormats is removed)
1 parent 0cd2c3b commit bd4e558

3 files changed

Lines changed: 12 additions & 0 deletions

File tree

Source/CommandLine.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,11 @@ namespace
241241
bool isPluginArgument (juce::String arg)
242242
{
243243
juce::AudioPluginFormatManager formatManager;
244+
#if JUCE_VERSION >= 0x08000B
244245
juce::addDefaultFormatsToManager (formatManager);
246+
#else
247+
formatManager.addDefaultFormats();
248+
#endif
245249

246250
for (auto format : formatManager.getFormats())
247251
if (format->fileMightContainThisPluginType (arg))

Source/MainComponent.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,11 @@ namespace
331331
MainComponent::MainComponent (Validator& v)
332332
: validator (v)
333333
{
334+
#if JUCE_VERSION >= 0x08000B
334335
juce::addDefaultFormatsToManager (formatManager);
336+
#else
337+
formatManager.addDefaultFormats();
338+
#endif
335339

336340
menuBar.setModel (this);
337341
addAndMakeVisible (menuBar);

Source/PluginTests.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,11 @@ PluginTests::PluginTests (const juce::String& fileOrIdentifier, Options opts)
6969
{
7070
jassert (fileOrIdentifier.isNotEmpty());
7171
jassert (juce::isPositiveAndNotGreaterThan (options.strictnessLevel, 10));
72+
#if JUCE_VERSION >= 0x08000B
7273
juce::addDefaultFormatsToManager (formatManager);
74+
#else
75+
formatManager.addDefaultFormats();
76+
#endif
7377
}
7478

7579
PluginTests::PluginTests (const juce::PluginDescription& desc, Options opts)

0 commit comments

Comments
 (0)