Commit 7c8b0ef2 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Add missing const + Q_REQUIRED_RESULT

parent dc60839a
Pipeline #89016 passed with stage
in 30 minutes and 19 seconds
...@@ -18,7 +18,7 @@ HierarchicalFolderMatcher::HierarchicalFolderMatcher() ...@@ -18,7 +18,7 @@ HierarchicalFolderMatcher::HierarchicalFolderMatcher()
{ {
} }
bool HierarchicalFolderMatcher::isNull() bool HierarchicalFolderMatcher::isNull() const
{ {
return filterRegExps.empty(); return filterRegExps.empty();
} }
......
...@@ -23,13 +23,13 @@ class HierarchicalFolderMatcher ...@@ -23,13 +23,13 @@ class HierarchicalFolderMatcher
public: public:
HierarchicalFolderMatcher(); HierarchicalFolderMatcher();
bool isNull(); Q_REQUIRED_RESULT bool isNull() const;
void setFilter(const QString &filter, Qt::CaseSensitivity caseSensitivity); void setFilter(const QString &filter, Qt::CaseSensitivity caseSensitivity);
bool matches(const QAbstractItemModel *model, const QModelIndex &start, int role = Qt::DisplayRole); Q_REQUIRED_RESULT bool matches(const QAbstractItemModel *model, const QModelIndex &start, int role = Qt::DisplayRole);
QModelIndex findFirstMatch(const QAbstractItemModel *model, const QModelIndex &start, int role = Qt::DisplayRole); Q_REQUIRED_RESULT QModelIndex findFirstMatch(const QAbstractItemModel *model, const QModelIndex &start, int role = Qt::DisplayRole);
private: private:
std::vector<QRegularExpression> filterRegExps; std::vector<QRegularExpression> filterRegExps;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment