diff --git a/extras/Introjucer/Source/Application/jucer_AppearanceSettings.cpp b/extras/Introjucer/Source/Application/jucer_AppearanceSettings.cpp index f2ed9902cb..f462fdc6ba 100644 --- a/extras/Introjucer/Source/Application/jucer_AppearanceSettings.cpp +++ b/extras/Introjucer/Source/Application/jucer_AppearanceSettings.cpp @@ -537,7 +537,7 @@ IntrojucerLookAndFeel::IntrojucerLookAndFeel() getScrollbarColourForBackground (findColour (mainBackgroundColourId))); } -Colour IntrojucerLookAndFeel::getScrollbarColourForBackground (const Colour& background) +Colour IntrojucerLookAndFeel::getScrollbarColourForBackground (Colour background) { return background.contrasting().withAlpha (0.13f); } diff --git a/extras/Introjucer/Source/Application/jucer_AppearanceSettings.h b/extras/Introjucer/Source/Application/jucer_AppearanceSettings.h index 6bc641d1ab..378cd96db2 100644 --- a/extras/Introjucer/Source/Application/jucer_AppearanceSettings.h +++ b/extras/Introjucer/Source/Application/jucer_AppearanceSettings.h @@ -110,7 +110,7 @@ public: void drawButtonBackground (Graphics& g, Button& button, const Colour& backgroundColour, bool isMouseOverButton, bool isButtonDown); - static Colour getScrollbarColourForBackground (const Colour& background); + static Colour getScrollbarColourForBackground (Colour background); private: Image backgroundTexture; diff --git a/extras/Introjucer/Source/ComponentEditor/properties/jucer_ComponentColourProperty.h b/extras/Introjucer/Source/ComponentEditor/properties/jucer_ComponentColourProperty.h index 3ecb4dda9f..74ec2dea3b 100644 --- a/extras/Introjucer/Source/ComponentEditor/properties/jucer_ComponentColourProperty.h +++ b/extras/Introjucer/Source/ComponentEditor/properties/jucer_ComponentColourProperty.h @@ -80,10 +80,6 @@ public: { } - ~ComponentColourIdProperty() - { - } - //============================================================================== Colour getColour() const { diff --git a/extras/Introjucer/Source/Utility/jucer_CodeHelpers.cpp b/extras/Introjucer/Source/Utility/jucer_CodeHelpers.cpp index 3610f0bfe7..078e75de61 100644 --- a/extras/Introjucer/Source/Utility/jucer_CodeHelpers.cpp +++ b/extras/Introjucer/Source/Utility/jucer_CodeHelpers.cpp @@ -283,7 +283,7 @@ namespace CodeHelpers return value ? "true" : "false"; } - String colourToCode (const Colour& col) + String colourToCode (Colour col) { const Colour colours[] = { diff --git a/extras/Introjucer/Source/Utility/jucer_CodeHelpers.h b/extras/Introjucer/Source/Utility/jucer_CodeHelpers.h index 44891f91a1..c3f9df0ddb 100644 --- a/extras/Introjucer/Source/Utility/jucer_CodeHelpers.h +++ b/extras/Introjucer/Source/Utility/jucer_CodeHelpers.h @@ -41,7 +41,7 @@ namespace CodeHelpers String floatLiteral (double value, int numDecPlaces); String boolLiteral (bool value); - String colourToCode (const Colour& col); + String colourToCode (Colour col); String justificationToCode (const Justification&); String alignFunctionCallParams (const String& call, const StringArray& parameters, int maxLineLength); diff --git a/modules/juce_audio_plugin_client/Standalone/juce_StandaloneFilterWindow.h b/modules/juce_audio_plugin_client/Standalone/juce_StandaloneFilterWindow.h index e1dfad5501..cde253e53d 100644 --- a/modules/juce_audio_plugin_client/Standalone/juce_StandaloneFilterWindow.h +++ b/modules/juce_audio_plugin_client/Standalone/juce_StandaloneFilterWindow.h @@ -46,7 +46,7 @@ public: class and deleted automatically when no longer needed. (It can also be null) */ StandaloneFilterWindow (const String& title, - const Colour& backgroundColour, + Colour backgroundColour, PropertySet* settingsToUse) : DocumentWindow (title, backgroundColour, DocumentWindow::minimiseButton | DocumentWindow::closeButton), settings (settingsToUse), diff --git a/modules/juce_graphics/fonts/juce_TextLayout.cpp b/modules/juce_graphics/fonts/juce_TextLayout.cpp index de1232c5ca..ba369426fc 100644 --- a/modules/juce_graphics/fonts/juce_TextLayout.cpp +++ b/modules/juce_graphics/fonts/juce_TextLayout.cpp @@ -260,7 +260,7 @@ namespace TextLayoutHelpers struct Token { - Token (const String& t, const Font& f, const Colour& c, const bool whitespace) + Token (const String& t, const Font& f, Colour c, const bool whitespace) : text (t), font (f), colour (c), area (font.getStringWidthFloat (t), f.getHeight()), isWhitespace (whitespace), @@ -415,7 +415,7 @@ namespace TextLayoutHelpers } void appendText (const AttributedString& text, const Range stringRange, - const Font& font, const Colour& colour) + const Font& font, Colour colour) { const String stringText (text.getText().substring (stringRange.getStart(), stringRange.getEnd())); String::CharPointerType t (stringText.getCharPointer()); diff --git a/modules/juce_graphics/native/juce_win32_Direct2DGraphicsContext.cpp b/modules/juce_graphics/native/juce_win32_Direct2DGraphicsContext.cpp index 4e44b9f45a..519557e7e8 100644 --- a/modules/juce_graphics/native/juce_win32_Direct2DGraphicsContext.cpp +++ b/modules/juce_graphics/native/juce_win32_Direct2DGraphicsContext.cpp @@ -722,7 +722,7 @@ private: return D2D1::RectF ((float) r.getX(), (float) r.getY(), (float) r.getRight(), (float) r.getBottom()); } - static D2D1_COLOR_F colourToD2D (const Colour& c) + static D2D1_COLOR_F colourToD2D (Colour c) { return D2D1::ColorF::ColorF (c.getFloatRed(), c.getFloatGreen(), c.getFloatBlue(), c.getFloatAlpha()); } diff --git a/modules/juce_gui_basics/buttons/juce_ShapeButton.cpp b/modules/juce_gui_basics/buttons/juce_ShapeButton.cpp index 65b11af12b..5494ca2819 100644 --- a/modules/juce_gui_basics/buttons/juce_ShapeButton.cpp +++ b/modules/juce_gui_basics/buttons/juce_ShapeButton.cpp @@ -22,14 +22,11 @@ ============================================================================== */ -ShapeButton::ShapeButton (const String& text_, - const Colour& normalColour_, - const Colour& overColour_, - const Colour& downColour_) - : Button (text_), - normalColour (normalColour_), - overColour (overColour_), - downColour (downColour_), +ShapeButton::ShapeButton (const String& t, Colour n, Colour o, Colour d) + : Button (t), + normalColour (n), + overColour (o), + downColour (d), maintainShapeProportions (false), outlineWidth (0.0f) { @@ -39,16 +36,16 @@ ShapeButton::~ShapeButton() { } -void ShapeButton::setColours (const Colour& newNormalColour, - const Colour& newOverColour, - const Colour& newDownColour) +void ShapeButton::setColours (Colour newNormalColour, + Colour newOverColour, + Colour newDownColour) { normalColour = newNormalColour; overColour = newOverColour; downColour = newDownColour; } -void ShapeButton::setOutline (const Colour& newOutlineColour, +void ShapeButton::setOutline (Colour newOutlineColour, const float newOutlineWidth) { outlineColour = newOutlineColour; diff --git a/modules/juce_gui_basics/buttons/juce_ShapeButton.h b/modules/juce_gui_basics/buttons/juce_ShapeButton.h index 991ca85b3e..f87121242a 100644 --- a/modules/juce_gui_basics/buttons/juce_ShapeButton.h +++ b/modules/juce_gui_basics/buttons/juce_ShapeButton.h @@ -46,9 +46,9 @@ public: @param downColour the colour to use when the button is in the pressed-down state */ ShapeButton (const String& name, - const Colour& normalColour, - const Colour& overColour, - const Colour& downColour); + Colour normalColour, + Colour overColour, + Colour downColour); /** Destructor. */ ~ShapeButton(); @@ -73,16 +73,16 @@ public: @param overColour the colour to use when the mouse is over the shape @param downColour the colour to use when the button is in the pressed-down state */ - void setColours (const Colour& normalColour, - const Colour& overColour, - const Colour& downColour); + void setColours (Colour normalColour, + Colour overColour, + Colour downColour); /** Sets up an outline to draw around the shape. @param outlineColour the colour to use @param outlineStrokeWidth the thickness of line to draw */ - void setOutline (const Colour& outlineColour, + void setOutline (Colour outlineColour, float outlineStrokeWidth); diff --git a/modules/juce_gui_basics/drawables/juce_DrawableImage.cpp b/modules/juce_gui_basics/drawables/juce_DrawableImage.cpp index 17d0fc456b..7c29dee045 100644 --- a/modules/juce_gui_basics/drawables/juce_DrawableImage.cpp +++ b/modules/juce_gui_basics/drawables/juce_DrawableImage.cpp @@ -62,7 +62,7 @@ void DrawableImage::setOpacity (const float newOpacity) opacity = newOpacity; } -void DrawableImage::setOverlayColour (const Colour& newOverlayColour) +void DrawableImage::setOverlayColour (Colour newOverlayColour) { overlayColour = newOverlayColour; } @@ -205,7 +205,7 @@ Colour DrawableImage::ValueTreeWrapper::getOverlayColour() const return Colour::fromString (state [overlay].toString()); } -void DrawableImage::ValueTreeWrapper::setOverlayColour (const Colour& newColour, UndoManager* undoManager) +void DrawableImage::ValueTreeWrapper::setOverlayColour (Colour newColour, UndoManager* undoManager) { if (newColour.isTransparent()) state.removeProperty (overlay, undoManager); diff --git a/modules/juce_gui_basics/drawables/juce_DrawableImage.h b/modules/juce_gui_basics/drawables/juce_DrawableImage.h index 103e15fa4e..47d5d190c4 100644 --- a/modules/juce_gui_basics/drawables/juce_DrawableImage.h +++ b/modules/juce_gui_basics/drawables/juce_DrawableImage.h @@ -67,10 +67,10 @@ public: This is handy for doing things like darkening or lightening an image by overlaying it with semi-transparent black or white. */ - void setOverlayColour (const Colour& newOverlayColour); + void setOverlayColour (Colour newOverlayColour); /** Returns the overlay colour. */ - const Colour& getOverlayColour() const noexcept { return overlayColour; } + Colour getOverlayColour() const noexcept { return overlayColour; } /** Sets the bounding box within which the image should be displayed. */ void setBoundingBox (const RelativeParallelogram& newBounds); @@ -91,9 +91,9 @@ public: /** @internal */ Rectangle getDrawableBounds() const override; /** @internal */ - void refreshFromValueTree (const ValueTree& tree, ComponentBuilder& builder); + void refreshFromValueTree (const ValueTree& tree, ComponentBuilder&); /** @internal */ - ValueTree createValueTree (ComponentBuilder::ImageProvider* imageProvider) const override; + ValueTree createValueTree (ComponentBuilder::ImageProvider*) const override; /** @internal */ static const Identifier valueTreeType; @@ -105,19 +105,19 @@ public: ValueTreeWrapper (const ValueTree& state); var getImageIdentifier() const; - void setImageIdentifier (const var& newIdentifier, UndoManager* undoManager); - Value getImageIdentifierValue (UndoManager* undoManager); + void setImageIdentifier (const var&, UndoManager*); + Value getImageIdentifierValue (UndoManager*); float getOpacity() const; - void setOpacity (float newOpacity, UndoManager* undoManager); - Value getOpacityValue (UndoManager* undoManager); + void setOpacity (float newOpacity, UndoManager*); + Value getOpacityValue (UndoManager*); Colour getOverlayColour() const; - void setOverlayColour (const Colour& newColour, UndoManager* undoManager); - Value getOverlayColourValue (UndoManager* undoManager); + void setOverlayColour (Colour newColour, UndoManager*); + Value getOverlayColourValue (UndoManager*); RelativeParallelogram getBoundingBox() const; - void setBoundingBox (const RelativeParallelogram& newBounds, UndoManager* undoManager); + void setBoundingBox (const RelativeParallelogram&, UndoManager*); static const Identifier opacity, overlay, image, topLeft, topRight, bottomLeft; }; diff --git a/modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.cpp b/modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.cpp index 0d8cc58b47..fed399e363 100644 --- a/modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.cpp +++ b/modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.cpp @@ -91,7 +91,7 @@ FileChooserDialogBox::FileChooserDialogBox (const String& name, const String& instructions, FileBrowserComponent& chooserComponent, const bool warnAboutOverwritingExistingFiles_, - const Colour& backgroundColour) + Colour backgroundColour) : ResizableWindow (name, backgroundColour, true), warnAboutOverwritingExistingFiles (warnAboutOverwritingExistingFiles_) { diff --git a/modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.h b/modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.h index 2969ff22ff..0effab4594 100644 --- a/modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.h +++ b/modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.h @@ -91,7 +91,7 @@ public: const String& instructions, FileBrowserComponent& browserComponent, bool warnAboutOverwritingExistingFiles, - const Colour& backgroundColour); + Colour backgroundColour); /** Destructor. */ ~FileChooserDialogBox(); diff --git a/modules/juce_gui_basics/layout/juce_MultiDocumentPanel.cpp b/modules/juce_gui_basics/layout/juce_MultiDocumentPanel.cpp index 434c82d43a..78f6550403 100644 --- a/modules/juce_gui_basics/layout/juce_MultiDocumentPanel.cpp +++ b/modules/juce_gui_basics/layout/juce_MultiDocumentPanel.cpp @@ -22,7 +22,7 @@ ============================================================================== */ -MultiDocumentPanelWindow::MultiDocumentPanelWindow (const Colour& backgroundColour) +MultiDocumentPanelWindow::MultiDocumentPanelWindow (Colour backgroundColour) : DocumentWindow (String::empty, backgroundColour, DocumentWindow::maximiseButton | DocumentWindow::closeButton, false) { @@ -156,7 +156,7 @@ void MultiDocumentPanel::addWindow (Component* component) } bool MultiDocumentPanel::addDocument (Component* const component, - const Colour& docColour, + Colour docColour, const bool deleteWhenRemoved) { // If you try passing a full DocumentWindow or ResizableWindow in here, you'll end up @@ -415,7 +415,7 @@ void MultiDocumentPanel::setLayoutMode (const LayoutMode newLayoutMode) } } -void MultiDocumentPanel::setBackgroundColour (const Colour& newBackgroundColour) +void MultiDocumentPanel::setBackgroundColour (Colour newBackgroundColour) { if (backgroundColour != newBackgroundColour) { diff --git a/modules/juce_gui_basics/layout/juce_MultiDocumentPanel.h b/modules/juce_gui_basics/layout/juce_MultiDocumentPanel.h index 00ded3ccc7..4de61f5a6a 100644 --- a/modules/juce_gui_basics/layout/juce_MultiDocumentPanel.h +++ b/modules/juce_gui_basics/layout/juce_MultiDocumentPanel.h @@ -46,20 +46,20 @@ public: //============================================================================== /** */ - MultiDocumentPanelWindow (const Colour& backgroundColour); + MultiDocumentPanelWindow (Colour backgroundColour); /** Destructor. */ ~MultiDocumentPanelWindow(); //============================================================================== /** @internal */ - void maximiseButtonPressed(); + void maximiseButtonPressed() override; /** @internal */ - void closeButtonPressed(); + void closeButtonPressed() override; /** @internal */ - void activeWindowStatusChanged(); + void activeWindowStatusChanged() override; /** @internal */ - void broughtToFront(); + void broughtToFront() override; private: //============================================================================== @@ -136,7 +136,7 @@ public: the caller must handle the component's deletion */ bool addDocument (Component* component, - const Colour& backgroundColour, + Colour backgroundColour, bool deleteWhenRemoved); /** Closes one of the documents. @@ -233,13 +233,13 @@ public: Each document has its own background colour, but this is the one used to fill the areas behind them. */ - void setBackgroundColour (const Colour& newBackgroundColour); + void setBackgroundColour (Colour newBackgroundColour); /** Returns the current background colour. @see setBackgroundColour */ - const Colour& getBackgroundColour() const noexcept { return backgroundColour; } + Colour getBackgroundColour() const noexcept { return backgroundColour; } /** If the panel is being used in tabbed mode, this returns the TabbedComponent that's involved. */ TabbedComponent* getCurrentTabbedComponent() const noexcept { return tabComponent; } diff --git a/modules/juce_gui_basics/layout/juce_TabbedButtonBar.cpp b/modules/juce_gui_basics/layout/juce_TabbedButtonBar.cpp index 9f76dbb3df..cdd49bf494 100644 --- a/modules/juce_gui_basics/layout/juce_TabbedButtonBar.cpp +++ b/modules/juce_gui_basics/layout/juce_TabbedButtonBar.cpp @@ -227,7 +227,7 @@ void TabbedButtonBar::clearTabs() } void TabbedButtonBar::addTab (const String& tabName, - const Colour& tabBackgroundColour, + Colour tabBackgroundColour, int insertIndex) { jassert (tabName.isNotEmpty()); // you have to give them all a name.. @@ -482,7 +482,7 @@ Colour TabbedButtonBar::getTabBackgroundColour (const int tabIndex) return tab == nullptr ? Colours::white : tab->colour; } -void TabbedButtonBar::setTabBackgroundColour (const int tabIndex, const Colour& newColour) +void TabbedButtonBar::setTabBackgroundColour (const int tabIndex, Colour newColour) { if (TabInfo* const tab = tabs [tabIndex]) { diff --git a/modules/juce_gui_basics/layout/juce_TabbedButtonBar.h b/modules/juce_gui_basics/layout/juce_TabbedButtonBar.h index 5cfb4d4057..cc35344461 100644 --- a/modules/juce_gui_basics/layout/juce_TabbedButtonBar.h +++ b/modules/juce_gui_basics/layout/juce_TabbedButtonBar.h @@ -206,7 +206,7 @@ public: If this is the first tab added, it'll also be automatically selected. */ void addTab (const String& tabName, - const Colour& tabBackgroundColour, + Colour tabBackgroundColour, int insertIndex); /** Changes the name of one of the tabs. */ @@ -273,7 +273,7 @@ public: /** Changes the background colour of a tab. @see addTab, getTabBackgroundColour */ - void setTabBackgroundColour (int tabIndex, const Colour& newColour); + void setTabBackgroundColour (int tabIndex, Colour newColour); //============================================================================== /** A set of colour IDs to use to change the colour of various aspects of the component. diff --git a/modules/juce_gui_basics/layout/juce_TabbedComponent.cpp b/modules/juce_gui_basics/layout/juce_TabbedComponent.cpp index 4e1a065a24..d8570afc7b 100644 --- a/modules/juce_gui_basics/layout/juce_TabbedComponent.cpp +++ b/modules/juce_gui_basics/layout/juce_TabbedComponent.cpp @@ -145,7 +145,7 @@ void TabbedComponent::clearTabs() } void TabbedComponent::addTab (const String& tabName, - const Colour& tabBackgroundColour, + Colour tabBackgroundColour, Component* const contentComponent, const bool deleteComponentWhenNotNeeded, const int insertIndex) @@ -194,7 +194,7 @@ Colour TabbedComponent::getTabBackgroundColour (const int tabIndex) const noexce return tabs->getTabBackgroundColour (tabIndex); } -void TabbedComponent::setTabBackgroundColour (const int tabIndex, const Colour& newColour) +void TabbedComponent::setTabBackgroundColour (const int tabIndex, Colour newColour) { tabs->setTabBackgroundColour (tabIndex, newColour); diff --git a/modules/juce_gui_basics/layout/juce_TabbedComponent.h b/modules/juce_gui_basics/layout/juce_TabbedComponent.h index 0c983d8bc4..2278352609 100644 --- a/modules/juce_gui_basics/layout/juce_TabbedComponent.h +++ b/modules/juce_gui_basics/layout/juce_TabbedComponent.h @@ -107,7 +107,7 @@ public: @see TabbedButtonBar::addTab */ void addTab (const String& tabName, - const Colour& tabBackgroundColour, + Colour tabBackgroundColour, Component* contentComponent, bool deleteComponentWhenNotNeeded, int insertIndex = -1); @@ -134,7 +134,7 @@ public: Colour getTabBackgroundColour (int tabIndex) const noexcept; /** Changes the background colour of one of the tabs. */ - void setTabBackgroundColour (int tabIndex, const Colour& newColour); + void setTabBackgroundColour (int tabIndex, Colour newColour); //============================================================================== /** Changes the currently-selected tab. diff --git a/modules/juce_gui_basics/widgets/juce_TextEditor.cpp b/modules/juce_gui_basics/widgets/juce_TextEditor.cpp index eb5a5f1dc3..e2fa861af9 100644 --- a/modules/juce_gui_basics/widgets/juce_TextEditor.cpp +++ b/modules/juce_gui_basics/widgets/juce_TextEditor.cpp @@ -1163,7 +1163,7 @@ void TextEditor::setInputRestrictions (const int maxLen, setInputFilter (new LengthAndCharacterRestriction (maxLen, chars), true); } -void TextEditor::setTextToShowWhenEmpty (const String& text, const Colour& colourToUse) +void TextEditor::setTextToShowWhenEmpty (const String& text, Colour colourToUse) { textToShowWhenEmpty = text; colourForTextWhenEmpty = colourToUse; diff --git a/modules/juce_gui_basics/widgets/juce_TextEditor.h b/modules/juce_gui_basics/widgets/juce_TextEditor.h index 2231088efd..fe2c6bd746 100644 --- a/modules/juce_gui_basics/widgets/juce_TextEditor.h +++ b/modules/juce_gui_basics/widgets/juce_TextEditor.h @@ -267,7 +267,7 @@ public: string is only displayed, it's not taken to actually be the contents of the editor. */ - void setTextToShowWhenEmpty (const String& text, const Colour& colourToUse); + void setTextToShowWhenEmpty (const String& text, Colour colourToUse); //============================================================================== /** Changes the size of the scrollbars that are used. diff --git a/modules/juce_gui_basics/windows/juce_DialogWindow.cpp b/modules/juce_gui_basics/windows/juce_DialogWindow.cpp index 7a7a2b3824..186ebfd173 100644 --- a/modules/juce_gui_basics/windows/juce_DialogWindow.cpp +++ b/modules/juce_gui_basics/windows/juce_DialogWindow.cpp @@ -22,7 +22,7 @@ ============================================================================== */ -DialogWindow::DialogWindow (const String& name, const Colour& colour, +DialogWindow::DialogWindow (const String& name, Colour colour, const bool escapeCloses, const bool onDesktop) : DocumentWindow (name, colour, DocumentWindow::closeButton, onDesktop), escapeKeyTriggersCloseButton (escapeCloses) @@ -124,7 +124,7 @@ int DialogWindow::LaunchOptions::runModal() void DialogWindow::showDialog (const String& dialogTitle, Component* const contentComponent, Component* const componentToCentreAround, - const Colour& backgroundColour, + Colour backgroundColour, const bool escapeKeyTriggersCloseButton, const bool resizable, const bool useBottomRightCornerResizer) @@ -146,7 +146,7 @@ void DialogWindow::showDialog (const String& dialogTitle, int DialogWindow::showModalDialog (const String& dialogTitle, Component* const contentComponent, Component* const componentToCentreAround, - const Colour& backgroundColour, + Colour backgroundColour, const bool escapeKeyTriggersCloseButton, const bool resizable, const bool useBottomRightCornerResizer) diff --git a/modules/juce_gui_basics/windows/juce_DialogWindow.h b/modules/juce_gui_basics/windows/juce_DialogWindow.h index f5062a8da9..4ecaf5d27b 100644 --- a/modules/juce_gui_basics/windows/juce_DialogWindow.h +++ b/modules/juce_gui_basics/windows/juce_DialogWindow.h @@ -64,7 +64,7 @@ public: desktop; if false, you can use it as a child component */ DialogWindow (const String& name, - const Colour& backgroundColour, + Colour backgroundColour, bool escapeKeyTriggersCloseButton, bool addToDesktop = true); @@ -192,7 +192,7 @@ public: static void showDialog (const String& dialogTitle, Component* contentComponent, Component* componentToCentreAround, - const Colour& backgroundColour, + Colour backgroundColour, bool escapeKeyTriggersCloseButton, bool shouldBeResizable = false, bool useBottomRightCornerResizer = false); @@ -240,7 +240,7 @@ public: static int showModalDialog (const String& dialogTitle, Component* contentComponent, Component* componentToCentreAround, - const Colour& backgroundColour, + Colour backgroundColour, bool escapeKeyTriggersCloseButton, bool shouldBeResizable = false, bool useBottomRightCornerResizer = false); diff --git a/modules/juce_gui_basics/windows/juce_DocumentWindow.cpp b/modules/juce_gui_basics/windows/juce_DocumentWindow.cpp index 42a7bf7e5f..e63b8db687 100644 --- a/modules/juce_gui_basics/windows/juce_DocumentWindow.cpp +++ b/modules/juce_gui_basics/windows/juce_DocumentWindow.cpp @@ -42,9 +42,9 @@ private: //============================================================================== DocumentWindow::DocumentWindow (const String& title, - const Colour& backgroundColour, - const int requiredButtons_, - const bool addToDesktop_) + Colour backgroundColour, + int requiredButtons_, + bool addToDesktop_) : ResizableWindow (title, backgroundColour, addToDesktop_), titleBarHeight (26), menuBarHeight (24), diff --git a/modules/juce_gui_basics/windows/juce_DocumentWindow.h b/modules/juce_gui_basics/windows/juce_DocumentWindow.h index cb4fdfdaed..6bc0108f19 100644 --- a/modules/juce_gui_basics/windows/juce_DocumentWindow.h +++ b/modules/juce_gui_basics/windows/juce_DocumentWindow.h @@ -89,7 +89,7 @@ public: @see TitleBarButtons */ DocumentWindow (const String& name, - const Colour& backgroundColour, + Colour backgroundColour, int requiredButtons, bool addToDesktop = true); diff --git a/modules/juce_gui_basics/windows/juce_ResizableWindow.cpp b/modules/juce_gui_basics/windows/juce_ResizableWindow.cpp index 45c5ca057e..f3ad59680c 100644 --- a/modules/juce_gui_basics/windows/juce_ResizableWindow.cpp +++ b/modules/juce_gui_basics/windows/juce_ResizableWindow.cpp @@ -37,7 +37,7 @@ ResizableWindow::ResizableWindow (const String& name, } ResizableWindow::ResizableWindow (const String& name, - const Colour& backgroundColour_, + Colour backgroundColour_, const bool addToDesktop_) : TopLevelWindow (name, addToDesktop_), ownsContentComponent (false), @@ -401,7 +401,7 @@ Colour ResizableWindow::getBackgroundColour() const noexcept return findColour (backgroundColourId, false); } -void ResizableWindow::setBackgroundColour (const Colour& newColour) +void ResizableWindow::setBackgroundColour (Colour newColour) { Colour backgroundColour (newColour); diff --git a/modules/juce_gui_basics/windows/juce_ResizableWindow.h b/modules/juce_gui_basics/windows/juce_ResizableWindow.h index b0cc95b702..1b2dd4fc04 100644 --- a/modules/juce_gui_basics/windows/juce_ResizableWindow.h +++ b/modules/juce_gui_basics/windows/juce_ResizableWindow.h @@ -75,7 +75,7 @@ public: desktop; if false, you can use it as a child component */ ResizableWindow (const String& name, - const Colour& backgroundColour, + Colour backgroundColour, bool addToDesktop); /** Destructor. @@ -110,7 +110,7 @@ public: @see getBackgroundColour */ - void setBackgroundColour (const Colour& newColour); + void setBackgroundColour (Colour newColour); //============================================================================== /** Make the window resizable or fixed. diff --git a/modules/juce_gui_basics/windows/juce_TopLevelWindow.h b/modules/juce_gui_basics/windows/juce_TopLevelWindow.h index 6383109e0f..39610f13ba 100644 --- a/modules/juce_gui_basics/windows/juce_TopLevelWindow.h +++ b/modules/juce_gui_basics/windows/juce_TopLevelWindow.h @@ -128,7 +128,7 @@ public: //============================================================================== /** @internal */ - virtual void addToDesktop (int windowStyleFlags, void* nativeWindowToAttachTo = nullptr); + virtual void addToDesktop (int windowStyleFlags, void* nativeWindowToAttachTo = nullptr) override; protected: //============================================================================== diff --git a/modules/juce_gui_extra/misc/juce_PreferencesPanel.cpp b/modules/juce_gui_extra/misc/juce_PreferencesPanel.cpp index 40c6b0c26b..9d4c579a71 100644 --- a/modules/juce_gui_extra/misc/juce_PreferencesPanel.cpp +++ b/modules/juce_gui_extra/misc/juce_PreferencesPanel.cpp @@ -79,7 +79,7 @@ void PreferencesPanel::addSettingsPage (const String& title, const void* imageDa } //============================================================================== -void PreferencesPanel::showInDialogBox (const String& dialogTitle, int dialogWidth, int dialogHeight, const Colour& backgroundColour) +void PreferencesPanel::showInDialogBox (const String& dialogTitle, int dialogWidth, int dialogHeight, Colour backgroundColour) { setSize (dialogWidth, dialogHeight); diff --git a/modules/juce_gui_extra/misc/juce_PreferencesPanel.h b/modules/juce_gui_extra/misc/juce_PreferencesPanel.h index 4e19cb88d7..6852bb39aa 100644 --- a/modules/juce_gui_extra/misc/juce_PreferencesPanel.h +++ b/modules/juce_gui_extra/misc/juce_PreferencesPanel.h @@ -102,7 +102,7 @@ public: void showInDialogBox (const String& dialogTitle, int dialogWidth, int dialogHeight, - const Colour& backgroundColour = Colours::white); + Colour backgroundColour = Colours::white); //============================================================================== /** Subclasses must override this to return a component for each preferences page.