]> cvs.zerfleddert.de Git - proxmark3-svn/blame - client/proxgui.cpp
Add license headers to armsrc/bootrom/common stuff
[proxmark3-svn] / client / proxgui.cpp
CommitLineData
6658905f 1#include "proxgui.h"
2#include "proxguiqt.h"
3
4static ProxGuiQT *gui = NULL;
5
6extern "C" void ShowGraphWindow(void)
7{
7fe9b0b7 8 if (!gui)
9 return;
10
11 gui->ShowGraphWindow();
6658905f 12}
13
14extern "C" void HideGraphWindow(void)
15{
7fe9b0b7 16 if (!gui)
17 return;
18
19 gui->HideGraphWindow();
6658905f 20}
21
22extern "C" void RepaintGraphWindow(void)
23{
7fe9b0b7 24 if (!gui)
25 return;
6658905f 26
7fe9b0b7 27 gui->RepaintGraphWindow();
6658905f 28}
29
30extern "C" void MainGraphics(void)
31{
7fe9b0b7 32 if (!gui)
33 return;
6658905f 34
7fe9b0b7 35 gui->MainLoop();
6658905f 36}
37
38extern "C" void InitGraphics(int argc, char **argv)
39{
40#ifdef Q_WS_X11
7fe9b0b7 41 bool useGUI = getenv("DISPLAY") != 0;
6658905f 42#else
7fe9b0b7 43 bool useGUI = true;
6658905f 44#endif
7fe9b0b7 45 if (!useGUI)
46 return;
6658905f 47
7fe9b0b7 48 gui = new ProxGuiQT(argc, argv);
6658905f 49}
50
51extern "C" void ExitGraphics(void)
52{
7fe9b0b7 53 if (!gui)
54 return;
55
56 delete gui;
57 gui = NULL;
6658905f 58}
Impressum, Datenschutz