Crossfire Server, Trunk  R20513
CREStringListPanel.h
Go to the documentation of this file.
1 #ifndef _CRESTRINGLISTPANEL_H
2 #define _CRESTRINGLISTPANEL_H
3 
4 #include <QWidget>
5 
6 #include "CREMessagePanel.h"
7 
8 class QListWidget;
9 class QLineEdit;
10 class QTextEdit;
11 
12 class CREStringListPanel : public QWidget
13 {
14  Q_OBJECT
15 
16  public:
17  CREStringListPanel(QWidget* parent);
18  virtual ~CREStringListPanel();
19 
20  void clearData();
21  void setData(const QStringList& list);
22  QStringList getData() const;
23 
24  signals:
25  void dataModified();
26 
27  private:
29  QListWidget* myItems;
30  QTextEdit* myTextEdit;
31 
32  void commitData();
33  protected slots:
34  void onAddItem(bool);
35  void onDeleteItem(bool);
36  void onCurrentItemChanged(int currentRow);
37  void onTextEditChanged();
38 };
39 
40 #endif /* _CRESTRINGLISTPANEL_H */
void onCurrentItemChanged(int currentRow)
void setData(const QStringList &list)
QStringList getData() const
CREStringListPanel(QWidget *parent)