X-Git-Url: http://git.maemo.org/git/?p=presencevnc;a=blobdiff_plain;f=src%2Fvncview.h;h=82de5931899bb0a375237341f6465d0f1dc38a37;hp=0c3a22ea179fa0d584a0903989c99b1bd4ad43d5;hb=41bbfc24088b49a15ee31a810798d408de11dfc1;hpb=c45b940958d597ec3eddda4c59bc56710fbaf085 diff --git a/src/vncview.h b/src/vncview.h index 0c3a22e..82de593 100644 --- a/src/vncview.h +++ b/src/vncview.h @@ -27,10 +27,9 @@ #include "remoteview.h" #include "vncclientthread.h" -class KConfigGroup{}; +class KConfigGroup {}; #include -#include extern "C" { #include @@ -44,26 +43,28 @@ public: explicit VncView(QWidget *parent = 0, const KUrl &url = KUrl(), RemoteView::Quality quality = RemoteView::Medium, int listen_port = 0); ~VncView(); - QSize framebufferSize(); + QSize framebufferSize() const; QSize sizeHint() const; QSize minimumSizeHint() const; - bool isQuitting(); - qreal getZoomFactor() { return m_horizontalFactor;} //assumes fixed aspect ratio + bool isQuitting() const; + qreal zoomFactor() const { return m_horizontalFactor;} //assumes fixed aspect ratio void reloadSettings(); bool start(); bool supportsScaling() const; bool supportsLocalCursor() const; - + void setQuality(int q); void setViewOnly(bool viewOnly); void showDotCursor(DotCursorState state); - + void useFastTransformations(bool enabled); + QPoint cursorPosition() const { return QPoint(cursor_x, cursor_y); } + void setDisplayOff(bool off) { display_off = off; } + public slots: void setZoomLevel(int level = -1); //'level' doesn't correspond to actual magnification, though mapping is done here void sendKey(Qt::Key key); void sendKeySequence(QKeySequence keys); void startQuitting(); - void forceFullRepaint(); protected: void paintEvent(QPaintEvent *event); @@ -80,7 +81,6 @@ private: QMap m_mods; int m_x, m_y, m_w, m_h; int cursor_x, cursor_y; - bool m_repaint; bool m_quitFlag; bool m_firstPasswordTry; bool m_dontSendClipboard; @@ -88,16 +88,17 @@ private: qreal m_verticalFactor; QImage m_frame; bool m_forceLocalCursor; - bool force_full_repaint; int left_zoom, right_zoom; bool disable_tapping; RemoteView::Quality quality; - int listen_port; + int listen_port; + Qt::TransformationMode transformation_mode; + bool display_off; void keyEventHandler(QKeyEvent *e); void unpressModifiers(); void wheelEventHandler(QWheelEvent *event); - + private slots: void mouseEventHandler(QMouseEvent *event = 0);