Browse Source

Fixed some more Android compiler warnings

tags/2021-05-28
Tom Poole 6 years ago
parent
commit
8f84192c9b
12 changed files with 37 additions and 36 deletions
  1. +1
    -1
      modules/juce_audio_basics/mpe/juce_MPESynthesiser.h
  2. +4
    -4
      modules/juce_audio_processors/utilities/juce_AudioParameterBool.h
  3. +4
    -4
      modules/juce_audio_processors/utilities/juce_AudioParameterChoice.h
  4. +7
    -7
      modules/juce_audio_processors/utilities/juce_AudioParameterFloat.h
  5. +4
    -4
      modules/juce_audio_processors/utilities/juce_AudioParameterInt.h
  6. +3
    -3
      modules/juce_audio_processors/utilities/juce_AudioProcessorParameterWithID.h
  7. +2
    -2
      modules/juce_audio_processors/utilities/juce_AudioProcessorValueTreeState.h
  8. +3
    -3
      modules/juce_audio_processors/utilities/juce_RangedAudioParameter.h
  9. +1
    -0
      modules/juce_box2d/juce_box2d.h
  10. +1
    -1
      modules/juce_core/files/juce_WildcardFileFilter.h
  11. +3
    -3
      modules/juce_graphics/native/juce_android_Fonts.cpp
  12. +4
    -4
      modules/juce_video/native/juce_android_CameraDevice.h

+ 1
- 1
modules/juce_audio_basics/mpe/juce_MPESynthesiser.h View File

@@ -69,7 +69,7 @@ public:
@see MPESynthesiserBase, MPEInstrument @see MPESynthesiserBase, MPEInstrument
*/ */
MPESynthesiser (MPEInstrument* instrument);
MPESynthesiser (MPEInstrument* instrumentToUse);
/** Destructor. */ /** Destructor. */
~MPESynthesiser() override; ~MPESynthesiser() override;


+ 4
- 4
modules/juce_audio_processors/utilities/juce_AudioParameterBool.h View File

@@ -40,9 +40,9 @@ public:
/** Creates a AudioParameterBool with the specified parameters. /** Creates a AudioParameterBool with the specified parameters.
@param parameterID The parameter ID to use @param parameterID The parameter ID to use
@param name The parameter name to use
@param parameterName The parameter name to use
@param defaultValue The default value @param defaultValue The default value
@param label An optional label for the parameter's value
@param parameterLabel An optional label for the parameter's value
@param stringFromBool An optional lambda function that converts a bool @param stringFromBool An optional lambda function that converts a bool
value to a string with a maximum length. This may value to a string with a maximum length. This may
be used by hosts to display the parameter's value. be used by hosts to display the parameter's value.
@@ -50,8 +50,8 @@ public:
converts it into a bool value. Some hosts use this converts it into a bool value. Some hosts use this
to allow users to type in parameter values. to allow users to type in parameter values.
*/ */
AudioParameterBool (const String& parameterID, const String& name, bool defaultValue,
const String& label = String(),
AudioParameterBool (const String& parameterID, const String& parameterName, bool defaultValue,
const String& parameterLabel = String(),
std::function<String(bool value, int maximumStringLength)> stringFromBool = nullptr, std::function<String(bool value, int maximumStringLength)> stringFromBool = nullptr,
std::function<bool(const String& text)> boolFromString = nullptr); std::function<bool(const String& text)> boolFromString = nullptr);


+ 4
- 4
modules/juce_audio_processors/utilities/juce_AudioParameterChoice.h View File

