┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/search/dolphinfacetswidget.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/search/dolphinfacetswidget.h')
-rw-r--r--src/search/dolphinfacetswidget.h23
1 files changed, 18 insertions, 5 deletions
diff --git a/src/search/dolphinfacetswidget.h b/src/search/dolphinfacetswidget.h
index 0a8a5161f..2e91bcc96 100644
--- a/src/search/dolphinfacetswidget.h
+++ b/src/search/dolphinfacetswidget.h
@@ -21,10 +21,12 @@
#define DOLPHINFACETSWIDGET_H
#include <QWidget>
+#include <KCoreDirLister>
class QComboBox;
class QDate;
class QEvent;
+class QToolButton;
/**
* @brief Allows to filter search-queries by facets.
@@ -50,13 +52,12 @@ public:
explicit DolphinFacetsWidget(QWidget* parent = nullptr);
~DolphinFacetsWidget() override;
- void resetOptions();
-
- QString ratingTerm() const;
+ QStringList searchTerms() const;
QString facetType() const;
- bool isRatingTerm(const QString& term) const;
- void setRatingTerm(const QString& term);
+ bool isSearchTerm(const QString& term) const;
+ void setSearchTerm(const QString& term);
+ void resetSearchTerms();
void setFacetType(const QString& type);
@@ -66,15 +67,27 @@ signals:
protected:
void changeEvent(QEvent* event) override;
+private slots:
+ void updateTagsMenu();
+ void updateTagsMenuItems(const QUrl&, const KFileItemList& items);
+
private:
void setRating(const int stars);
void setTimespan(const QDate& date);
+ void addSearchTag(const QString& tag);
+ void removeSearchTag(const QString& tag);
+
void initComboBox(QComboBox* combo);
+ void updateTagsSelector();
private:
QComboBox* m_typeSelector;
QComboBox* m_dateSelector;
QComboBox* m_ratingSelector;
+ QToolButton* m_tagsSelector;
+
+ QStringList m_searchTags;
+ KCoreDirLister m_tagsLister;
};
#endif