diff options
Diffstat (limited to 'Swift/QtUI/Roster')
-rw-r--r-- | Swift/QtUI/Roster/QtFilterWidget.cpp | 17 | ||||
-rw-r--r-- | Swift/QtUI/Roster/QtFilterWidget.h | 6 |
2 files changed, 14 insertions, 9 deletions
diff --git a/Swift/QtUI/Roster/QtFilterWidget.cpp b/Swift/QtUI/Roster/QtFilterWidget.cpp index 2f08981..a4c9449 100644 --- a/Swift/QtUI/Roster/QtFilterWidget.cpp +++ b/Swift/QtUI/Roster/QtFilterWidget.cpp @@ -1,17 +1,24 @@ /* + * Copyright (c) 2014 Kevin Smith and Remko Tronçon + * Licensed under the GNU General Public License v3. + * See Documentation/Licenses/GPLv3.txt for more information. + */ + +/* * Copyright (c) 2013 Tobias Markmann * Licensed under the simplified BSD license. * See Documentation/Licenses/BSD-simplified.txt for more information. */ -#include <QLayout> -#include <QVBoxLayout> -#include <QKeyEvent> #include <QEvent> +#include <QKeyEvent> +#include <QLayout> #include <QString> -#include <QEvent> +#include <QVBoxLayout> + #include <Swift/Controllers/UIEvents/RequestChatUIEvent.h> #include <Swift/Controllers/UIEvents/UIEventStream.h> +#include <Swift/QtUI/QtClosableLineEdit.h> #include <Swift/QtUI/QtSwiftUtil.h> #include <Swift/QtUI/Roster/QtFilterWidget.h> @@ -24,7 +31,7 @@ QtFilterWidget::QtFilterWidget(QWidget* parent, QtTreeWidget* treeView, UIEventS vboxLayout->setSpacing(0); vboxLayout->setContentsMargins(0,0,0,0); - filterLineEdit_ = new QLineEdit(this); + filterLineEdit_ = new QtClosableLineEdit(this); filterLineEdit_->hide(); vboxLayout->addWidget(filterLineEdit_); diff --git a/Swift/QtUI/Roster/QtFilterWidget.h b/Swift/QtUI/Roster/QtFilterWidget.h index 94ebc2a..3e17566 100644 --- a/Swift/QtUI/Roster/QtFilterWidget.h +++ b/Swift/QtUI/Roster/QtFilterWidget.h @@ -9,7 +9,6 @@ #include <vector> #include <QBoxLayout> -#include <QLineEdit> #include <QWidget> #include <Swift/Controllers/Roster/RosterFilter.h> @@ -18,9 +17,8 @@ #include <Swift/QtUI/Roster/QtTreeWidget.h> namespace Swift { - class UIEventStream; - +class QtClosableLineEdit; class QtFilterWidget : public QWidget { Q_OBJECT public: @@ -38,7 +36,7 @@ class QtFilterWidget : public QWidget { void updateSearchFilter(); private: - QLineEdit* filterLineEdit_; + QtClosableLineEdit* filterLineEdit_; QtTreeWidget* treeView_; UIEventStream* eventStream_; std::vector<RosterFilter*> filters_; |