@@ -41,10 +41,10 @@ public:
/** Creates a AudioParameterChoice with the specified parameters. /** Creates a AudioParameterChoice with the specified parameters.
@param parameterID The parameter ID to use @param parameterID The parameter ID to use
@param name The parameter name to use
@param parameterName The parameter name to use
@param choices The set of choices to use @param choices The set of choices to use
@param defaultItemIndex The index of the default choice @param defaultItemIndex The index of the default choice
@param label An optional label for the parameter's value
@param parameterLabel An optional label for the parameter's value
@param stringFromIndex An optional lambda function that converts a choice @param stringFromIndex An optional lambda function that converts a choice
index to a string with a maximum length. This may index to a string with a maximum length. This may
be used by hosts to display the parameter's value. be used by hosts to display the parameter's value.
@@ -52,10 +52,10 @@ public:
converts it into a choice index. Some hosts use this converts it into a choice index. Some hosts use this
to allow users to type in parameter values. to allow users to type in parameter values.
*/ */
AudioParameterChoice (const String& parameterID, const String& name,
AudioParameterChoice (const String& parameterID, const String& parameterName,
const StringArray& choices, const StringArray& choices,
int defaultItemIndex, int defaultItemIndex,
const String& label = String(),
const String& parameterLabel = String(),
std::function<String(int index, int maximumStringLength)> stringFromIndex = nullptr, std::function<String(int index, int maximumStringLength)> stringFromIndex = nullptr,
std::function<int(const String& text)> indexFromString = nullptr); std::function<int(const String& text)> indexFromString = nullptr);


+ 7
- 7
modules/juce_audio_processors/utilities/juce_AudioParameterFloat.h View File

@@ -41,11 +41,11 @@ public:
/** Creates a AudioParameterFloat with the specified parameters. /** Creates a AudioParameterFloat with the specified parameters.
@param parameterID The parameter ID to use @param parameterID The parameter ID to use
@param name The parameter name to use
@param parameterName The parameter name to use
@param normalisableRange The NormalisableRange to use @param normalisableRange The NormalisableRange to use
@param defaultValue The non-normalised default value @param defaultValue The non-normalised default value
@param label An optional label for the parameter's value
@param category An optional parameter category
@param parameterLabel An optional label for the parameter's value
@param parameterCategory An optional parameter category
@param stringFromValue An optional lambda function that converts a non-normalised @param stringFromValue An optional lambda function that converts a non-normalised
value to a string with a maximum length. This may value to a string with a maximum length. This may
be used by hosts to display the parameter's value. be used by hosts to display the parameter's value.
@@ -54,11 +54,11 @@ public:
this to allow users to type in parameter values. this to allow users to type in parameter values.
*/ */
AudioParameterFloat (const String& parameterID, AudioParameterFloat (const String& parameterID,
const String& name,
const String& parameterName,
NormalisableRange<float> normalisableRange, NormalisableRange<float> normalisableRange,
float defaultValue, float defaultValue,
const String& label = String(),
Category category = AudioProcessorParameter::genericParameter,
const String& parameterLabel = String(),
Category parameterCategory = AudioProcessorParameter::genericParameter,
std::function<String(float value, int maximumStringLength)> stringFromValue = nullptr, std::function<String(float value, int maximumStringLength)> stringFromValue = nullptr,
std::function<float(const String& text)> valueFromString = nullptr); std::function<float(const String& text)> valueFromString = nullptr);
@@ -68,7 +68,7 @@ public:
constructor and provide a NormalisableRange. constructor and provide a NormalisableRange.
*/ */
AudioParameterFloat (String parameterID, AudioParameterFloat (String parameterID,
String name,
String parameterName,
float minValue, float minValue,
float maxValue, float maxValue,
float defaultValue); float defaultValue);


+ 4
- 4
modules/juce_audio_processors/utilities/juce_AudioParameterInt.h View File

@@ -41,11 +41,11 @@ public:
/** Creates a AudioParameterInt with the specified parameters. /** Creates a AudioParameterInt with the specified parameters.
@param parameterID The parameter ID to use @param parameterID The parameter ID to use
@param name The parameter name to use
@param parameterName The parameter name to use
@param minValue The minimum parameter value @param minValue The minimum parameter value
@param maxValue The maximum parameter value @param maxValue The maximum parameter value
@param defaultValue The default value @param defaultValue The default value
@param label An optional label for the parameter's value
@param parameterLabel An optional label for the parameter's value
@param stringFromInt An optional lambda function that converts a int @param stringFromInt An optional lambda function that converts a int
value to a string with a maximum length. This may value to a string with a maximum length. This may
be used by hosts to display the parameter's value. be used by hosts to display the parameter's value.
@@ -53,10 +53,10 @@ public:
and converts it into an int. Some hosts use this and converts it into an int. Some hosts use this
to allow users to type in parameter values. to allow users to type in parameter values.
*/ */
AudioParameterInt (const String& parameterID, const String& name,
AudioParameterInt (const String& parameterID, const String& parameterName,
int minValue, int maxValue, int minValue, int maxValue,
int defaultValue, int defaultValue,
const String& label = String(),
const String& parameterLabel = String(),
std::function<String(int value, int maximumStringLength)> stringFromInt = nullptr, std::function<String(int value, int maximumStringLength)> stringFromInt = nullptr,
std::function<int(const String& text)> intFromString = nullptr); std::function<int(const String& text)> intFromString = nullptr);


