summaryrefslogtreecommitdiff
path: root/src/plugins/git/gerrit/gerritdialog.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/git/gerrit/gerritdialog.h')
-rw-r--r--src/plugins/git/gerrit/gerritdialog.h24
1 files changed, 21 insertions, 3 deletions
diff --git a/src/plugins/git/gerrit/gerritdialog.h b/src/plugins/git/gerrit/gerritdialog.h
index a1a48d9c6c..5ee65f500f 100644
--- a/src/plugins/git/gerrit/gerritdialog.h
+++ b/src/plugins/git/gerrit/gerritdialog.h
@@ -33,6 +33,8 @@
#ifndef GERRIT_INTERNAL_GERRITDIALOG_H
#define GERRIT_INTERNAL_GERRITDIALOG_H
+#include <utils/filterlineedit.h>
+
#include <QDialog>
#include <QSharedPointer>
@@ -47,15 +49,30 @@ class QDialogButtonBox;
class QTextBrowser;
QT_END_NAMESPACE
-namespace Utils {
-class FilterLineEdit;
-}
namespace Gerrit {
namespace Internal {
class GerritParameters;
class GerritModel;
class GerritChange;
+class QueryValidatingLineEdit : public Utils::FilterLineEdit
+{
+ Q_OBJECT
+
+public:
+ explicit QueryValidatingLineEdit(QWidget *parent = 0);
+ void setTextColor(const QColor &c);
+
+public slots:
+ void setValid();
+ void setInvalid();
+
+private:
+ bool m_valid;
+ const QColor m_okTextColor;
+ const QColor m_errorTextColor;
+};
+
class GerritDialog : public QDialog
{
Q_OBJECT
@@ -88,6 +105,7 @@ private:
GerritModel *m_model;
QTreeView *m_treeView;
QTextBrowser *m_detailsBrowser;
+ QueryValidatingLineEdit *m_queryLineEdit;
Utils::FilterLineEdit *m_filterLineEdit;
QDialogButtonBox *m_buttonBox;
QPushButton *m_displayButton;