]> git.zerfleddert.de Git - proxmark3-svn/blame - client/proxguiqt.h
make a start on updating the main README
[proxmark3-svn] / client / proxguiqt.h
CommitLineData
a553f267 1//-----------------------------------------------------------------------------
2// This code is licensed to you under the terms of the GNU GPL, version 2 or,
3// at your option, any later version. See the LICENSE.txt file for the text of
4// the license.
5//-----------------------------------------------------------------------------
6// GUI (QT)
7//-----------------------------------------------------------------------------
8
6658905f 9#include <QApplication>
10#include <QPushButton>
11#include <QObject>
12#include <QWidget>
13#include <QPainter>
14
15class ProxWidget : public QWidget
16{
17 Q_OBJECT;
18
19 private:
20 int GraphStart;
21 double GraphPixelsPerPoint;
22 int CursorAPos;
23 int CursorBPos;
24
25 public:
26 ProxWidget(QWidget *parent = 0);
27
28 protected:
29 void paintEvent(QPaintEvent *event);
30 void closeEvent(QCloseEvent *event);
31 void mouseMoveEvent(QMouseEvent *event);
32 void mousePressEvent(QMouseEvent *event) { mouseMoveEvent(event); }
33 void keyPressEvent(QKeyEvent *event);
34};
35
36class ProxGuiQT : public QObject
37{
38 Q_OBJECT;
39
40 private:
41 QApplication *plotapp;
42 ProxWidget *plotwidget;
43 int argc;
44 char **argv;
45 void (*main_func)(void);
46
47 public:
48 ProxGuiQT(int argc, char **argv);
49 ~ProxGuiQT(void);
50 void ShowGraphWindow(void);
51 void RepaintGraphWindow(void);
52 void HideGraphWindow(void);
53 void MainLoop(void);
54
55 private slots:
56 void _ShowGraphWindow(void);
57 void _RepaintGraphWindow(void);
58 void _HideGraphWindow(void);
59
60 signals:
61 void ShowGraphWindowSignal(void);
62 void RepaintGraphWindowSignal(void);
63 void HideGraphWindowSignal(void);
64};
Impressum, Datenschutz