+ 3
- 3
modules/juce_audio_processors/utilities/juce_AudioProcessorParameterWithID.h View File

@@ -41,9 +41,9 @@ public:
constant for its lifetime. constant for its lifetime.
*/ */
AudioProcessorParameterWithID (const String& parameterID, AudioProcessorParameterWithID (const String& parameterID,
const String& name,
const String& label = String(),
Category category = AudioProcessorParameter::genericParameter);
const String& parameterName,
const String& parameterLabel = String(),
Category parameterCategory = AudioProcessorParameter::genericParameter);
/** Destructor. */ /** Destructor. */
~AudioProcessorParameterWithID() override; ~AudioProcessorParameterWithID() override;


+ 2
- 2
modules/juce_audio_processors/utilities/juce_AudioProcessorValueTreeState.h View File

@@ -267,7 +267,7 @@ public:
bool isMetaParameter = false, bool isMetaParameter = false,
bool isAutomatableParameter = true, bool isAutomatableParameter = true,
bool isDiscrete = false, bool isDiscrete = false,
AudioProcessorParameter::Category category = AudioProcessorParameter::genericParameter,
AudioProcessorParameter::Category parameterCategory = AudioProcessorParameter::genericParameter,
bool isBoolean = false)); bool isBoolean = false));
/** This function adds a parameter to the attached AudioProcessor and that parameter will /** This function adds a parameter to the attached AudioProcessor and that parameter will
@@ -402,7 +402,7 @@ public:
bool isMetaParameter = false, bool isMetaParameter = false,
bool isAutomatableParameter = true, bool isAutomatableParameter = true,
bool isDiscrete = false, bool isDiscrete = false,
AudioProcessorParameter::Category category = AudioProcessorParameter::genericParameter,
AudioProcessorParameter::Category parameterCategory = AudioProcessorParameter::genericParameter,
bool isBoolean = false); bool isBoolean = false);
float getDefaultValue() const override; float getDefaultValue() const override;


+ 3
- 3
modules/juce_audio_processors/utilities/juce_RangedAudioParameter.h View File

@@ -41,9 +41,9 @@ public:
constant for its lifetime. constant for its lifetime.
*/ */
RangedAudioParameter (const String& parameterID, RangedAudioParameter (const String& parameterID,
const String& name,
const String& label = {},
Category category = AudioProcessorParameter::genericParameter);
const String& parameterName,
const String& parameterLabel = {},
Category parameterCategory = AudioProcessorParameter::genericParameter);
/** Returns the range of values that the parameter can take. */ /** Returns the range of values that the parameter can take. */
virtual const NormalisableRange<float>& getNormalisableRange() const = 0; virtual const NormalisableRange<float>& getNormalisableRange() const = 0;


+ 1
- 0
modules/juce_box2d/juce_box2d.h View File

@@ -57,6 +57,7 @@
#ifdef JUCE_CLANG #ifdef JUCE_CLANG
#pragma clang diagnostic push #pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wconversion" #pragma clang diagnostic ignored "-Wconversion"
#pragma clang diagnostic ignored "-Wshadow-field"
#if __has_warning("-Wzero-as-null-pointer-constant") #if __has_warning("-Wzero-as-null-pointer-constant")
#pragma clang diagnostic ignored "-Wzero-as-null-pointer-constant" #pragma clang diagnostic ignored "-Wzero-as-null-pointer-constant"
#endif #endif


+ 1
- 1
modules/juce_core/files/juce_WildcardFileFilter.h View File

