From 082c9097e4c35b580a02f55c301df89b2d69e7a5 Mon Sep 17 00:00:00 2001 From: Jonas Kvinge Date: Sun, 14 Jun 2020 18:58:24 +0200 Subject: [PATCH] Fix parameter name mispatches --- 3rdparty/taglib/ape/apeitem.cpp | 4 +-- 3rdparty/taglib/asf/asfattribute.h | 2 +- 3rdparty/taglib/asf/asftag.h | 26 +++++++++---------- 3rdparty/taglib/dsdiff/dsdifffile.cpp | 6 ++--- 3rdparty/taglib/dsdiff/dsdifffile.h | 6 ++--- .../taglib/flac/flacunknownmetadatablock.h | 2 +- 3rdparty/taglib/mod/modproperties.h | 2 +- 3rdparty/taglib/mp4/mp4item.cpp | 6 ++--- 3rdparty/taglib/mp4/mp4tag.h | 4 +-- .../taglib/mpeg/id3v2/frames/commentsframe.h | 2 +- .../frames/generalencapsulatedobjectframe.h | 2 +- .../mpeg/id3v2/frames/ownershipframe.cpp | 8 +++--- .../mpeg/id3v2/frames/popularimeterframe.cpp | 12 ++++----- .../taglib/mpeg/id3v2/frames/privateframe.h | 2 +- .../id3v2/frames/synchronizedlyricsframe.h | 2 +- .../id3v2/frames/unsynchronizedlyricsframe.h | 2 +- 3rdparty/taglib/mpeg/id3v2/id3v2frame.h | 2 +- 3rdparty/taglib/mpeg/id3v2/id3v2synchdata.h | 2 +- 3rdparty/taglib/riff/aiff/aifffile.cpp | 4 +-- 3rdparty/taglib/riff/wav/wavfile.cpp | 4 +-- 3rdparty/taglib/tag.h | 2 +- 3rdparty/taglib/toolkit/tbytevector.cpp | 4 +-- 3rdparty/taglib/toolkit/tstringlist.h | 2 +- 3rdparty/taglib/trueaudio/trueaudiofile.cpp | 4 +-- 3rdparty/taglib/wavpack/wavpackfile.cpp | 4 +-- ext/gstmoodbar/gstfastspectrum.cpp | 4 +-- ext/libstrawberry-common/core/closure.cpp | 4 +-- ext/libstrawberry-common/core/closure.h | 2 +- ext/libstrawberry-common/core/logging.h | 2 +- src/collection/collectionfilterwidget.h | 2 +- src/collection/collectionmodel.h | 4 +-- src/collection/collectionwatcher.h | 2 +- src/context/contextalbumsmodel.cpp | 2 +- src/context/contextalbumsmodel.h | 2 +- src/core/mergedproxymodel.cpp | 4 +-- src/core/mergedproxymodel.h | 10 +++---- src/core/mpris2.h | 4 +-- src/core/songloader.h | 2 +- src/core/urlhandler.h | 2 +- src/core/utilities.cpp | 2 +- src/core/utilities.h | 4 +-- src/covermanager/albumcoverfetcher.h | 2 +- src/covermanager/albumcovermanager.cpp | 2 +- src/covermanager/albumcovermanager.h | 2 +- src/device/devicelister.h | 2 +- src/device/devicemanager.cpp | 2 +- src/device/devicemanager.h | 4 +-- src/device/deviceview.cpp | 4 +-- src/device/udisks2lister.cpp | 4 +-- src/device/udisks2lister.h | 4 +-- src/engine/enginebase.h | 2 +- src/engine/gstengine.h | 2 +- src/engine/gstenginepipeline.cpp | 2 +- src/engine/gstenginepipeline.h | 6 ++--- src/globalshortcuts/globalshortcut-x11.cpp | 8 +++--- src/internet/internetplaylistitem.cpp | 2 +- src/internet/internetplaylistitem.h | 2 +- src/internet/internetsearchitemdelegate.h | 2 +- src/internet/internetsearchview.h | 8 +++--- src/lyrics/lyricsfetchersearch.h | 2 +- src/moodbar/moodbarloader.cpp | 2 +- src/moodbar/moodbarloader.h | 2 +- src/moodbar/moodbarpipeline.cpp | 2 +- src/moodbar/moodbarpipeline.h | 2 +- src/organise/organiseformat.h | 4 +-- src/playlist/playlist.cpp | 10 +++---- src/playlist/playlist.h | 16 ++++++------ src/playlist/playlistdelegates.h | 4 +-- src/settings/scrobblersettingspage.h | 2 +- src/tidal/tidalrequest.h | 2 +- src/tidal/tidalservice.h | 2 +- src/transcoder/transcoder.h | 2 +- src/widgets/fancytabwidget.cpp | 4 +-- src/widgets/fancytabwidget.h | 4 +-- src/widgets/favoritewidget.cpp | 2 +- src/widgets/favoritewidget.h | 2 +- 76 files changed, 145 insertions(+), 147 deletions(-) diff --git a/3rdparty/taglib/ape/apeitem.cpp b/3rdparty/taglib/ape/apeitem.cpp index 9f6a1954..d02a97d9 100644 --- a/3rdparty/taglib/ape/apeitem.cpp +++ b/3rdparty/taglib/ape/apeitem.cpp @@ -100,8 +100,8 @@ bool APE::Item::isReadOnly() const { return d->readOnly; } -void APE::Item::setType(APE::Item::ItemTypes val) { - d->type = val; +void APE::Item::setType(APE::Item::ItemTypes type) { + d->type = type; } APE::Item::ItemTypes APE::Item::type() const { diff --git a/3rdparty/taglib/asf/asfattribute.h b/3rdparty/taglib/asf/asfattribute.h index 42f187fd..a06fe2cd 100644 --- a/3rdparty/taglib/asf/asfattribute.h +++ b/3rdparty/taglib/asf/asfattribute.h @@ -104,7 +104,7 @@ class TAGLIB_EXPORT Attribute { /*! * Construct an attribute as a copy of \a other. */ - Attribute(const Attribute &item); + Attribute(const Attribute &other); /*! * Copies the contents of \a other into this item. diff --git a/3rdparty/taglib/asf/asftag.h b/3rdparty/taglib/asf/asftag.h index d3d935cf..0a9bfccf 100644 --- a/3rdparty/taglib/asf/asftag.h +++ b/3rdparty/taglib/asf/asftag.h @@ -97,47 +97,47 @@ class TAGLIB_EXPORT Tag : public Strawberry_TagLib::TagLib::Tag { /*! * Sets the title to \a s. */ - virtual void setTitle(const String &s); + virtual void setTitle(const String &value); /*! * Sets the artist to \a s. */ - virtual void setArtist(const String &s); + virtual void setArtist(const String &value); /*! * Sets the album to \a s. If \a s is String::null then this value will be cleared. */ - virtual void setAlbum(const String &s); + virtual void setAlbum(const String &value); /*! * Sets the comment to \a s. */ - virtual void setComment(const String &s); + virtual void setComment(const String &value); /*! * Sets the rating to \a s. */ - virtual void setRating(const String &s); + virtual void setRating(const String &value); /*! * Sets the copyright to \a s. */ - virtual void setCopyright(const String &s); + virtual void setCopyright(const String &value); /*! * Sets the genre to \a s. */ - virtual void setGenre(const String &s); + virtual void setGenre(const String &value); /*! * Sets the year to \a i. If \a s is 0 then this value will be cleared. */ - virtual void setYear(unsigned int i); + virtual void setYear(unsigned int value); /*! * Sets the track to \a i. If \a s is 0 then this value will be cleared. */ - virtual void setTrack(unsigned int i); + virtual void setTrack(unsigned int value); /*! * Returns true if the tag does not contain any data. @@ -153,12 +153,12 @@ class TAGLIB_EXPORT Tag : public Strawberry_TagLib::TagLib::Tag { /*! * \return True if a value for \a attribute is currently set. */ - bool contains(const String &name) const; + bool contains(const String &key) const; /*! * Removes the \a key attribute from the tag */ - void removeItem(const String &name); + void removeItem(const String &key); /*! * \return The list of values for the key \a name, or an empty list if no values have been set. @@ -182,8 +182,8 @@ class TAGLIB_EXPORT Tag : public Strawberry_TagLib::TagLib::Tag { void addAttribute(const String &name, const Attribute &attribute); PropertyMap properties() const; - void removeUnsupportedProperties(const StringList &properties); - PropertyMap setProperties(const PropertyMap &properties); + void removeUnsupportedProperties(const StringList &props); + PropertyMap setProperties(const PropertyMap &props); private: class TagPrivate; diff --git a/3rdparty/taglib/dsdiff/dsdifffile.cpp b/3rdparty/taglib/dsdiff/dsdifffile.cpp index 41a905f1..a58aacb1 100644 --- a/3rdparty/taglib/dsdiff/dsdifffile.cpp +++ b/3rdparty/taglib/dsdiff/dsdifffile.cpp @@ -196,13 +196,13 @@ PropertyMap DSDIFF::File::properties() const { } -void DSDIFF::File::removeUnsupportedProperties(const StringList &unsupported) { +void DSDIFF::File::removeUnsupportedProperties(const StringList &properties) { if (d->hasID3v2) - d->tag.access(ID3v2Index, false)->removeUnsupportedProperties(unsupported); + d->tag.access(ID3v2Index, false)->removeUnsupportedProperties(properties); if (d->hasDiin) - d->tag.access(DIINIndex, false)->removeUnsupportedProperties(unsupported); + d->tag.access(DIINIndex, false)->removeUnsupportedProperties(properties); } diff --git a/3rdparty/taglib/dsdiff/dsdifffile.h b/3rdparty/taglib/dsdiff/dsdifffile.h index 1df80882..c40ac024 100644 --- a/3rdparty/taglib/dsdiff/dsdifffile.h +++ b/3rdparty/taglib/dsdiff/dsdifffile.h @@ -141,7 +141,7 @@ class TAGLIB_EXPORT File : public Strawberry_TagLib::TagLib::File { * Implements the unified property interface -- import function. * This method forwards to ID3v2::Tag::setProperties(). */ - PropertyMap setProperties(const PropertyMap &); + PropertyMap setProperties(const PropertyMap &properties); /*! * Returns the AIFF::Properties for this file. @@ -214,8 +214,8 @@ class TAGLIB_EXPORT File : public Strawberry_TagLib::TagLib::File { File &operator=(const File &); void removeRootChunk(const ByteVector &id); - void removeRootChunk(unsigned int chunk); - void removeChildChunk(unsigned int i, unsigned int chunk); + void removeRootChunk(unsigned int i); + void removeChildChunk(unsigned int i, unsigned int childChunkNum); /*! * Sets the data for the the specified chunk at root level to \a data. diff --git a/3rdparty/taglib/flac/flacunknownmetadatablock.h b/3rdparty/taglib/flac/flacunknownmetadatablock.h index 832cd9ec..972829d1 100644 --- a/3rdparty/taglib/flac/flacunknownmetadatablock.h +++ b/3rdparty/taglib/flac/flacunknownmetadatablock.h @@ -37,7 +37,7 @@ namespace FLAC { class TAGLIB_EXPORT UnknownMetadataBlock : public MetadataBlock { public: - UnknownMetadataBlock(int blockType, const ByteVector &data); + UnknownMetadataBlock(int code, const ByteVector &data); ~UnknownMetadataBlock(); /*! diff --git a/3rdparty/taglib/mod/modproperties.h b/3rdparty/taglib/mod/modproperties.h index f2b95d75..31ed2d02 100644 --- a/3rdparty/taglib/mod/modproperties.h +++ b/3rdparty/taglib/mod/modproperties.h @@ -50,7 +50,7 @@ class TAGLIB_EXPORT Properties : public AudioProperties { void setChannels(int channels); - void setInstrumentCount(unsigned int sampleCount); + void setInstrumentCount(unsigned int instrumentCount); void setLengthInPatterns(unsigned char lengthInPatterns); private: diff --git a/3rdparty/taglib/mp4/mp4item.cpp b/3rdparty/taglib/mp4/mp4item.cpp index 3b0f6fc3..a011e596 100644 --- a/3rdparty/taglib/mp4/mp4item.cpp +++ b/3rdparty/taglib/mp4/mp4item.cpp @@ -93,9 +93,9 @@ MP4::Item::Item(long long value) : d(new ItemPrivate()) { d->m_longlong = value; } -MP4::Item::Item(int value1, int value2) : d(new ItemPrivate()) { - d->m_intPair.first = value1; - d->m_intPair.second = value2; +MP4::Item::Item(int first, int second) : d(new ItemPrivate()) { + d->m_intPair.first = first; + d->m_intPair.second = second; } MP4::Item::Item(const ByteVectorList &value) : d(new ItemPrivate()) { diff --git a/3rdparty/taglib/mp4/mp4tag.h b/3rdparty/taglib/mp4/mp4tag.h index 06a594a7..e7d1ed98 100644 --- a/3rdparty/taglib/mp4/mp4tag.h +++ b/3rdparty/taglib/mp4/mp4tag.h @@ -91,8 +91,8 @@ class TAGLIB_EXPORT Tag : public Strawberry_TagLib::TagLib::Tag { bool contains(const String &key) const; PropertyMap properties() const; - void removeUnsupportedProperties(const StringList &properties); - PropertyMap setProperties(const PropertyMap &properties); + void removeUnsupportedProperties(const StringList &props); + PropertyMap setProperties(const PropertyMap &props); private: AtomDataList parseData2(const Atom *atom, int expectedFlags = -1, bool freeForm = false); diff --git a/3rdparty/taglib/mpeg/id3v2/frames/commentsframe.h b/3rdparty/taglib/mpeg/id3v2/frames/commentsframe.h index c0fabfbd..e99698c3 100644 --- a/3rdparty/taglib/mpeg/id3v2/frames/commentsframe.h +++ b/3rdparty/taglib/mpeg/id3v2/frames/commentsframe.h @@ -98,7 +98,7 @@ class TAGLIB_EXPORT CommentsFrame : public Frame { * * \see language() */ - void setLanguage(const ByteVector &languageCode); + void setLanguage(const ByteVector &languageEncoding); /*! * Sets the description of the comment to \a s. diff --git a/3rdparty/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.h b/3rdparty/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.h index 19611409..20d9495f 100644 --- a/3rdparty/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.h +++ b/3rdparty/taglib/mpeg/id3v2/frames/generalencapsulatedobjectframe.h @@ -157,7 +157,7 @@ class TAGLIB_EXPORT GeneralEncapsulatedObjectFrame : public Frame { * \see mimeType() * \see setMimeType() */ - void setObject(const ByteVector &object); + void setObject(const ByteVector &data); protected: virtual void parseFields(const ByteVector &data); diff --git a/3rdparty/taglib/mpeg/id3v2/frames/ownershipframe.cpp b/3rdparty/taglib/mpeg/id3v2/frames/ownershipframe.cpp index e6e19186..1a5800e4 100644 --- a/3rdparty/taglib/mpeg/id3v2/frames/ownershipframe.cpp +++ b/3rdparty/taglib/mpeg/id3v2/frames/ownershipframe.cpp @@ -64,16 +64,16 @@ String OwnershipFrame::pricePaid() const { return d->pricePaid; } -void OwnershipFrame::setPricePaid(const String &s) { - d->pricePaid = s; +void OwnershipFrame::setPricePaid(const String &pricePaid) { + d->pricePaid = pricePaid; } String OwnershipFrame::datePurchased() const { return d->datePurchased; } -void OwnershipFrame::setDatePurchased(const String &s) { - d->datePurchased = s; +void OwnershipFrame::setDatePurchased(const String &datePurchased) { + d->datePurchased = datePurchased; } String OwnershipFrame::seller() const { diff --git a/3rdparty/taglib/mpeg/id3v2/frames/popularimeterframe.cpp b/3rdparty/taglib/mpeg/id3v2/frames/popularimeterframe.cpp index a47b93f2..75125f96 100644 --- a/3rdparty/taglib/mpeg/id3v2/frames/popularimeterframe.cpp +++ b/3rdparty/taglib/mpeg/id3v2/frames/popularimeterframe.cpp @@ -60,24 +60,24 @@ String PopularimeterFrame::email() const { return d->email; } -void PopularimeterFrame::setEmail(const String &s) { - d->email = s; +void PopularimeterFrame::setEmail(const String &email) { + d->email = email; } int PopularimeterFrame::rating() const { return d->rating; } -void PopularimeterFrame::setRating(int s) { - d->rating = s; +void PopularimeterFrame::setRating(int rating) { + d->rating = rating; } unsigned int PopularimeterFrame::counter() const { return d->counter; } -void PopularimeterFrame::setCounter(unsigned int s) { - d->counter = s; +void PopularimeterFrame::setCounter(unsigned int counter) { + d->counter = counter; } //////////////////////////////////////////////////////////////////////////////// diff --git a/3rdparty/taglib/mpeg/id3v2/frames/privateframe.h b/3rdparty/taglib/mpeg/id3v2/frames/privateframe.h index 31560b0c..7dc1dc40 100644 --- a/3rdparty/taglib/mpeg/id3v2/frames/privateframe.h +++ b/3rdparty/taglib/mpeg/id3v2/frames/privateframe.h @@ -84,7 +84,7 @@ class TAGLIB_EXPORT PrivateFrame : public Frame { /*! * */ - void setData(const ByteVector &v); + void setData(const ByteVector &data); protected: // Reimplementations. diff --git a/3rdparty/taglib/mpeg/id3v2/frames/synchronizedlyricsframe.h b/3rdparty/taglib/mpeg/id3v2/frames/synchronizedlyricsframe.h index eb95c402..83214c59 100644 --- a/3rdparty/taglib/mpeg/id3v2/frames/synchronizedlyricsframe.h +++ b/3rdparty/taglib/mpeg/id3v2/frames/synchronizedlyricsframe.h @@ -172,7 +172,7 @@ class TAGLIB_EXPORT SynchronizedLyricsFrame : public Frame { * * \see language() */ - void setLanguage(const ByteVector &languageCode); + void setLanguage(const ByteVector &languageEncoding); /*! * Set the timestamp format. diff --git a/3rdparty/taglib/mpeg/id3v2/frames/unsynchronizedlyricsframe.h b/3rdparty/taglib/mpeg/id3v2/frames/unsynchronizedlyricsframe.h index f0c5a4b7..ad01c4d5 100644 --- a/3rdparty/taglib/mpeg/id3v2/frames/unsynchronizedlyricsframe.h +++ b/3rdparty/taglib/mpeg/id3v2/frames/unsynchronizedlyricsframe.h @@ -97,7 +97,7 @@ class TAGLIB_EXPORT UnsynchronizedLyricsFrame : public Frame { * * \see language() */ - void setLanguage(const ByteVector &languageCode); + void setLanguage(const ByteVector &languageEncoding); /*! * Sets the description of the unsynchronized lyrics frame to \a s. diff --git a/3rdparty/taglib/mpeg/id3v2/id3v2frame.h b/3rdparty/taglib/mpeg/id3v2/id3v2frame.h index a2797885..125cb47c 100644 --- a/3rdparty/taglib/mpeg/id3v2/id3v2frame.h +++ b/3rdparty/taglib/mpeg/id3v2/id3v2frame.h @@ -398,7 +398,7 @@ class TAGLIB_EXPORT Frame::Header { * * \see tagAlterPreservation() */ - void setTagAlterPreservation(bool discard); + void setTagAlterPreservation(bool preserve); /*! * Returns true if the flag for file alter preservation is set. diff --git a/3rdparty/taglib/mpeg/id3v2/id3v2synchdata.h b/3rdparty/taglib/mpeg/id3v2/id3v2synchdata.h index 0ac6a762..e7da49df 100644 --- a/3rdparty/taglib/mpeg/id3v2/id3v2synchdata.h +++ b/3rdparty/taglib/mpeg/id3v2/id3v2synchdata.h @@ -57,7 +57,7 @@ TAGLIB_EXPORT ByteVector fromUInt(unsigned int value); /*! * Convert the data from unsynchronized data to its original format. */ -TAGLIB_EXPORT ByteVector decode(const ByteVector &input); +TAGLIB_EXPORT ByteVector decode(const ByteVector &data); } // namespace SynchData } // namespace ID3v2 diff --git a/3rdparty/taglib/riff/aiff/aifffile.cpp b/3rdparty/taglib/riff/aiff/aifffile.cpp index 492d4a63..384d10c1 100644 --- a/3rdparty/taglib/riff/aiff/aifffile.cpp +++ b/3rdparty/taglib/riff/aiff/aifffile.cpp @@ -90,8 +90,8 @@ PropertyMap RIFF::AIFF::File::properties() const { return d->tag->properties(); } -void RIFF::AIFF::File::removeUnsupportedProperties(const StringList &unsupported) { - d->tag->removeUnsupportedProperties(unsupported); +void RIFF::AIFF::File::removeUnsupportedProperties(const StringList &properties) { + d->tag->removeUnsupportedProperties(properties); } PropertyMap RIFF::AIFF::File::setProperties(const PropertyMap &properties) { diff --git a/3rdparty/taglib/riff/wav/wavfile.cpp b/3rdparty/taglib/riff/wav/wavfile.cpp index d319fad5..b2c5ae2a 100644 --- a/3rdparty/taglib/riff/wav/wavfile.cpp +++ b/3rdparty/taglib/riff/wav/wavfile.cpp @@ -121,8 +121,8 @@ PropertyMap RIFF::WAV::File::properties() const { return d->tag.properties(); } -void RIFF::WAV::File::removeUnsupportedProperties(const StringList &unsupported) { - d->tag.removeUnsupportedProperties(unsupported); +void RIFF::WAV::File::removeUnsupportedProperties(const StringList &properties) { + d->tag.removeUnsupportedProperties(properties); } PropertyMap RIFF::WAV::File::setProperties(const PropertyMap &properties) { diff --git a/3rdparty/taglib/tag.h b/3rdparty/taglib/tag.h index 82fa1ac7..adc6f476 100644 --- a/3rdparty/taglib/tag.h +++ b/3rdparty/taglib/tag.h @@ -68,7 +68,7 @@ class TAGLIB_EXPORT Tag { * This default implementation sets only the tags for which setter methods exist in this class * (artist, album, ...), and only one value per key; the rest will be contained in the returned PropertyMap. */ - PropertyMap setProperties(const PropertyMap &properties); + PropertyMap setProperties(const PropertyMap &origProps); /*! * Returns the track name; if no track name is present in the tag String::null will be returned. diff --git a/3rdparty/taglib/toolkit/tbytevector.cpp b/3rdparty/taglib/toolkit/tbytevector.cpp index d9078759..6a007d15 100644 --- a/3rdparty/taglib/toolkit/tbytevector.cpp +++ b/3rdparty/taglib/toolkit/tbytevector.cpp @@ -349,8 +349,8 @@ ByteVector::~ByteVector() { delete d; } -ByteVector &ByteVector::setData(const char *s, unsigned int length) { - ByteVector(s, length).swap(*this); +ByteVector &ByteVector::setData(const char *data, unsigned int length) { + ByteVector(data, length).swap(*this); return *this; } diff --git a/3rdparty/taglib/toolkit/tstringlist.h b/3rdparty/taglib/toolkit/tstringlist.h index 3eeabf1a..1b48a175 100644 --- a/3rdparty/taglib/toolkit/tstringlist.h +++ b/3rdparty/taglib/toolkit/tstringlist.h @@ -66,7 +66,7 @@ class TAGLIB_EXPORT StringList : public List { * \note This should only be used with the 8-bit codecs Latin1 and UTF8, * when used with other codecs it will simply print a warning and exit. */ - StringList(const ByteVectorList &vl, String::Type t = String::Latin1); + StringList(const ByteVectorList &bl, String::Type t = String::Latin1); /*! * Destroys this StringList instance. diff --git a/3rdparty/taglib/trueaudio/trueaudiofile.cpp b/3rdparty/taglib/trueaudio/trueaudiofile.cpp index 4849e857..a2aea938 100644 --- a/3rdparty/taglib/trueaudio/trueaudiofile.cpp +++ b/3rdparty/taglib/trueaudio/trueaudiofile.cpp @@ -129,8 +129,8 @@ PropertyMap TrueAudio::File::properties() const { return d->tag.properties(); } -void TrueAudio::File::removeUnsupportedProperties(const StringList &unsupported) { - d->tag.removeUnsupportedProperties(unsupported); +void TrueAudio::File::removeUnsupportedProperties(const StringList &properties) { + d->tag.removeUnsupportedProperties(properties); } PropertyMap TrueAudio::File::setProperties(const PropertyMap &properties) { diff --git a/3rdparty/taglib/wavpack/wavpackfile.cpp b/3rdparty/taglib/wavpack/wavpackfile.cpp index 6e715cd2..0519c3f7 100644 --- a/3rdparty/taglib/wavpack/wavpackfile.cpp +++ b/3rdparty/taglib/wavpack/wavpackfile.cpp @@ -113,8 +113,8 @@ PropertyMap WavPack::File::properties() const { return d->tag.properties(); } -void WavPack::File::removeUnsupportedProperties(const StringList &unsupported) { - d->tag.removeUnsupportedProperties(unsupported); +void WavPack::File::removeUnsupportedProperties(const StringList &properties) { + d->tag.removeUnsupportedProperties(properties); } PropertyMap WavPack::File::setProperties(const PropertyMap &properties) { diff --git a/ext/gstmoodbar/gstfastspectrum.cpp b/ext/gstmoodbar/gstfastspectrum.cpp index b447f9b8..743c49da 100644 --- a/ext/gstmoodbar/gstfastspectrum.cpp +++ b/ext/gstmoodbar/gstfastspectrum.cpp @@ -65,7 +65,7 @@ static void gst_fastspectrum_set_property (GObject * object, guint prop_id, cons static void gst_fastspectrum_get_property (GObject * object, guint prop_id, GValue * value, GParamSpec * pspec); static gboolean gst_fastspectrum_start (GstBaseTransform * trans); static gboolean gst_fastspectrum_stop (GstBaseTransform * trans); -static GstFlowReturn gst_fastspectrum_transform_ip (GstBaseTransform * trans, GstBuffer * in); +static GstFlowReturn gst_fastspectrum_transform_ip (GstBaseTransform *trans, GstBuffer *buffer); static gboolean gst_fastspectrum_setup (GstAudioFilter * base, const GstAudioInfo * info); static void gst_fastspectrum_class_init (GstFastSpectrumClass * klass) { @@ -390,7 +390,7 @@ static void gst_fastspectrum_run_fft (GstFastSpectrum * spectrum, guint input_po } -static GstFlowReturn gst_fastspectrum_transform_ip (GstBaseTransform * trans, GstBuffer * buffer) { +static GstFlowReturn gst_fastspectrum_transform_ip (GstBaseTransform *trans, GstBuffer *buffer) { GstFastSpectrum *spectrum = GST_FASTSPECTRUM (trans); guint rate = GST_AUDIO_FILTER_RATE (spectrum); diff --git a/ext/libstrawberry-common/core/closure.cpp b/ext/libstrawberry-common/core/closure.cpp index 647cf2e9..8fb8151e 100644 --- a/ext/libstrawberry-common/core/closure.cpp +++ b/ext/libstrawberry-common/core/closure.cpp @@ -29,9 +29,7 @@ namespace _detail { -ClosureBase::ClosureBase(ObjectHelper *helper) - : helper_(helper) { -} +ClosureBase::ClosureBase(ObjectHelper *helper) : helper_(helper) {} ClosureBase::~ClosureBase() {} diff --git a/ext/libstrawberry-common/core/closure.h b/ext/libstrawberry-common/core/closure.h index d2ccccb5..9cbcfe35 100644 --- a/ext/libstrawberry-common/core/closure.h +++ b/ext/libstrawberry-common/core/closure.h @@ -64,7 +64,7 @@ class ClosureBase { class ObjectHelper : public QObject { Q_OBJECT public: - ObjectHelper(QObject *parent, const char *signal, ClosureBase *closure); + ObjectHelper(QObject *sender, const char *signal, ClosureBase *closure); ~ObjectHelper(); private slots: diff --git a/ext/libstrawberry-common/core/logging.h b/ext/libstrawberry-common/core/logging.h index ee71609b..873f0e83 100644 --- a/ext/libstrawberry-common/core/logging.h +++ b/ext/libstrawberry-common/core/logging.h @@ -82,6 +82,6 @@ extern const char *kDefaultLogLevels; } // namespace logging -QDebug operator<<(QDebug debug, std::chrono::seconds secs); +QDebug operator<<(QDebug dbg, std::chrono::seconds secs); #endif // LOGGING_H diff --git a/src/collection/collectionfilterwidget.h b/src/collection/collectionfilterwidget.h index 40be542b..3894dfc6 100644 --- a/src/collection/collectionfilterwidget.h +++ b/src/collection/collectionfilterwidget.h @@ -80,7 +80,7 @@ class CollectionFilterWidget : public QWidget { QString group_by(const int number); public slots: - void SetQueryMode(QueryOptions::QueryMode view); + void SetQueryMode(QueryOptions::QueryMode query_mode); void FocusOnFilter(QKeyEvent *e); signals: diff --git a/src/collection/collectionmodel.h b/src/collection/collectionmodel.h index 7710d344..1023de5e 100644 --- a/src/collection/collectionmodel.h +++ b/src/collection/collectionmodel.h @@ -171,7 +171,7 @@ class CollectionModel : public SimpleTreeModel { static QString PrettyAlbumDisc(const QString &album, const int disc); static QString PrettyYearAlbumDisc(const int year, const QString &album, const int disc); static QString SortText(QString text); - static QString SortTextForNumber(const int year); + static QString SortTextForNumber(const int number); static QString SortTextForArtist(QString artist); static QString SortTextForSong(const Song &song); static QString SortTextForYear(const int year); @@ -200,7 +200,7 @@ class CollectionModel : public SimpleTreeModel { protected: void LazyPopulate(CollectionItem *item) { LazyPopulate(item, true); } - void LazyPopulate(CollectionItem *item, const bool signal); + void LazyPopulate(CollectionItem *parent, const bool signal); private slots: // From CollectionBackend diff --git a/src/collection/collectionwatcher.h b/src/collection/collectionwatcher.h index 5f7226f8..98df8aac 100644 --- a/src/collection/collectionwatcher.h +++ b/src/collection/collectionwatcher.h @@ -150,7 +150,7 @@ class CollectionWatcher : public QObject { private slots: void Exit(); - void DirectoryChanged(const QString &path); + void DirectoryChanged(const QString &subdir); void IncrementalScanNow(); void FullScanNow(); void RescanTracksNow(); diff --git a/src/context/contextalbumsmodel.cpp b/src/context/contextalbumsmodel.cpp index 3a8b0e5a..dfb2ae26 100644 --- a/src/context/contextalbumsmodel.cpp +++ b/src/context/contextalbumsmodel.cpp @@ -304,7 +304,7 @@ void ContextAlbumsModel::PostQuery(CollectionItem *parent, const ContextAlbumsMo } -void ContextAlbumsModel::LazyPopulate(CollectionItem *parent, bool signal) { +void ContextAlbumsModel::LazyPopulate(CollectionItem *parent, const bool signal) { if (parent->lazy_loaded) return; parent->lazy_loaded = true; diff --git a/src/context/contextalbumsmodel.h b/src/context/contextalbumsmodel.h index 3541af3b..0e4e7c6e 100644 --- a/src/context/contextalbumsmodel.h +++ b/src/context/contextalbumsmodel.h @@ -97,7 +97,7 @@ class ContextAlbumsModel : public SimpleTreeModel { protected: void LazyPopulate(CollectionItem *item) { LazyPopulate(item, true); } - void LazyPopulate(CollectionItem *item, bool signal); + void LazyPopulate(CollectionItem *parent, const bool signal); private slots: void AlbumCoverLoaded(const quint64 id, const AlbumCoverLoaderResult &result); diff --git a/src/core/mergedproxymodel.cpp b/src/core/mergedproxymodel.cpp index b071900c..57d15d89 100644 --- a/src/core/mergedproxymodel.cpp +++ b/src/core/mergedproxymodel.cpp @@ -370,9 +370,9 @@ bool MergedProxyModel::hasChildren(const QModelIndex &parent) const { } -QVariant MergedProxyModel::data(const QModelIndex &proxyIndex, int role) const { +QVariant MergedProxyModel::data(const QModelIndex &proxy_index, int role) const { - QModelIndex source_index = mapToSource(proxyIndex); + QModelIndex source_index = mapToSource(proxy_index); if (!IsKnownModel(source_index.model())) return QVariant(); return source_index.model()->data(source_index, role); diff --git a/src/core/mergedproxymodel.h b/src/core/mergedproxymodel.h index 2fc30911..991424ac 100644 --- a/src/core/mergedproxymodel.h +++ b/src/core/mergedproxymodel.h @@ -60,9 +60,9 @@ class MergedProxyModel : public QAbstractProxyModel { QModelIndex parent(const QModelIndex &child) const; int rowCount(const QModelIndex &parent) const; int columnCount(const QModelIndex &parent) const; - QVariant data(const QModelIndex &proxyIndex, int role = Qt::DisplayRole) const; + QVariant data(const QModelIndex &proxy_index, int role = Qt::DisplayRole) const; bool hasChildren(const QModelIndex &parent) const; - QMap itemData(const QModelIndex &proxyIndex) const; + QMap itemData(const QModelIndex &proxy_index) const; Qt::ItemFlags flags(const QModelIndex &index) const; bool setData(const QModelIndex &index, const QVariant &value, int role); QStringList mimeTypes() const; @@ -74,9 +74,9 @@ class MergedProxyModel : public QAbstractProxyModel { // QAbstractProxyModel // Note that these implementations of map{To,From}Source will not always give you an index in sourceModel(), // you might get an index in one of the child models instead. - QModelIndex mapFromSource(const QModelIndex &sourceIndex) const; - QModelIndex mapToSource(const QModelIndex &proxyIndex) const; - void setSourceModel(QAbstractItemModel *sourceModel); + QModelIndex mapFromSource(const QModelIndex &source_index) const; + QModelIndex mapToSource(const QModelIndex &proxy_index) const; + void setSourceModel(QAbstractItemModel *source_model); // Convenience functions that call map{To,From}Source multiple times. QModelIndexList mapFromSource(const QModelIndexList &source_indexes) const; diff --git a/src/core/mpris2.h b/src/core/mpris2.h index 5139daee..f7e41963 100644 --- a/src/core/mpris2.h +++ b/src/core/mpris2.h @@ -143,9 +143,9 @@ class Mpris2 : public QObject { QString LoopStatus() const; void SetLoopStatus(const QString &value); double Rate() const; - void SetRate(double value); + void SetRate(double rate); bool Shuffle() const; - void SetShuffle(bool value); + void SetShuffle(bool enable); QVariantMap Metadata() const; double Volume() const; void SetVolume(double value); diff --git a/src/core/songloader.h b/src/core/songloader.h index 0268bc13..fc2313bd 100644 --- a/src/core/songloader.h +++ b/src/core/songloader.h @@ -116,7 +116,7 @@ class SongLoader : public QObject { // GStreamer callbacks static void TypeFound(GstElement *typefind, uint probability, GstCaps *caps, void *self); - static GstPadProbeReturn DataReady(GstPad*, GstPadProbeInfo *buf, gpointer self); + static GstPadProbeReturn DataReady(GstPad*, GstPadProbeInfo *info, gpointer self); static GstBusSyncReply BusCallbackSync(GstBus*, GstMessage*, gpointer); static gboolean BusCallback(GstBus*, GstMessage*, gpointer); diff --git a/src/core/urlhandler.h b/src/core/urlhandler.h index f5a87720..4411ccb4 100644 --- a/src/core/urlhandler.h +++ b/src/core/urlhandler.h @@ -57,7 +57,7 @@ class UrlHandler : public QObject { Error, }; - LoadResult(const QUrl &original_url = QUrl(), const Type type = NoMoreTracks, const QUrl &stream_url = QUrl(), const Song::FileType filetype = Song::FileType_Stream, const int samplerate = -1, const int bitdepth = -1, const qint64 length_nanosec_ = -1, const QString error = QString()); + LoadResult(const QUrl &original_url = QUrl(), const Type type = NoMoreTracks, const QUrl &stream_url = QUrl(), const Song::FileType filetype = Song::FileType_Stream, const int samplerate = -1, const int bit_depth = -1, const qint64 length_nanosec = -1, const QString error = QString()); // The url that the playlist item has in Url(). // Might be something unplayable like lastfm://... diff --git a/src/core/utilities.cpp b/src/core/utilities.cpp index 2dbe4421..997dcb92 100644 --- a/src/core/utilities.cpp +++ b/src/core/utilities.cpp @@ -461,7 +461,7 @@ void OpenInFileBrowser(const QList &urls) { } -QByteArray Hmac(const QByteArray &key, const QByteArray &data, HashFunction method) { +QByteArray Hmac(const QByteArray &key, const QByteArray &data, const HashFunction method) { const int kBlockSize = 64; // bytes Q_ASSERT(key.length() <= kBlockSize); diff --git a/src/core/utilities.h b/src/core/utilities.h index ea2727ba..af36b4db 100644 --- a/src/core/utilities.h +++ b/src/core/utilities.h @@ -68,14 +68,14 @@ bool RemoveRecursive(const QString &path); bool CopyRecursive(const QString &source, const QString &destination); bool Copy(QIODevice *source, QIODevice *destination); -void OpenInFileBrowser(const QList &filenames); +void OpenInFileBrowser(const QList &urls); enum HashFunction { Md5_Algo, Sha256_Algo, Sha1_Algo, }; -QByteArray Hmac(const QByteArray &key, const QByteArray &data, HashFunction algo); +QByteArray Hmac(const QByteArray &key, const QByteArray &data, const HashFunction method); QByteArray HmacMd5(const QByteArray &key, const QByteArray &data); QByteArray HmacSha256(const QByteArray &key, const QByteArray &data); QByteArray HmacSha1(const QByteArray &key, const QByteArray &data); diff --git a/src/covermanager/albumcoverfetcher.h b/src/covermanager/albumcoverfetcher.h index c35c1d87..ae670bf1 100644 --- a/src/covermanager/albumcoverfetcher.h +++ b/src/covermanager/albumcoverfetcher.h @@ -104,7 +104,7 @@ class AlbumCoverFetcher : public QObject { private slots: void SingleSearchFinished(const quint64, const CoverSearchResults results); - void SingleCoverFetched(const quint64, const QUrl &cover_url, const QImage &cover); + void SingleCoverFetched(const quint64, const QUrl &cover_url, const QImage &image); void StartRequests(); private: diff --git a/src/covermanager/albumcovermanager.cpp b/src/covermanager/albumcovermanager.cpp index 4ad46514..fa778fc3 100644 --- a/src/covermanager/albumcovermanager.cpp +++ b/src/covermanager/albumcovermanager.cpp @@ -892,7 +892,7 @@ void AlbumCoverManager::ExportCovers() { } -void AlbumCoverManager::UpdateExportStatus(int exported, int skipped, int max) { +void AlbumCoverManager::UpdateExportStatus(const int exported, const int skipped, const int max) { progress_bar_->setValue(exported); diff --git a/src/covermanager/albumcovermanager.h b/src/covermanager/albumcovermanager.h index a100c893..6b9badb6 100644 --- a/src/covermanager/albumcovermanager.h +++ b/src/covermanager/albumcovermanager.h @@ -156,7 +156,7 @@ class AlbumCoverManager : public QMainWindow { void LoadSelectedToPlaylist(); void UpdateCoverInList(QListWidgetItem *item, const QUrl &cover); - void UpdateExportStatus(int exported, int bad, int count); + void UpdateExportStatus(const int exported, const int skipped, const int max); private: Ui_CoverManager *ui_; diff --git a/src/device/devicelister.h b/src/device/devicelister.h index 795a1338..215fd326 100644 --- a/src/device/devicelister.h +++ b/src/device/devicelister.h @@ -74,7 +74,7 @@ class DeviceLister : public QObject { public slots: virtual void UpdateDeviceFreeSpace(const QString &id) = 0; virtual void ShutDown() {} - virtual void MountDevice(const QString &id, const int ret); + virtual void MountDevice(const QString &id, const int request_id); virtual void UnmountDevice(const QString &id) { Q_UNUSED(id); } virtual void Exit(); diff --git a/src/device/devicemanager.cpp b/src/device/devicemanager.cpp index c12a3e97..4a617fa5 100644 --- a/src/device/devicemanager.cpp +++ b/src/device/devicemanager.cpp @@ -920,7 +920,7 @@ void DeviceManager::DeviceSongCountUpdated(int count) { } -void DeviceManager::LazyPopulate(DeviceInfo *parent, bool signal) { +void DeviceManager::LazyPopulate(DeviceInfo *parent, const bool signal) { Q_UNUSED(signal); if (parent->lazy_loaded) return; diff --git a/src/device/devicemanager.h b/src/device/devicemanager.h index 78f5c9db..619c4c88 100644 --- a/src/device/devicemanager.h +++ b/src/device/devicemanager.h @@ -113,7 +113,7 @@ class DeviceManager : public SimpleTreeModel { void SetDeviceOptions(QModelIndex idx, const QString &friendly_name, const QString &icon_name, MusicStorage::TranscodeMode mode, Song::FileType format); // QAbstractItemModel - QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const; + QVariant data(const QModelIndex &idx, int role = Qt::DisplayRole) const; public slots: void Unmount(QModelIndex idx); @@ -141,7 +141,7 @@ class DeviceManager : public SimpleTreeModel { protected: void LazyPopulate(DeviceInfo *item) { LazyPopulate(item, true); } - void LazyPopulate(DeviceInfo *item, bool signal); + void LazyPopulate(DeviceInfo *parent, const bool signal); private: diff --git a/src/device/deviceview.cpp b/src/device/deviceview.cpp index e37adb4e..9b3bdd5c 100644 --- a/src/device/deviceview.cpp +++ b/src/device/deviceview.cpp @@ -456,7 +456,7 @@ void DeviceView::DeleteFinished(const SongList &songs_with_errors) { } -bool DeviceView::CanRecursivelyExpand(const QModelIndex &index) const { +bool DeviceView::CanRecursivelyExpand(const QModelIndex &idx) const { // Never expand devices - return index.parent().isValid(); + return idx.parent().isValid(); } diff --git a/src/device/udisks2lister.cpp b/src/device/udisks2lister.cpp index a93ce525..379720cf 100644 --- a/src/device/udisks2lister.cpp +++ b/src/device/udisks2lister.cpp @@ -245,8 +245,8 @@ void Udisks2Lister::DBusInterfaceAdded(const QDBusObjectPath &path, const Interf } } -void Udisks2Lister::DBusInterfaceRemoved(const QDBusObjectPath &path, const QStringList &ifaces) { - Q_UNUSED(ifaces); +void Udisks2Lister::DBusInterfaceRemoved(const QDBusObjectPath &path, const QStringList &interfaces) { + Q_UNUSED(interfaces); if (!isPendingJob(path)) RemoveDevice(path); } diff --git a/src/device/udisks2lister.h b/src/device/udisks2lister.h index 71795de1..daf0393b 100644 --- a/src/device/udisks2lister.h +++ b/src/device/udisks2lister.h @@ -71,8 +71,8 @@ class Udisks2Lister : public DeviceLister { bool Init() override; private slots: - void DBusInterfaceAdded(const QDBusObjectPath &path, const InterfacesAndProperties &ifaces); - void DBusInterfaceRemoved(const QDBusObjectPath &path, const QStringList &ifaces); + void DBusInterfaceAdded(const QDBusObjectPath &path, const InterfacesAndProperties &interfaces); + void DBusInterfaceRemoved(const QDBusObjectPath &path, const QStringList &interfaces); void JobCompleted(bool success, const QString &message); private: diff --git a/src/engine/enginebase.h b/src/engine/enginebase.h index f413e86f..c9881266 100644 --- a/src/engine/enginebase.h +++ b/src/engine/enginebase.h @@ -97,7 +97,7 @@ public: // Plays a media stream represented with the URL 'u' from the given 'beginning' to the given 'end' (usually from 0 to a song's length). // Both markers should be passed in nanoseconds. 'end' can be negative, indicating that the real length of 'u' stream is unknown. - bool Play(const QUrl &stream_url, const QUrl &original_url, const TrackChangeFlags c, const bool force_stop_at_end, const quint64 beginning_nanosec, const qint64 end_nanosec); + bool Play(const QUrl &stream_url, const QUrl &original_url, const TrackChangeFlags flags, const bool force_stop_at_end, const quint64 beginning_nanosec, const qint64 end_nanosec); void SetVolume(const uint value); static uint MakeVolumeLogarithmic(const uint volume); diff --git a/src/engine/gstengine.h b/src/engine/gstengine.h index b6b997d7..2a4473af 100644 --- a/src/engine/gstengine.h +++ b/src/engine/gstengine.h @@ -103,7 +103,7 @@ class GstEngine : public Engine::Base, public GstBufferConsumer { void SetEqualizerEnabled(const bool); // Set equalizer preamp and gains, range -100..100. Gains are 10 values. - void SetEqualizerParameters(const int preamp, const QList &bandGains); + void SetEqualizerParameters(const int preamp, const QList &band_gains); void AddBufferConsumer(GstBufferConsumer *consumer); void RemoveBufferConsumer(GstBufferConsumer *consumer); diff --git a/src/engine/gstenginepipeline.cpp b/src/engine/gstenginepipeline.cpp index e25b81d0..d0beed38 100644 --- a/src/engine/gstenginepipeline.cpp +++ b/src/engine/gstenginepipeline.cpp @@ -1221,7 +1221,7 @@ void GstEnginePipeline::StreamDiscovered(GstDiscoverer*, GstDiscovererInfo *info } -void GstEnginePipeline::StreamDiscoveryFinished(GstDiscoverer *, gpointer) {} +void GstEnginePipeline::StreamDiscoveryFinished(GstDiscoverer*, gpointer) {} QString GstEnginePipeline::GSTdiscovererErrorMessage(GstDiscovererResult result) { diff --git a/src/engine/gstenginepipeline.h b/src/engine/gstenginepipeline.h index 3b823ac1..918a539e 100644 --- a/src/engine/gstenginepipeline.h +++ b/src/engine/gstenginepipeline.h @@ -65,7 +65,7 @@ class GstEnginePipeline : public QObject { int id() const { return id_; } // Call these setters before Init - void set_output_device(const QString &sink, const QVariant &device); + void set_output_device(const QString &output, const QVariant &device); void set_volume_enabled(const bool enabled); void set_stereo_balancer_enabled(const bool enabled); void set_equalizer_enabled(const bool enabled); @@ -147,8 +147,8 @@ class GstEnginePipeline : public QObject { static GstBusSyncReply BusCallbackSync(GstBus*, GstMessage*, gpointer); static gboolean BusCallback(GstBus*, GstMessage*, gpointer); static void TaskEnterCallback(GstTask*, GThread*, gpointer); - static void StreamDiscovered(GstDiscoverer *discoverer, GstDiscovererInfo *info, GError *err, gpointer instance); - static void StreamDiscoveryFinished(GstDiscoverer *discoverer, gpointer instance); + static void StreamDiscovered(GstDiscoverer*, GstDiscovererInfo *info, GError*, gpointer self); + static void StreamDiscoveryFinished(GstDiscoverer*, gpointer); static QString GSTdiscovererErrorMessage(GstDiscovererResult result); void TagMessageReceived(GstMessage*); diff --git a/src/globalshortcuts/globalshortcut-x11.cpp b/src/globalshortcuts/globalshortcut-x11.cpp index b6a7f72f..bcd60580 100644 --- a/src/globalshortcuts/globalshortcut-x11.cpp +++ b/src/globalshortcuts/globalshortcut-x11.cpp @@ -49,16 +49,16 @@ quint32 GlobalShortcut::nativeModifiers(Qt::KeyboardModifiers qt_mods) { } -quint32 GlobalShortcut::nativeKeycode(Qt::Key key) { +quint32 GlobalShortcut::nativeKeycode(Qt::Key qt_key) { if (!QX11Info::display()) return 0; quint32 keysym = 0; - if (KeyMapperX11::keymapper_x11_.contains(key)) { - keysym = KeyMapperX11::keymapper_x11_.value(key); + if (KeyMapperX11::keymapper_x11_.contains(qt_key)) { + keysym = KeyMapperX11::keymapper_x11_.value(qt_key); } else { - keysym = XStringToKeysym(QKeySequence(key).toString().toLatin1().data()); + keysym = XStringToKeysym(QKeySequence(qt_key).toString().toLatin1().data()); if (keysym == NoSymbol) return 0; } return XKeysymToKeycode(QX11Info::display(), keysym); diff --git a/src/internet/internetplaylistitem.cpp b/src/internet/internetplaylistitem.cpp index 15649fd5..8455df11 100644 --- a/src/internet/internetplaylistitem.cpp +++ b/src/internet/internetplaylistitem.cpp @@ -35,7 +35,7 @@ #include "collection/sqlrow.h" #include "playlist/playlistbackend.h" -InternetPlaylistItem::InternetPlaylistItem(const Song::Source &source) +InternetPlaylistItem::InternetPlaylistItem(const Song::Source source) : PlaylistItem(source) {} InternetPlaylistItem::InternetPlaylistItem(InternetService *service, const Song &metadata) diff --git a/src/internet/internetplaylistitem.h b/src/internet/internetplaylistitem.h index bb5373ed..b4a2e7c4 100644 --- a/src/internet/internetplaylistitem.h +++ b/src/internet/internetplaylistitem.h @@ -35,7 +35,7 @@ class InternetService; class InternetPlaylistItem : public PlaylistItem { public: - explicit InternetPlaylistItem(const Song::Source &type); + explicit InternetPlaylistItem(const Song::Source source); explicit InternetPlaylistItem(InternetService *service, const Song &metadata); bool InitFromQuery(const SqlRow &query); Song Metadata() const; diff --git a/src/internet/internetsearchitemdelegate.h b/src/internet/internetsearchitemdelegate.h index cc64feac..dbd55e4b 100644 --- a/src/internet/internetsearchitemdelegate.h +++ b/src/internet/internetsearchitemdelegate.h @@ -34,7 +34,7 @@ class InternetSearchItemDelegate : public CollectionItemDelegate { public: explicit InternetSearchItemDelegate(InternetSearchView *view); - void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const; + void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &idx) const; private: InternetSearchView *view_; diff --git a/src/internet/internetsearchview.h b/src/internet/internetsearchview.h index 58735cb4..ba8eea8c 100644 --- a/src/internet/internetsearchview.h +++ b/src/internet/internetsearchview.h @@ -149,10 +149,10 @@ class InternetSearchView : public QWidget { void StartSearch(const QString &query); void SearchDone(const int service_id, const SongList &songs, const QString &error); - void UpdateStatus(const int id, const QString &text); - void ProgressSetMaximum(const int id, const int progress); - void UpdateProgress(const int id, const int max); - void AddResults(const int id, const ResultList &results); + void UpdateStatus(const int service_id, const QString &text); + void ProgressSetMaximum(const int service_id, const int max); + void UpdateProgress(const int service_id, const int progress); + void AddResults(const int service_id, const ResultList &results); void FocusOnFilter(QKeyEvent *e); diff --git a/src/lyrics/lyricsfetchersearch.h b/src/lyrics/lyricsfetchersearch.h index 02f4c53d..6d336d51 100644 --- a/src/lyrics/lyricsfetchersearch.h +++ b/src/lyrics/lyricsfetchersearch.h @@ -38,7 +38,7 @@ class LyricsFetcherSearch : public QObject { public: explicit LyricsFetcherSearch(const LyricsSearchRequest &request, QObject *parent); - void Start(LyricsProviders *cover_providers); + void Start(LyricsProviders *lyrics_providers); void Cancel(); signals: diff --git a/src/moodbar/moodbarloader.cpp b/src/moodbar/moodbarloader.cpp index 69ecc582..8f82070f 100644 --- a/src/moodbar/moodbarloader.cpp +++ b/src/moodbar/moodbarloader.cpp @@ -160,7 +160,7 @@ void MoodbarLoader::MaybeTakeNextRequest() { } -void MoodbarLoader::RequestFinished(MoodbarPipeline* request, const QUrl& url) { +void MoodbarLoader::RequestFinished(MoodbarPipeline *request, const QUrl &url) { Q_ASSERT(QThread::currentThread() == qApp->thread()); diff --git a/src/moodbar/moodbarloader.h b/src/moodbar/moodbarloader.h index 407bfa25..7e1b7ee4 100644 --- a/src/moodbar/moodbarloader.h +++ b/src/moodbar/moodbarloader.h @@ -57,7 +57,7 @@ class MoodbarLoader : public QObject { private slots: void ReloadSettings(); - void RequestFinished(MoodbarPipeline* request, const QUrl& filename); + void RequestFinished(MoodbarPipeline *request, const QUrl &url); void MaybeTakeNextRequest(); private: diff --git a/src/moodbar/moodbarpipeline.cpp b/src/moodbar/moodbarpipeline.cpp index 51605251..1eede8ad 100644 --- a/src/moodbar/moodbarpipeline.cpp +++ b/src/moodbar/moodbarpipeline.cpp @@ -132,7 +132,7 @@ void MoodbarPipeline::Start() { } -void MoodbarPipeline::ReportError(GstMessage* msg) { +void MoodbarPipeline::ReportError(GstMessage *msg) { GError* error; gchar* debugs; diff --git a/src/moodbar/moodbarpipeline.h b/src/moodbar/moodbarpipeline.h index cfca4253..6a59c065 100644 --- a/src/moodbar/moodbarpipeline.h +++ b/src/moodbar/moodbarpipeline.h @@ -53,7 +53,7 @@ class MoodbarPipeline : public QObject { private: GstElement* CreateElement(const QString& factory_name); - void ReportError(GstMessage* message); + void ReportError(GstMessage *msg); void Stop(bool success); void Cleanup(); diff --git a/src/organise/organiseformat.h b/src/organise/organiseformat.h index 582d28c0..a14332ef 100644 --- a/src/organise/organiseformat.h +++ b/src/organise/organiseformat.h @@ -70,7 +70,7 @@ class OrganiseFormat { class Validator : public QValidator { public: explicit Validator(QObject *parent = nullptr); - QValidator::State validate(QString &format, int &pos) const; + QValidator::State validate(QString &input, int&) const; }; class SyntaxHighlighter : public QSyntaxHighlighter { @@ -85,7 +85,7 @@ class OrganiseFormat { explicit SyntaxHighlighter(QObject *parent = nullptr); explicit SyntaxHighlighter(QTextEdit *parent); explicit SyntaxHighlighter(QTextDocument *parent); - void highlightBlock(const QString &format); + void highlightBlock(const QString &text); }; private: diff --git a/src/playlist/playlist.cpp b/src/playlist/playlist.cpp index 5ed6b836..76a9b2e2 100644 --- a/src/playlist/playlist.cpp +++ b/src/playlist/playlist.cpp @@ -987,15 +987,15 @@ void Playlist::InsertItemsWithoutUndo(const PlaylistItemList &items, int pos, bo } -void Playlist::InsertCollectionItems(const SongList &songs, int pos, bool play_now, bool enqueue, bool enqueue_next) { +void Playlist::InsertCollectionItems(const SongList &songs, const int pos, const bool play_now, const bool enqueue, const bool enqueue_next) { InsertSongItems(songs, pos, play_now, enqueue, enqueue_next); } -void Playlist::InsertSongs(const SongList &songs, int pos, bool play_now, bool enqueue, bool enqueue_next) { +void Playlist::InsertSongs(const SongList &songs, const int pos, const bool play_now, const bool enqueue, const bool enqueue_next) { InsertSongItems(songs, pos, play_now, enqueue, enqueue_next); } -void Playlist::InsertSongsOrCollectionItems(const SongList &songs, int pos, bool play_now, bool enqueue, bool enqueue_next) { +void Playlist::InsertSongsOrCollectionItems(const SongList &songs, const int pos, const bool play_now, const bool enqueue, const bool enqueue_next) { PlaylistItemList items; for (const Song &song : songs) { @@ -1010,7 +1010,7 @@ void Playlist::InsertSongsOrCollectionItems(const SongList &songs, int pos, bool } -void Playlist::InsertInternetItems(InternetService *service, const SongList &songs, int pos, bool play_now, bool enqueue, bool enqueue_next) { +void Playlist::InsertInternetItems(InternetService *service, const SongList &songs, const int pos, const bool play_now, const bool enqueue, const bool enqueue_next) { PlaylistItemList playlist_items; for (const Song &song : songs) { @@ -1433,7 +1433,7 @@ bool Playlist::removeRows(QList &rows) { } -PlaylistItemList Playlist::RemoveItemsWithoutUndo(int row, int count) { +PlaylistItemList Playlist::RemoveItemsWithoutUndo(const int row, const int count) { if (row < 0 || row >= items_.size() || row + count > items_.size()) { return PlaylistItemList(); diff --git a/src/playlist/playlist.h b/src/playlist/playlist.h index eed1ebe7..3b5baa01 100644 --- a/src/playlist/playlist.h +++ b/src/playlist/playlist.h @@ -229,11 +229,11 @@ class Playlist : public QAbstractListModel { void UpdateScrobblePoint(const qint64 seek_point_nanosec = 0); // Changing the playlist - void InsertItems (const PlaylistItemList &items, int pos = -1, bool play_now = false, bool enqueue = false, bool enqueue_next = false); - void InsertCollectionItems (const SongList &items, int pos = -1, bool play_now = false, bool enqueue = false, bool enqueue_next = false); - void InsertSongs (const SongList &items, int pos = -1, bool play_now = false, bool enqueue = false, bool enqueue_next = false); - void InsertSongsOrCollectionItems (const SongList &items, int pos = -1, bool play_now = false, bool enqueue = false, bool enqueue_next = false); - void InsertInternetItems(InternetService* service, const SongList& songs, int pos = -1, bool play_now = false, bool enqueue = false, bool enqueue_next = false); + void InsertItems(const PlaylistItemList &itemsIn, const int pos = -1, const bool play_now = false, const bool enqueue = false, const bool enqueue_next = false); + void InsertCollectionItems(const SongList &songs, const int pos = -1, const bool play_now = false, const bool enqueue = false, const bool enqueue_next = false); + void InsertSongs(const SongList &songs, const int pos = -1, const bool play_now = false, const bool enqueue = false, const bool enqueue_next = false); + void InsertSongsOrCollectionItems(const SongList &songs, const int pos = -1, const bool play_now = false, const bool enqueue = false, const bool enqueue_next = false); + void InsertInternetItems(InternetService* service, const SongList& songs, const int pos = -1, const bool play_now = false, const bool enqueue = false, const bool enqueue_next = false); void ReshuffleIndices(); @@ -265,7 +265,7 @@ class Playlist : public QAbstractListModel { // QAbstractListModel int rowCount(const QModelIndex& = QModelIndex()) const { return items_.count(); } int columnCount(const QModelIndex& = QModelIndex()) const { return ColumnCount; } - QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const; + QVariant data(const QModelIndex &idx, int role = Qt::DisplayRole) const; bool setData(const QModelIndex &index, const QVariant &value, int role); QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const; Qt::ItemFlags flags(const QModelIndex &index) const; @@ -301,7 +301,7 @@ class Playlist : public QAbstractListModel { void InsertUrls(const QList &urls, int pos = -1, bool play_now = false, bool enqueue = false, bool enqueue_next = false); // Removes items with given indices from the playlist. This operation is not undoable. - void RemoveItemsWithoutUndo(const QList &indices); + void RemoveItemsWithoutUndo(const QList &indicesIn); signals: void RestoreFinished(); @@ -331,7 +331,7 @@ class Playlist : public QAbstractListModel { // Modify the playlist without changing the undo stack. These are used by our friends in PlaylistUndoCommands void InsertItemsWithoutUndo(const PlaylistItemList &items, int pos, bool enqueue = false, bool enqueue_next = false); - PlaylistItemList RemoveItemsWithoutUndo(int pos, int count); + PlaylistItemList RemoveItemsWithoutUndo(const int row, const int count); void MoveItemsWithoutUndo(const QList &source_rows, int pos); void MoveItemWithoutUndo(int source, int dest); void MoveItemsWithoutUndo(int start, const QList &dest_rows); diff --git a/src/playlist/playlistdelegates.h b/src/playlist/playlistdelegates.h index e9e1c1d5..102e43ed 100644 --- a/src/playlist/playlistdelegates.h +++ b/src/playlist/playlistdelegates.h @@ -128,7 +128,7 @@ class FileTypeItemDelegate : public PlaylistDelegateBase { class TextItemDelegate : public PlaylistDelegateBase { public: explicit TextItemDelegate(QObject *parent) : PlaylistDelegateBase(parent) {} - QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index) const; + QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &idx) const; }; class TagCompletionModel : public QStringListModel { @@ -177,7 +177,7 @@ class SongSourceDelegate : public PlaylistDelegateBase { void paint(QPainter *paint, const QStyleOptionViewItem &option, const QModelIndex &index) const; private: - QPixmap LookupPixmap(const Song::Source &type, const QSize &size) const; + QPixmap LookupPixmap(const Song::Source &source, const QSize &size) const; mutable QPixmapCache cache_; }; diff --git a/src/settings/scrobblersettingspage.h b/src/settings/scrobblersettingspage.h index 99125c86..b1b4b698 100644 --- a/src/settings/scrobblersettingspage.h +++ b/src/settings/scrobblersettingspage.h @@ -36,7 +36,7 @@ class ScrobblerSettingsPage : public SettingsPage { Q_OBJECT public: - explicit ScrobblerSettingsPage(SettingsDialog *dialog); + explicit ScrobblerSettingsPage(SettingsDialog *parent); ~ScrobblerSettingsPage(); static const char *kSettingsGroup; diff --git a/src/tidal/tidalrequest.h b/src/tidal/tidalrequest.h index f5811aee..022ba280 100644 --- a/src/tidal/tidalrequest.h +++ b/src/tidal/tidalrequest.h @@ -58,7 +58,7 @@ class TidalRequest : public TidalBaseRequest { void Process(); void NeedLogin() { need_login_ = true; } - void Search(const int search_id, const QString &search_text); + void Search(const int query_id, const QString &search_text); signals: void Login(); diff --git a/src/tidal/tidalservice.h b/src/tidal/tidalservice.h index 284e91b6..bc2050a5 100644 --- a/src/tidal/tidalservice.h +++ b/src/tidal/tidalservice.h @@ -68,7 +68,7 @@ class TidalService : public InternetService { void ReloadSettings(); void Logout(); - int Search(const QString &query, InternetSearchView::SearchType type); + int Search(const QString &text, InternetSearchView::SearchType type); void CancelSearch(); int max_login_attempts() { return kLoginAttempts; } diff --git a/src/transcoder/transcoder.h b/src/transcoder/transcoder.h index 356b2d0f..07d35d51 100644 --- a/src/transcoder/transcoder.h +++ b/src/transcoder/transcoder.h @@ -130,7 +130,7 @@ class Transcoder : public QObject { GstElement *CreateElement(const QString &factory_name, GstElement *bin = nullptr, const QString &name = QString()); GstElement *CreateElementForMimeType(const QString &element_type, const QString &mime_type, GstElement *bin = nullptr); - void SetElementProperties(const QString &name, GObject *element); + void SetElementProperties(const QString &name, GObject *object); static void NewPadCallback(GstElement*, GstPad *pad, gpointer data); static GstBusSyncReply BusCallbackSync(GstBus*, GstMessage *msg, gpointer data); diff --git a/src/widgets/fancytabwidget.cpp b/src/widgets/fancytabwidget.cpp index 0cd711e5..bf55afcb 100644 --- a/src/widgets/fancytabwidget.cpp +++ b/src/widgets/fancytabwidget.cpp @@ -361,7 +361,7 @@ void FancyTabWidget::setCurrentIndex(int idx) { } -void FancyTabWidget::currentTabChanged(int idx) { +void FancyTabWidget::currentTabChanged(const int idx) { QWidget *currentPage = currentWidget(); QLayout *layout = currentPage->layout(); @@ -406,7 +406,7 @@ void FancyTabWidget::Load(const QString &kSettingsGroup) { } -int FancyTabWidget::insertTab(int idx, QWidget *page, const QIcon &icon, const QString &label) { +int FancyTabWidget::insertTab(const int idx, QWidget *page, const QIcon &icon, const QString &label) { return QTabWidget::insertTab(idx, page, icon, label); } diff --git a/src/widgets/fancytabwidget.h b/src/widgets/fancytabwidget.h index 0ada0e8e..87b60901 100644 --- a/src/widgets/fancytabwidget.h +++ b/src/widgets/fancytabwidget.h @@ -52,7 +52,7 @@ class FancyTabWidget : public QTabWidget { void AddTab(QWidget *widget_view, const QString &name, const QIcon &icon, const QString &label); bool EnableTab(QWidget *widget_view); bool DisableTab(QWidget *widget_view); - int insertTab(int index, QWidget *page, const QIcon &icon, const QString &label); + int insertTab(const int idx, QWidget *page, const QIcon &icon, const QString &label); void addBottomWidget(QWidget* widget_view); void setBackgroundPixmap(const QPixmap& pixmap); @@ -84,7 +84,7 @@ class FancyTabWidget : public QTabWidget { void CurrentChanged(int); public slots: - void setCurrentIndex(int index); + void setCurrentIndex(int idx); void SetMode(Mode mode); // Mapper mapped signal needs this convenience function void SetMode(int mode) { SetMode(Mode(mode)); } diff --git a/src/widgets/favoritewidget.cpp b/src/widgets/favoritewidget.cpp index 79552e82..2db34ad8 100644 --- a/src/widgets/favoritewidget.cpp +++ b/src/widgets/favoritewidget.cpp @@ -32,7 +32,7 @@ const int FavoriteWidget::kStarSize = 15; -FavoriteWidget::FavoriteWidget(int tab_index, bool favorite, QWidget *parent) +FavoriteWidget::FavoriteWidget(const int tab_index, const bool favorite, QWidget *parent) : QWidget(parent), tab_index_(tab_index), favorite_(favorite), diff --git a/src/widgets/favoritewidget.h b/src/widgets/favoritewidget.h index 456f484b..537c1dfe 100644 --- a/src/widgets/favoritewidget.h +++ b/src/widgets/favoritewidget.h @@ -34,7 +34,7 @@ class FavoriteWidget : public QWidget { Q_OBJECT public: - explicit FavoriteWidget(int tab_id, bool favorite = false, QWidget *parent = nullptr); + explicit FavoriteWidget(const int tab_index, const bool favorite = false, QWidget *parent = nullptr); // Change the value if different from the current one and then update display and emit FavoriteStateChanged signal void SetFavorite(bool favorite);