diff options
| author | Denis Steckelmacher <[email protected]> | 2014-09-10 10:16:11 +0200 |
|---|---|---|
| committer | Denis Steckelmacher <[email protected]> | 2014-09-10 10:16:11 +0200 |
| commit | e3578ee3b770a1b8f359ed1a3cc6e3ac7f6c700e (patch) | |
| tree | d12f42038fc7f1ccb66b4705bb8a9283ac6fc210 /src/search/dolphinsearchbox.h | |
| parent | 39cfd051ef25f3a90fdfa411325829ca119a421c (diff) | |
Use the Baloo Query Builder widget to add syntax-highlighting in Dolphin search
REVIEW: 112589
Diffstat (limited to 'src/search/dolphinsearchbox.h')
| -rw-r--r-- | src/search/dolphinsearchbox.h | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/src/search/dolphinsearchbox.h b/src/search/dolphinsearchbox.h index 53b12ffab..eba81346d 100644 --- a/src/search/dolphinsearchbox.h +++ b/src/search/dolphinsearchbox.h @@ -24,6 +24,8 @@ #include <QList> #include <QWidget> +#include <config-baloo.h> + class DolphinFacetsWidget; class KLineEdit; class KSeparator; @@ -32,6 +34,11 @@ class QScrollArea; class QLabel; class QVBoxLayout; +namespace Baloo { + class QueryBuilder; + class NaturalQueryParser; +} + /** * @brief Input box for searching files with or without Baloo. * @@ -134,10 +141,11 @@ private slots: void emitSearchRequest(); void emitCloseRequest(); void slotConfigurationChanged(); - void slotSearchTextChanged(const QString& text); - void slotReturnPressed(const QString& text); + void slotSearchTextChanged(); + void slotReturnPressed(); void slotFacetsButtonToggled(); void slotFacetChanged(); + void updateSearchInputParsing(); private: void initButton(QToolButton* button); @@ -164,7 +172,12 @@ private: QVBoxLayout* m_topLayout; QLabel* m_searchLabel; +#ifdef HAVE_BALOO + Baloo::QueryBuilder* m_searchInput; + QScopedPointer<Baloo::NaturalQueryParser> m_queryParser; +#else KLineEdit* m_searchInput; +#endif QScrollArea* m_optionsScrollArea; QToolButton* m_fileNameButton; QToolButton* m_contentButton; |
