Diffstat (limited to 'noncore/tools/euroconv/calckeypad.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/tools/euroconv/calckeypad.h | 78 |
1 files changed, 78 insertions, 0 deletions
diff --git a/noncore/tools/euroconv/calckeypad.h b/noncore/tools/euroconv/calckeypad.h new file mode 100644 index 0000000..42e7eb3 --- a/dev/null +++ b/noncore/tools/euroconv/calckeypad.h | |||
@@ -0,0 +1,78 @@ | |||
1 | /**************************************************************************** | ||
2 | * | ||
3 | * File: calckeypad.h | ||
4 | * | ||
5 | * Description: Header file for the class KeyPad | ||
6 | * | ||
7 | * | ||
8 | * Authors: Eric Santonacci <Eric.Santonacci@talc.fr> | ||
9 | * | ||
10 | * Requirements: Qt | ||
11 | * | ||
12 | * $Id$ | ||
13 | * | ||
14 | * | ||
15 | ***************************************************************************/ | ||
16 | #ifndef CALCKEYPAD_H | ||
17 | #define CALCKEYPAD_H | ||
18 | |||
19 | #include <qpushbutton.h> | ||
20 | #include <qgrid.h> | ||
21 | #include <qbuttongroup.h> | ||
22 | |||
23 | #include "calcdisplay.h" | ||
24 | |||
25 | class KeyPad : public QGrid { | ||
26 | |||
27 | Q_OBJECT | ||
28 | public: | ||
29 | KeyPad(LCDDisplay *LCD, QWidget *parent=0, const char *name=0 ); | ||
30 | |||
31 | public slots: | ||
32 | void enterDigits(int); | ||
33 | void operatorPressed(int); | ||
34 | void clearLCD(void); | ||
35 | void aboutDialog(void); | ||
36 | void gotoDec(void); | ||
37 | |||
38 | private: | ||
39 | LCDDisplay *display; | ||
40 | double dCurrent; | ||
41 | int iLenCurrent; | ||
42 | bool bIsDec; | ||
43 | double dDecCurrent; | ||
44 | int iPreviousOperator; | ||
45 | double dPreviousValue; | ||
46 | |||
47 | QPushButton *btn0; | ||
48 | QPushButton *btn1; | ||
49 | QPushButton *btn2; | ||
50 | QPushButton *btn3; | ||
51 | QPushButton *btn4; | ||
52 | QPushButton *btn5; | ||
53 | QPushButton *btn6; | ||
54 | QPushButton *btn7; | ||
55 | QPushButton *btn8; | ||
56 | QPushButton *btn9; | ||
57 | QButtonGroup *grpbtnDigits; | ||
58 | |||
59 | QPushButton *btnDot; | ||
60 | |||
61 | QPushButton *btnClear; | ||
62 | |||
63 | QPushButton *btnPlus; | ||
64 | QPushButton *btnMinus; | ||
65 | QPushButton *btnMultiply; | ||
66 | QPushButton *btnDivide; | ||
67 | QPushButton *btnEqual; | ||
68 | QPushButton *btnPercent; | ||
69 | QPushButton *btnF1; | ||
70 | QPushButton *btnAbout; | ||
71 | |||
72 | QButtonGroup *grpbtnOperators; | ||
73 | |||
74 | |||
75 | |||
76 | }; | ||
77 | |||
78 | #endif // CALCKEYPAD_H | ||