-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathServiceControl.cpp
More file actions
59 lines (51 loc) · 2.42 KB
/
Copy pathServiceControl.cpp
File metadata and controls
59 lines (51 loc) · 2.42 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#include <ServiceClass.h>
//#include <MenuClass.h>
//#include <WinClass.h>
#include <MenuWinClass.h>
#include <TaskClass.h>
#include <Info.h>
using namespace std;
TaskClass * TaskClassS = new TaskClass();
ServiceClass * ServiceClassS = new ServiceClass();
MenuWinClass *MenuWinClassS = new MenuWinClass();
int main (int argc, char* argv[]) {
//try {
if (argc > 1) {
if (string(argv[1]).compare("-h")) {
cout << HELP_INFO << " " << VERSION << endl;
return 0;
exit(EXIT_SUCCESS);
} else {
//fn = string(argv[1]);
//ed = Editor(fn);
}
}
int Key = 0;
werase(stdscr);
MenuWinClassS->StartWin();
signal(SIGWINCH, MenuWinClass::ResizeHandler);
//-------------_DatumUhrZeit_datumuhrzeit_-----------------------------------------------
//std::thread worker(&TaskClass::process_signal, std::ref(TaskPtr), "DateTime");
//worker.detach();
MenuWinClass::SetWinSize();
MenuWinClassS->FensterDraw();
refresh();
wrefresh(TaskClassS->ClearWindow(MenuWinClass::START.TMPWin1));
touchwin(TaskClassS->ClearWindow(MenuWinClass::START.TMPWin1));
redrawwin(TaskClassS->ClearWindow(MenuWinClass::START.TMPWin2));
wrefresh(TaskClassS->ClearWindow(MenuWinClass::START.TMPWin2));
touchwin(TaskClassS->ClearWindow(MenuWinClass::START.TMPWin2));
wrefresh(TaskClassS->ClearWindow(MenuWinClass::START.TMPWin3));
touchwin(TaskClassS->ClearWindow(MenuWinClass::START.TMPWin3));
prefresh(MenuWinClass::START.TMPWin4, 0, 0, 2, 1, MenuWinClass::START.HRYw4() + 1, MenuWinClass::START.WCXw4());
// prefresh(MenuWinClass::START.TMPWin5, 0, 0, MenuWinClass::START.HRY()-4,
// MenuWinClass::START.WCX()-46, MenuWinClass::START.HRYw5(), MenuWinClass::START.WCXw5());
redrawwin(TaskClassS->ClearWindow(MenuWinClass::START.TMPWin1));
wrefresh(TaskClassS->ClearWindow(MenuWinClass::START.TMPWin1));
do { Key = MenuWinClass::MenuStart(Key); if (Key == KEY_F(10)) { break; }; } while ((Key = getch()) != KEY_F(10));
ServiceClassS->ENDE();
MenuWinClassS->StopWin();
// } catch (const NCursesException *e) { endwin(); std::cerr << e->message << std::endl; cout << e->errorno;
// } catch (const NCursesException &e) { endwin(); std::cerr << e.message << std::endl; cout << e.errorno;
// } catch (const std::exception &e) { endwin(); std::cerr << "Exception: " << e.what() << std::endl; cout << EXIT_FAILURE; }
}