Snoke
application.h
Go to the documentation of this file.
1 #ifndef APPLICATION_H
2 #define APPLICATION_H
3 #include <list>
4 #include <map>
5 #include <ncurses.h>
6 #include "screen.h"
7 #include "../Widgets/widget.h"
8 
17 {
18  private:
19  void focusFirst();
20  Application();
21  Application(const Application&);
23  std::map<char*, Screen*> screens;
24  std::list<Screen*> history;
27 
28  public:
29  static Application& instance();
30  void load(char* name);
31  void back();
32  void add(char* name, Screen* screen);
33  void execute();
34 };
35 
40 extern Application& app;
41 
42 #endif
Widget * currentWidget
Definition: application.h:26
static Application & instance()
Definition: application.cpp:90
Definition: screen.h:10
std::list< Screen * > history
Definition: application.h:24
void load(char *name)
Definition: application.cpp:55
Application & operator=(Application &)
Application & app
void add(char *name, Screen *screen)
Definition: application.cpp:80
Screen * currentScreen
Definition: application.h:25
std::map< char *, Screen * > screens
Definition: application.h:23
Definition: widget.h:36
void execute()
Definition: application.cpp:15
void focusFirst()
Definition: application.cpp:6