mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 17:35:34 +08:00
refs #937 Resolved clazy warnings: pass-by-value/reference.
This commit is contained in:
@@ -53,7 +53,7 @@ namespace BlackMisc
|
||||
CTextMessageList::CTextMessageList(const QString &message, const QList<CFrequency> &frequencies, const BlackMisc::Aviation::CCallsign &fromCallsign)
|
||||
{
|
||||
if (frequencies.isEmpty()) return;
|
||||
foreach(CFrequency frequency, frequencies)
|
||||
for (const CFrequency &frequency : frequencies)
|
||||
{
|
||||
CTextMessage pm(message, frequency, fromCallsign);
|
||||
this->push_back(pm);
|
||||
|
||||
@@ -166,7 +166,7 @@ namespace BlackMisc
|
||||
return url;
|
||||
}
|
||||
|
||||
bool CUrl::pathEndsWith(const QString ending, Qt::CaseSensitivity cs) const
|
||||
bool CUrl::pathEndsWith(const QString &ending, Qt::CaseSensitivity cs) const
|
||||
{
|
||||
return m_path.endsWith(ending, cs);
|
||||
}
|
||||
@@ -220,7 +220,7 @@ namespace BlackMisc
|
||||
return QUrl::fromLocalFile(localFile);
|
||||
}
|
||||
|
||||
QString CUrl::stripQueryString(const QString query)
|
||||
QString CUrl::stripQueryString(const QString &query)
|
||||
{
|
||||
QString q(query.trimmed());
|
||||
if (q.startsWith("?") || q.startsWith("&"))
|
||||
|
||||
@@ -137,7 +137,7 @@ namespace BlackMisc
|
||||
CUrl withSwitchedScheme(const QString &protocol, int port) const;
|
||||
|
||||
//! Path ending with?
|
||||
bool pathEndsWith(const QString ending, Qt::CaseSensitivity cs = Qt::CaseInsensitive) const;
|
||||
bool pathEndsWith(const QString &ending, Qt::CaseSensitivity cs = Qt::CaseInsensitive) const;
|
||||
|
||||
//! \copydoc BlackMisc::Mixin::Index::propertyByIndex
|
||||
CVariant propertyByIndex(const BlackMisc::CPropertyIndex &index) const;
|
||||
@@ -173,7 +173,7 @@ namespace BlackMisc
|
||||
QString m_path;
|
||||
QString m_query;
|
||||
|
||||
static QString stripQueryString(const QString query);
|
||||
static QString stripQueryString(const QString &query);
|
||||
|
||||
BLACK_METACLASS(
|
||||
CUrl,
|
||||
|
||||
Reference in New Issue
Block a user