Diffstat (limited to 'core/applets/screenshotapplet/screenshot.h') (more/less context) (show whitespace changes)
-rw-r--r-- | core/applets/screenshotapplet/screenshot.h | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/core/applets/screenshotapplet/screenshot.h b/core/applets/screenshotapplet/screenshot.h new file mode 100644 index 0000000..82800b9 --- a/dev/null +++ b/core/applets/screenshotapplet/screenshot.h | |||
@@ -0,0 +1,76 @@ | |||
1 | /********************************************************************** | ||
2 | ** Copyright (C) 2002 L.J. Potter ljp@llornkcor.com | ||
3 | ** All rights reserved. | ||
4 | ** | ||
5 | ** This file may be distributed and/or modified under the terms of the | ||
6 | ** GNU General Public License version 2 as published by the Free Software | ||
7 | ** Foundation and appearing in the file LICENSE.GPL included in the | ||
8 | ** packaging of this file. | ||
9 | ** | ||
10 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE | ||
11 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | ||
12 | ** | ||
13 | **********************************************************************/ | ||
14 | |||
15 | #ifndef __SCREENSHOT_APPLET_H__ | ||
16 | #define __SCREENSHOT_APPLET_H__ | ||
17 | |||
18 | |||
19 | |||
20 | #include <qwidget.h> | ||
21 | #include <qframe.h> | ||
22 | #include <qpixmap.h> | ||
23 | #include <qguardedptr.h> | ||
24 | #include <qtimer.h> | ||
25 | |||
26 | class QComboBox; | ||
27 | class QCheckBox; | ||
28 | class QSpinBox; | ||
29 | class QPushButton; | ||
30 | //class QImage; | ||
31 | |||
32 | class ScreenshotControl : public QFrame | ||
33 | { | ||
34 | Q_OBJECT | ||
35 | public: | ||
36 | ScreenshotControl( QWidget *parent=0, const char *name=0 ); | ||
37 | void performGrab(); | ||
38 | |||
39 | public: | ||
40 | QPushButton *grabItButton; | ||
41 | QPixmap snapshot; | ||
42 | QTimer* grabTimer; | ||
43 | void slotSave(); | ||
44 | void slotCopy(); | ||
45 | void setTime(int newTime); | ||
46 | |||
47 | QSpinBox *delaySpin; | ||
48 | private: | ||
49 | private slots: | ||
50 | void slotGrab(); | ||
51 | void savePixmap(); | ||
52 | void grabTimerDone(); | ||
53 | }; | ||
54 | |||
55 | class ScreenshotApplet : public QWidget | ||
56 | { | ||
57 | Q_OBJECT | ||
58 | public: | ||
59 | ScreenshotApplet( QWidget *parent = 0, const char *name=0 ); | ||
60 | ~ScreenshotApplet(); | ||
61 | ScreenshotControl *vc; | ||
62 | public slots: | ||
63 | private: | ||
64 | void mousePressEvent( QMouseEvent * ); | ||
65 | void paintEvent( QPaintEvent* ); | ||
66 | |||
67 | private: | ||
68 | QPixmap snapshotPixmap; | ||
69 | private slots: | ||
70 | |||
71 | |||
72 | }; | ||
73 | |||
74 | |||
75 | #endif // __SCREENSHOT_APPLET_H__ | ||
76 | |||