@@ -54,7 +54,7 @@ public:
*/ */
WildcardFileFilter (const String& fileWildcardPatterns, WildcardFileFilter (const String& fileWildcardPatterns,
const String& directoryWildcardPatterns, const String& directoryWildcardPatterns,
const String& description);
const String& filterDescription);
/** Destructor. */ /** Destructor. */
~WildcardFileFilter() override; ~WildcardFileFilter() override;


+ 3
- 3
modules/juce_graphics/native/juce_android_Fonts.cpp View File

@@ -425,12 +425,12 @@ private:
return file; return file;
} }
static File getFontFile (const String& family, const String& style)
static File getFontFile (const String& family, const String& fontStyle)
{ {
String path ("/system/fonts/" + family); String path ("/system/fonts/" + family);
if (style.isNotEmpty())
path << '-' << style;
if (fontStyle.isNotEmpty())
path << '-' << fontStyle;
return File (path + ".ttf"); return File (path + ".ttf");
} }


+ 4
- 4
modules/juce_video/native/juce_android_CameraDevice.h View File

@@ -2647,10 +2647,10 @@ private:
struct CaptureSessionPreviewMode : public CaptureSessionMode<CaptureSessionPreviewMode> struct CaptureSessionPreviewMode : public CaptureSessionMode<CaptureSessionPreviewMode>
{ {
CaptureSessionPreviewMode (Pimpl& ownerToUse, ScopedCameraDevice& cameraDeviceToUse, GlobalRef& handlerToUse, CaptureSessionPreviewMode (Pimpl& ownerToUse, ScopedCameraDevice& cameraDeviceToUse, GlobalRef& handlerToUse,
PreviewDisplay& pd, ImageReader& ir, int cameraSensorOrientation,
PreviewDisplay& pd, ImageReader& ir, int sensorOrientation,
int cameraLensFacingToUse, StreamConfigurationMap& streamConfigurationMapToUse) int cameraLensFacingToUse, StreamConfigurationMap& streamConfigurationMapToUse)
: CaptureSessionMode<CaptureSessionPreviewMode> (ownerToUse, cameraDeviceToUse, handlerToUse, pd, : CaptureSessionMode<CaptureSessionPreviewMode> (ownerToUse, cameraDeviceToUse, handlerToUse, pd,
cameraSensorOrientation, cameraLensFacingToUse, streamConfigurationMapToUse),
sensorOrientation, cameraLensFacingToUse, streamConfigurationMapToUse),
imageReader (ir) imageReader (ir)
{ {
} }
@@ -2712,10 +2712,10 @@ private:
struct CaptureSessionVideoRecordingMode : public CaptureSessionMode<CaptureSessionVideoRecordingMode> struct CaptureSessionVideoRecordingMode : public CaptureSessionMode<CaptureSessionVideoRecordingMode>
{ {
CaptureSessionVideoRecordingMode (Pimpl& ownerToUse, ScopedCameraDevice& cameraDeviceToUse, GlobalRef& handlerToUse, CaptureSessionVideoRecordingMode (Pimpl& ownerToUse, ScopedCameraDevice& cameraDeviceToUse, GlobalRef& handlerToUse,
PreviewDisplay& pd, MediaRecorder& mr, int cameraSensorOrientation,
PreviewDisplay& pd, MediaRecorder& mr, int sensorOrientation,
int cameraLensFacingToUse, StreamConfigurationMap& streamConfigurationMapToUse) int cameraLensFacingToUse, StreamConfigurationMap& streamConfigurationMapToUse)
: CaptureSessionMode<CaptureSessionVideoRecordingMode> (ownerToUse, cameraDeviceToUse, handlerToUse, pd, : CaptureSessionMode<CaptureSessionVideoRecordingMode> (ownerToUse, cameraDeviceToUse, handlerToUse, pd,
cameraSensorOrientation, cameraLensFacingToUse, streamConfigurationMapToUse),
sensorOrientation, cameraLensFacingToUse, streamConfigurationMapToUse),
mediaRecorder (mr) mediaRecorder (mr)
{ {
} }


Loading…
Cancel
Save