diff options
| author | Ismael Asensio <[email protected]> | 2019-10-27 22:38:15 +0100 |
|---|---|---|
| committer | Elvis Angelaccio <[email protected]> | 2019-10-27 22:52:01 +0100 |
| commit | 1c50de3b380922eea36c59d5cf8dacb58c70d64d (patch) | |
| tree | b666a4823dfb8338b47a549d72b4f9429d362a55 /src/search/dolphinfacetswidget.h | |
| parent | c3b914a7faed3a7c0195ae77b40204cbc8d31fe5 (diff) | |
New design for extended search options
Summary:
Replace the arrays of radiobuttons in dolphin search box to more simple dropdown boxes.
This provides a leaner look, saving a lot user space on the main view and it is more consistent with the 'Search tools' in the most known sites (Google, DuckDuckGo, etc.)
There is room for improvement, as `QComboBox` doesn't match perfectly with the tool buttons used avobe, but I think it is an improvement over the current situation.
BEFORE:
{F7581883}
AFTER:
{F7580952}
Test Plan: Same behavior with different aesthetics
Reviewers: elvisangelaccio, #dolphin, #vdg
Subscribers: ndavis, ngraham, kfm-devel
Tags: #dolphin
Differential Revision: https://phabricator.kde.org/D24602
Diffstat (limited to 'src/search/dolphinfacetswidget.h')
| -rw-r--r-- | src/search/dolphinfacetswidget.h | 35 |
1 files changed, 5 insertions, 30 deletions
diff --git a/src/search/dolphinfacetswidget.h b/src/search/dolphinfacetswidget.h index 9d875f0ae..0a8a5161f 100644 --- a/src/search/dolphinfacetswidget.h +++ b/src/search/dolphinfacetswidget.h @@ -22,10 +22,9 @@ #include <QWidget> -class QButtonGroup; +class QComboBox; class QDate; class QEvent; -class QRadioButton; /** * @brief Allows to filter search-queries by facets. @@ -70,36 +69,12 @@ protected: private: void setRating(const int stars); void setTimespan(const QDate& date); - - /** - * @return New radiobutton which is connected to the - * slotFacedChanged() slot whenever it has - * been toggled. - */ - QRadioButton* createRadioButton(const QString& text, - QButtonGroup* group); + void initComboBox(QComboBox* combo); private: - QRadioButton* m_anyType; - QRadioButton* m_folders; - QRadioButton* m_documents; - QRadioButton* m_images; - QRadioButton* m_audio; - QRadioButton* m_videos; - - QRadioButton* m_anytime; - QRadioButton* m_today; - QRadioButton* m_yesterday; - QRadioButton* m_thisWeek; - QRadioButton* m_thisMonth; - QRadioButton* m_thisYear; - - QRadioButton* m_anyRating; - QRadioButton* m_oneOrMore; - QRadioButton* m_twoOrMore; - QRadioButton* m_threeOrMore; - QRadioButton* m_fourOrMore; - QRadioButton* m_maxRating; + QComboBox* m_typeSelector; + QComboBox* m_dateSelector; + QComboBox* m_ratingSelector; }; #endif |
