author | sandman <sandman> | 2002-10-28 20:27:14 (UTC) |
---|---|---|
committer | sandman <sandman> | 2002-10-28 20:27:14 (UTC) |
commit | b963230163fc8069731374a19390fd0e5cb42532 (patch) (unidiff) | |
tree | a9a46c7d61e9529afee40f39b03ed01dd744e868 /core/settings/light-and-power/calibration.h | |
parent | 052303d29fe4a7b16858398f79f667e57ae569c9 (diff) | |
download | opie-b963230163fc8069731374a19390fd0e5cb42532.zip opie-b963230163fc8069731374a19390fd0e5cb42532.tar.gz opie-b963230163fc8069731374a19390fd0e5cb42532.tar.bz2 |
Major update:
- fixed some layout margins in the ui file
- cleanup in light.cpp (removed the old TT code)
- new sensor calibration dialog
- new copyright headers
!! The launcher does not yet use the sensor calibration data !!
Diffstat (limited to 'core/settings/light-and-power/calibration.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/settings/light-and-power/calibration.h | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/core/settings/light-and-power/calibration.h b/core/settings/light-and-power/calibration.h new file mode 100644 index 0000000..2bff69a --- a/dev/null +++ b/core/settings/light-and-power/calibration.h | |||
@@ -0,0 +1,71 @@ | |||
1 | /* | ||
2 | This file is part of the OPIE Project | ||
3 | =. Copyright (c) 2002 Maximilian Reiss <harlekin@handhelds.org> | ||
4 | .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org> | ||
5 | .>+-= | ||
6 | _;:, .> :=|. This file is free software; you can | ||
7 | .> <`_, > . <= redistribute it and/or modify it under | ||
8 | :`=1 )Y*s>-.-- : the terms of the GNU General Public | ||
9 | .="- .-=="i, .._ License as published by the Free Software | ||
10 | - . .-<_> .<> Foundation; either version 2 of the License, | ||
11 | ._= =} : or (at your option) any later version. | ||
12 | .%`+i> _;_. | ||
13 | .i_,=:_. -<s. This file is distributed in the hope that | ||
14 | + . -:. = it will be useful, but WITHOUT ANY WARRANTY; | ||
15 | : .. .:, . . . without even the implied warranty of | ||
16 | =_ + =;=|` MERCHANTABILITY or FITNESS FOR A | ||
17 | _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU General | ||
18 | ..}^=.= = ; Public License for more details. | ||
19 | ++= -. .` .: | ||
20 | : = ...= . :.=- You should have received a copy of the GNU | ||
21 | -. .:....=;==+<; General Public License along with this file; | ||
22 | -_. . . )=. = see the file COPYING. If not, write to the | ||
23 | -- :-=` Free Software Foundation, Inc., | ||
24 | 59 Temple Place - Suite 330, | ||
25 | Boston, MA 02111-1307, USA. | ||
26 | |||
27 | */ | ||
28 | #ifndef __CALIBRATION_H__ | ||
29 | #define __CALIBRATION_H__ | ||
30 | |||
31 | #include <qwidget.h> | ||
32 | |||
33 | class Calibration : public QWidget { | ||
34 | Q_OBJECT | ||
35 | |||
36 | public: | ||
37 | Calibration ( QWidget *parent = 0, const char *name = 0, WFlags fl = 0 ); | ||
38 | virtual ~Calibration ( ); | ||
39 | |||
40 | QSize scale ( ) const; | ||
41 | int lineSteps ( ) const; | ||
42 | int interval ( ) const; | ||
43 | QPoint startPoint ( ) const; | ||
44 | QPoint endPoint ( ) const; | ||
45 | |||
46 | public slots: | ||
47 | void setScale ( const QSize &s ); | ||
48 | void setLineSteps ( int step ); | ||
49 | void setInterval ( int iv ); | ||
50 | void setStartPoint ( const QPoint &p ); | ||
51 | void setEndPoint ( const QPoint &p ); | ||
52 | |||
53 | protected: | ||
54 | virtual void paintEvent ( QPaintEvent * ); | ||
55 | virtual void mousePressEvent ( QMouseEvent * ); | ||
56 | virtual void mouseMoveEvent ( QMouseEvent * ); | ||
57 | virtual void mouseReleaseEvent ( QMouseEvent * ); | ||
58 | |||
59 | void checkPoints ( ); | ||
60 | |||
61 | private: | ||
62 | QSize m_scale; | ||
63 | QPoint m_p [2]; | ||
64 | int m_dragged; | ||
65 | int m_steps; | ||
66 | int m_interval; | ||
67 | }; | ||
68 | |||
69 | #endif | ||
70 | |||
71 | |||