resize vnc_view when available space changes, rotation still missing
[presencevnc] / src / mainwindow.h
1 #ifndef MAINWINDOW_H
2 #define MAINWINDOW_H
3
4 #include <QtGui>
5
6 #include "remoteview.h"
7 #include "vncview.h"
8
9 class MainWindow : public QMainWindow {
10         Q_OBJECT
11 public:
12         MainWindow(QString url, int quality);
13 public slots:
14         void about();
15         void connectDialog();
16         void disconnectFromHost();
17         void forceResize();
18         void forceResizeDelayed();
19         void sendTab() { vnc_view->sendKey(Qt::Key_Tab); }
20         void sendEsc() { vnc_view->sendKey(Qt::Key_Escape); }
21         void sendPgUp() { vnc_view->sendKey(Qt::Key_PageUp); }
22         void sendPgDn() { vnc_view->sendKey(Qt::Key_PageDown); }
23         void statusChanged(RemoteView::RemoteStatus status);
24         void toggleFullscreen();
25 protected:
26         //virtual bool event(QEvent *event);
27         void closeEvent(QCloseEvent*);
28 private:
29         void grabZoomKeys(bool grab);
30         VncView *vnc_view;
31         QScrollArea *scroll_area;
32         //QWidget *menu;
33         QToolBar *toolbar;      
34         //QPoint swipe_start;
35         QAction *scaling;
36         QAction *disconnect_action;
37 };
38 #endif