summaryrefslogtreecommitdiff
path: root/noncore/apps/tableviewer/ui/browsekeyentry.h
Unidiff
Diffstat (limited to 'noncore/apps/tableviewer/ui/browsekeyentry.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/tableviewer/ui/browsekeyentry.h75
1 files changed, 75 insertions, 0 deletions
diff --git a/noncore/apps/tableviewer/ui/browsekeyentry.h b/noncore/apps/tableviewer/ui/browsekeyentry.h
new file mode 100644
index 0000000..220bf6a
--- a/dev/null
+++ b/noncore/apps/tableviewer/ui/browsekeyentry.h
@@ -0,0 +1,75 @@
1/**********************************************************************
2** Copyright (C) 2000 Trolltech AS. All rights reserved.
3**
4** This file is part of Qtopia Environment.
5**
6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file.
10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13**
14** See http://www.trolltech.com/gpl/ for GPL licensing information.
15**
16** Contact info@trolltech.com if any conditions of this licensing are
17** not clear to you.
18**
19**********************************************************************/
20#ifndef BrowseKeyEntry_H
21#define BrowseKeyEntry_H
22
23#include <qwidget.h>
24#include "../db/common.h"
25
26/* Forward class declarations */
27class QWidgetStack;
28class QToolButton;
29class QPushButton;
30class QLineEdit;
31class DateEdit;
32class TimeEdit;
33class IntEdit;
34class QPopupMenu;
35class QHBox;
36
37class TVBrowseKeyEntry: public QWidget
38{
39 Q_OBJECT
40public:
41 TVBrowseKeyEntry( QWidget *parent = 0,
42 const char *name = 0, WFlags f = 0 );
43 ~TVBrowseKeyEntry();
44
45 void setTableState(TableState *t);
46 void rebuildKeys();
47 void reset();
48
49signals:
50 void searchOnKey(int keyIndex, TVVariant keyData);
51 void sortChanged(int i);
52
53private slots:
54 void changeKeySlot(int);
55 void changeKeyMenuSlot();
56 void searchOnText();
57
58private:
59 QPushButton *resetButton;
60 QToolButton *changeKeyButton;
61 QPopupMenu *keyMenu;
62 int totalKeys;
63 TableState *ts;
64
65 /* each type of possible data entry will be put on the stack */
66 QWidgetStack *ws;
67
68 /* include widgets for each type of data entry you need here. */
69 QLineEdit *textKey;
70 IntEdit *intKey;
71 DateEdit *dateKey;
72 TimeEdit *timeKey;
73};
74
75#endif