Diffstat (limited to 'core/apps/calibrate/calibrate.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/apps/calibrate/calibrate.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/apps/calibrate/calibrate.h b/core/apps/calibrate/calibrate.h index 97108c9..06aa0c9 100644 --- a/core/apps/calibrate/calibrate.h +++ b/core/apps/calibrate/calibrate.h | |||
@@ -1,67 +1,69 @@ | |||
1 | /********************************************************************** | 1 | /********************************************************************** |
2 | ** Copyright (C) 2000 Trolltech AS. All rights reserved. | 2 | ** Copyright (C) 2000 Trolltech AS. All rights reserved. |
3 | ** | 3 | ** |
4 | ** This file is part of Qtopia Environment. | 4 | ** This file is part of Qtopia Environment. |
5 | ** | 5 | ** |
6 | ** This file may be distributed and/or modified under the terms of the | 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 | 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 | 8 | ** Foundation and appearing in the file LICENSE.GPL included in the |
9 | ** packaging of this file. | 9 | ** packaging of this file. |
10 | ** | 10 | ** |
11 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE | 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. | 12 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. |
13 | ** | 13 | ** |
14 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. | 14 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. |
15 | ** | 15 | ** |
16 | ** Contact info@trolltech.com if any conditions of this licensing are | 16 | ** Contact info@trolltech.com if any conditions of this licensing are |
17 | ** not clear to you. | 17 | ** not clear to you. |
18 | ** | 18 | ** |
19 | **********************************************************************/ | 19 | **********************************************************************/ |
20 | 20 | ||
21 | #include <qwsmouse_qws.h> | 21 | #include <qwsmouse_qws.h> |
22 | 22 | ||
23 | #if defined(Q_WS_QWS) || defined(_WS_QWS_) | 23 | //#if defined(Q_WS_QWS) || defined(_WS_QWS_) |
24 | 24 | ||
25 | #include <qdialog.h> | 25 | #include <qdialog.h> |
26 | #include <qpixmap.h> | 26 | #include <qpixmap.h> |
27 | 27 | ||
28 | class QTimer; | 28 | class QTimer; |
29 | 29 | ||
30 | class Calibrate : public QDialog | 30 | class Calibrate : public QDialog |
31 | { | 31 | { |
32 | Q_OBJECT | 32 | Q_OBJECT |
33 | public: | 33 | public: |
34 | Calibrate(QWidget* parent=0, const char * name=0, WFlags=0); | 34 | Calibrate(QWidget* parent=0, const char * name=0, WFlags=0); |
35 | ~Calibrate(); | 35 | ~Calibrate(); |
36 | 36 | ||
37 | void show(); | 37 | void show(); |
38 | void hide(); | 38 | void hide(); |
39 | 39 | ||
40 | private: | 40 | private: |
41 | QPoint fromDevice( const QPoint &p ); | 41 | QPoint fromDevice( const QPoint &p ); |
42 | bool sanityCheck(); | 42 | bool sanityCheck(); |
43 | void moveCrosshair( QPoint pt ); | 43 | void moveCrosshair( QPoint pt ); |
44 | void paintEvent( QPaintEvent * ); | 44 | void paintEvent( QPaintEvent * ); |
45 | void mousePressEvent( QMouseEvent * ); | 45 | void mousePressEvent( QMouseEvent * ); |
46 | void mouseReleaseEvent( QMouseEvent * ); | 46 | void mouseReleaseEvent( QMouseEvent * ); |
47 | 47 | ||
48 | private slots: | 48 | private slots: |
49 | void timeout(); | 49 | void timeout(); |
50 | 50 | ||
51 | private: | 51 | private: |
52 | void store(); | 52 | void store(); |
53 | void reset(); | 53 | void reset(); |
54 | QPixmap logo; | 54 | QPixmap logo; |
55 | #ifdef QWS | ||
55 | QWSPointerCalibrationData goodcd,cd; | 56 | QWSPointerCalibrationData goodcd,cd; |
56 | QWSPointerCalibrationData::Location location; | 57 | QWSPointerCalibrationData::Location location; |
58 | #endif | ||
57 | QPoint crossPos; | 59 | QPoint crossPos; |
58 | QPoint penPos; | 60 | QPoint penPos; |
59 | QPixmap saveUnder; | 61 | QPixmap saveUnder; |
60 | QTimer *timer; | 62 | QTimer *timer; |
61 | int dx; | 63 | int dx; |
62 | int dy; | 64 | int dy; |
63 | bool showCross; | 65 | bool showCross; |
64 | }; | 66 | }; |
65 | 67 | ||
66 | #endif // _WS_QWS_ | 68 | //#endif // _WS_QWS_ |
67 | 69 | ||