00001
00002
00003 #ifndef KRFBBUFFER_H
00004 #define KRFBBUFFER_H
00005
00006 #include <qobject.h>
00007
00008 class QPixmap;
00009 class KRFBDecoder;
00010 class QMouseEvent;
00011 class QKeyEvent;
00012
00018 class KRFBBuffer : public QObject
00019 {
00020 Q_OBJECT
00021
00022 public:
00023 KRFBBuffer( KRFBDecoder *decoder, QObject *parent, const char *name=0 );
00024 ~KRFBBuffer();
00025
00026 QPixmap *pixmap() const { return pix; };
00027
00031 void drawRawRectChunk( void *data, int x, int y, int w, int h );
00032
00033 void copyRect( int srcX, int srcY,
00034 int destX, int destY, int w, int h );
00035
00036 void fillRect( int ,int , int , int , unsigned long ) {};
00037
00038 void resize( int w, int h );
00039
00040 void mouseEvent( QMouseEvent *e );
00041
00042 void keyPressEvent( QKeyEvent *e );
00043 void keyReleaseEvent( QKeyEvent *e );
00044
00045 void soundBell();
00046
00047 signals:
00051 void sizeChanged( int w, int h );
00052
00053 void updated( int x, int y, int w, int h );
00054
00055 void bell();
00056
00057 private:
00058 KRFBDecoder *decoder;
00059 QPixmap *pix;
00060 };
00061
00062 #endif // KRFBBUFFER_H