summaryrefslogtreecommitdiff
path: root/noncore/comm/keypebble/krfbcanvas.h
authorkergoth <kergoth>2002-01-25 22:14:26 (UTC)
committer kergoth <kergoth>2002-01-25 22:14:26 (UTC)
commit15318cad33835e4e2dc620d033e43cd930676cdd (patch) (unidiff)
treec2fa0399a2c47fda8e2cd0092c73a809d17f68eb /noncore/comm/keypebble/krfbcanvas.h
downloadopie-15318cad33835e4e2dc620d033e43cd930676cdd.zip
opie-15318cad33835e4e2dc620d033e43cd930676cdd.tar.gz
opie-15318cad33835e4e2dc620d033e43cd930676cdd.tar.bz2
Initial revision
Diffstat (limited to 'noncore/comm/keypebble/krfbcanvas.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/comm/keypebble/krfbcanvas.h54
1 files changed, 54 insertions, 0 deletions
diff --git a/noncore/comm/keypebble/krfbcanvas.h b/noncore/comm/keypebble/krfbcanvas.h
new file mode 100644
index 0000000..7864f1c
--- a/dev/null
+++ b/noncore/comm/keypebble/krfbcanvas.h
@@ -0,0 +1,54 @@
1// -*- c++ -*-
2
3#ifndef KRFBCANVAS_H
4#define KRFBCANVAS_H
5
6#include <qscrollview.h>
7#include <qurl.h>
8
9class KRFBConnection;
10
11/**
12 * Displays data from an KRFBDecoder, and sends events to the
13 * KRFBConnection.
14 */
15class KRFBCanvas : public QScrollView
16{
17 Q_OBJECT
18public:
19 KRFBCanvas( QWidget *parent, const char *name=0 );
20 ~KRFBCanvas();
21
22 void setConnection( KRFBConnection * );
23 KRFBConnection *connection() { return connection_; };
24
25public slots:
26 void openConnection();
27 void openURL( const QUrl & );
28 void closeConnection();
29 void passwordRequired( KRFBConnection * );
30
31 void refresh();
32 void bell();
33
34protected:
35 virtual void keyPressEvent( QKeyEvent * );
36 virtual void keyReleaseEvent( QKeyEvent * );
37 virtual void contentsMousePressEvent( QMouseEvent * );
38 virtual void contentsMouseReleaseEvent( QMouseEvent * );
39 virtual void contentsMouseMoveEvent( QMouseEvent * );
40
41 virtual void viewportPaintEvent( QPaintEvent *e );
42
43protected slots:
44 void loggedIn();
45 void viewportUpdate( int x, int y, int w, int h );
46 void clipboardChanged();
47
48private:
49 KRFBConnection *connection_;
50 QString password;
51 bool loggedIn_;
52};
53
54#endif // KRFBCANVAS_H