Skip to content

Commit

Permalink
Resurrect RTAS from the dead. Fix compilation.
Browse files Browse the repository at this point in the history
Partial Revert "RTAS:  Fixed some namespacing around include paths" &
"Moved all "namespace juce" declarations from module headers to the individual .h and .cpp source files. This makes life a lot easier for Intellisense and other IDE autocompletion tools"

This partially reverts commits afdb888, eda613c
  • Loading branch information
talaviram committed May 13, 2019
1 parent 8cac1cc commit 574e70c
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 21 deletions.
Expand Up @@ -24,11 +24,13 @@
==============================================================================
*/

#if JucePlugin_Build_RTAS
#pragma once

#include "../../juce_core/system/juce_TargetPlatform.h"
#include "../utility/juce_CheckSettingMacros.h"

#if JucePlugin_Build_RTAS

#include "juce_RTAS_DigiCode_Header.h"

/*
Expand Down
Expand Up @@ -24,11 +24,13 @@
==============================================================================
*/

#if JucePlugin_Build_RTAS
#pragma once

#include "../../juce_core/system/juce_TargetPlatform.h"
#include "../utility/juce_CheckSettingMacros.h"

#if JucePlugin_Build_RTAS

#include "juce_RTAS_DigiCode_Header.h"

#ifdef __clang__
Expand Down
2 changes: 2 additions & 0 deletions modules/juce_audio_plugin_client/RTAS/juce_RTAS_DigiCode3.cpp
Expand Up @@ -24,6 +24,8 @@
==============================================================================
*/

#pragma once

#include "../../juce_core/system/juce_TargetPlatform.h"
#include "../utility/juce_CheckSettingMacros.h"

Expand Down
Expand Up @@ -24,6 +24,8 @@
==============================================================================
*/

#pragma once

#if JucePlugin_Build_RTAS
#ifdef _MSC_VER

Expand Down
12 changes: 3 additions & 9 deletions modules/juce_audio_plugin_client/RTAS/juce_RTAS_MacUtilities.mm
Expand Up @@ -24,11 +24,11 @@
==============================================================================
*/

#if JucePlugin_Build_RTAS

#include "../../juce_core/system/juce_TargetPlatform.h"
#include "../utility/juce_CheckSettingMacros.h"

#if JucePlugin_Build_RTAS

// Horrible carbon-based fix for a cocoa bug, where an NSWindow that wraps a carbon
// window fails to keep its position updated when the user drags the window around..
#define WINDOWPOSITION_BODGE 1
Expand All @@ -38,12 +38,8 @@
#include "../utility/juce_IncludeModuleHeaders.h"
#include "../utility/juce_CarbonVisibility.h"

namespace juce
{

using namespace juce;

//==============================================================================
using namespace juce;
void initialiseMacRTAS();
void initialiseMacRTAS()
{
Expand Down Expand Up @@ -170,6 +166,4 @@ void forwardCurrentKeyEventToHostWindow()
}
}

} // namespace juce

#endif
14 changes: 4 additions & 10 deletions modules/juce_audio_plugin_client/RTAS/juce_RTAS_Wrapper.cpp
Expand Up @@ -24,11 +24,11 @@
==============================================================================
*/

#if JucePlugin_Build_RTAS

#include "../../juce_core/system/juce_TargetPlatform.h"
#include "../utility/juce_CheckSettingMacros.h"

#if JucePlugin_Build_RTAS

#ifdef _MSC_VER
// (this is a workaround for a build problem in VC9)
#define _DO_NOT_DECLARE_INTERLOCKED_INTRINSICS_IN_MEMORY
Expand Down Expand Up @@ -111,11 +111,6 @@

#include "../utility/juce_IncludeModuleHeaders.h"

using namespace juce;

namespace juce
{

#ifdef _MSC_VER
#pragma pack (pop)

Expand Down Expand Up @@ -166,6 +161,7 @@ static const int bypassControlIndex = 1;

static int numInstances = 0;

using namespace juce;
//==============================================================================
class JucePlugInProcess : public CEffectProcessMIDI,
public CEffectProcessRTAS,
Expand Down Expand Up @@ -729,7 +725,7 @@ class JucePlugInProcess : public CEffectProcessMIDI,
auto paramIndex = controlIndex - 2;
auto floatValue = longToFloat (value);

if (auto* param = owner.getParameters()[paramIndex])
if (auto* param = juceFilter->getParameters()[paramIndex])
{
param->setValue (floatValue);
param->sendValueChangedMessageToListeners (floatValue);
Expand Down Expand Up @@ -1314,8 +1310,6 @@ class JucePlugInGroup : public CEffectGroupMIDI

void initialiseMacRTAS();

} // namespace juce

CProcessGroupInterface* CProcessGroup::CreateProcessGroup()
{
#if JUCE_MAC
Expand Down

0 comments on commit 574e70c

Please sign in to comment.