UltraScan III
us_selectbox.h
Go to the documentation of this file.
1 #ifndef US_SELECTBOX_H
3 #define US_SELECTBOX_H
4 
5 #include <QtGui>
6 
7 #include "us_extern.h"
8 
9 struct listInfo
10 {
11  QString ID;
12  QString text;
13 };
14 
24 {
25  public:
31  US_SelectBase ();
32 
35 
36  protected:
37  QList< listInfo > widgetList;
38 
39 };
40 
48 class US_SelectBox : public QComboBox, public US_SelectBase
49 {
50  public:
56  US_SelectBox ( QWidget* parent = 0 );
57 
60 
66  void addOption ( listInfo& );
67 
73  void addOptions ( QList< listInfo >& );
74 
78  void load ( void );
79 
85  void setLogicalIndex ( int );
86 
90  int getLogicalID ( void );
91 };
92 
100 class US_ListwidgetBox : public QListWidget, public US_SelectBase
101 {
102  public:
110  US_ListwidgetBox ( QWidget* parent = 0, int fontAdjust = 0 );
111 
114 
120  void addOption ( listInfo& );
121 
127  void addOptions ( QList< listInfo >& );
128 
132  void load ( void );
133 
139  void setLogicalIndex ( int );
140 
144  int getLogicalID ( void );
145 };
146 
147 #endif