diff --git a/extras/Introjucer/Source/Project/jucer_ModulesPanel.h b/extras/Introjucer/Source/Project/jucer_ModulesPanel.h index a6a95fb3d0..5362ef3bd9 100644 --- a/extras/Introjucer/Source/Project/jucer_ModulesPanel.h +++ b/extras/Introjucer/Source/Project/jucer_ModulesPanel.h @@ -237,7 +237,7 @@ public: if (module != nullptr) { - props.add (new ModuleInfoComponent (project, moduleList, moduleID)); + props.add (new ModuleInfoComponent (moduleList, moduleID)); if (project.isModuleEnabled (moduleID)) { @@ -293,8 +293,8 @@ public: class ModuleInfoComponent : public PropertyComponent { public: - ModuleInfoComponent (Project& p, ModuleList& list, const String& modID) - : PropertyComponent ("Module", 100), project (p), moduleList (list), moduleID (modID) + ModuleInfoComponent (ModuleList& list, const String& modID) + : PropertyComponent ("Module", 100), moduleList (list), moduleID (modID) { } @@ -322,7 +322,6 @@ public: } private: - Project& project; ModuleList& moduleList; String moduleID; diff --git a/extras/JuceDemo/Source/demos/ThreadingDemo.cpp b/extras/JuceDemo/Source/demos/ThreadingDemo.cpp index 027d124015..0586d3bfbb 100644 --- a/extras/JuceDemo/Source/demos/ThreadingDemo.cpp +++ b/extras/JuceDemo/Source/demos/ThreadingDemo.cpp @@ -105,7 +105,7 @@ public: } private: - float x, y, size, dx, dy, w, h, parentWidth, parentHeight; + float x, y, size, dx, dy, parentWidth, parentHeight; float innerX, innerY; Colour colour; Thread::ThreadID threadId; diff --git a/modules/juce_audio_utils/gui/juce_AudioDeviceSelectorComponent.cpp b/modules/juce_audio_utils/gui/juce_AudioDeviceSelectorComponent.cpp index 26b330d8e1..70e115cd23 100644 --- a/modules/juce_audio_utils/gui/juce_AudioDeviceSelectorComponent.cpp +++ b/modules/juce_audio_utils/gui/juce_AudioDeviceSelectorComponent.cpp @@ -69,15 +69,11 @@ class AudioDeviceSelectorComponent::MidiInputSelectorComponentListBox : public private ListBoxModel { public: - MidiInputSelectorComponentListBox (AudioDeviceManager& deviceManager_, - const String& noItemsMessage_, - const int minNumber_, - const int maxNumber_) + MidiInputSelectorComponentListBox (AudioDeviceManager& dm, + const String& noItemsMessage_) : ListBox (String::empty, nullptr), - deviceManager (deviceManager_), - noItemsMessage (noItemsMessage_), - minNumber (minNumber_), - maxNumber (maxNumber_) + deviceManager (dm), + noItemsMessage (noItemsMessage_) { items = MidiInput::getDevices(); @@ -162,7 +158,6 @@ private: AudioDeviceManager& deviceManager; const String noItemsMessage; StringArray items; - int minNumber, maxNumber; void flipEnablement (const int row) { @@ -917,7 +912,7 @@ private: //============================================================================== -AudioDeviceSelectorComponent::AudioDeviceSelectorComponent (AudioDeviceManager& deviceManager_, +AudioDeviceSelectorComponent::AudioDeviceSelectorComponent (AudioDeviceManager& dm, const int minInputChannels_, const int maxInputChannels_, const int minOutputChannels_, @@ -926,7 +921,7 @@ AudioDeviceSelectorComponent::AudioDeviceSelectorComponent (AudioDeviceManager& const bool showMidiOutputSelector, const bool showChannelsAsStereoPairs_, const bool hideAdvancedOptionsWithButton_) - : deviceManager (deviceManager_), + : deviceManager (dm), minOutputChannels (minOutputChannels_), maxOutputChannels (maxOutputChannels_), minInputChannels (minInputChannels_), @@ -937,7 +932,7 @@ AudioDeviceSelectorComponent::AudioDeviceSelectorComponent (AudioDeviceManager& jassert (minOutputChannels >= 0 && minOutputChannels <= maxOutputChannels); jassert (minInputChannels >= 0 && minInputChannels <= maxInputChannels); - const OwnedArray& types = deviceManager_.getAvailableDeviceTypes(); + const OwnedArray& types = deviceManager.getAvailableDeviceTypes(); if (types.size() > 1) { @@ -958,8 +953,7 @@ AudioDeviceSelectorComponent::AudioDeviceSelectorComponent (AudioDeviceManager& { addAndMakeVisible (midiInputsList = new MidiInputSelectorComponentListBox (deviceManager, - "(" + TRANS("No MIDI inputs available") + ")", - 0, 0)); + "(" + TRANS("No MIDI inputs available") + ")")); midiInputsLabel = new Label (String::empty, TRANS ("Active MIDI inputs:")); midiInputsLabel->setJustificationType (Justification::topRight); @@ -985,7 +979,7 @@ AudioDeviceSelectorComponent::AudioDeviceSelectorComponent (AudioDeviceManager& midiOutputLabel = nullptr; } - deviceManager_.addChangeListener (this); + deviceManager.addChangeListener (this); updateAllControls(); } diff --git a/modules/juce_graphics/geometry/juce_EdgeTable.cpp b/modules/juce_graphics/geometry/juce_EdgeTable.cpp index c2f792ee1e..918ccd4240 100644 --- a/modules/juce_graphics/geometry/juce_EdgeTable.cpp +++ b/modules/juce_graphics/geometry/juce_EdgeTable.cpp @@ -417,7 +417,7 @@ void EdgeTable::intersectWithEdgeTableLine (const int y, const int* otherLine) if (dest[0] == 0) return; - int otherNumPoints = *otherLine; + const int otherNumPoints = *otherLine; if (otherNumPoints == 0) { *dest = 0; @@ -522,17 +522,6 @@ void EdgeTable::intersectWithEdgeTableLine (const int y, const int* otherLine) } dest[0] = destTotal; - -#if JUCE_DEBUG - int last = std::numeric_limits::min(); - for (int i = 0; i < dest[0]; ++i) - { - jassert (dest[i * 2 + 1] > last); - last = dest[i * 2 + 1]; - } - - jassert (dest [dest[0] * 2] == 0); -#endif } void EdgeTable::clipEdgeTableLineToRange (int* dest, const int x1, const int x2) noexcept @@ -656,13 +645,12 @@ void EdgeTable::clipToEdgeTable (const EdgeTable& other) if (clipped.getRight() < bounds.getRight()) bounds.setRight (clipped.getRight()); - int i = 0; - for (i = top; --i >= 0;) + for (int i = 0; i < top; ++i) table [lineStrideElements * i] = 0; const int* otherLine = other.table + other.lineStrideElements * (clipped.getY() - other.bounds.getY()); - for (i = top; i < bottom; ++i) + for (int i = top; i < bottom; ++i) { intersectWithEdgeTableLine (i, otherLine); otherLine += other.lineStrideElements; diff --git a/modules/juce_gui_basics/widgets/juce_ComboBox.h b/modules/juce_gui_basics/widgets/juce_ComboBox.h index c1de11184e..89cbfbc2ae 100644 --- a/modules/juce_gui_basics/widgets/juce_ComboBox.h +++ b/modules/juce_gui_basics/widgets/juce_ComboBox.h @@ -396,7 +396,7 @@ private: OwnedArray items; Value currentId; int lastCurrentId; - bool isButtonDown, separatorPending, menuActive, textIsCustom; + bool isButtonDown, separatorPending, menuActive; ListenerList listeners; ScopedPointer