Debian Codegraph @

Examples/GUIStyle/MenuSystem/NS_Menu_Play.h

raw
1 // NS_Menu_Play.h: interface for the NS_Menu_Play class.
2 //
3 //////////////////////////////////////////////////////////////////////
4
5 #if !defined(AFX_NS_MENU_PLAY_H__1931A600_09B6_40E1_BAA4_B153D0C0C7AB__INCLUDED_)
6 #define AFX_NS_MENU_PLAY_H__1931A600_09B6_40E1_BAA4_B153D0C0C7AB__INCLUDED_
7
8 #if _MSC_VER > 1000
9 #pragma once
10 #endif // _MSC_VER > 1000
11
12 #include "NS_MenuGeneric.h"
13
14 class NS_Game;
15 class NS_LevelSet;
16 class NS_Panel_In_Game;
17
18 #include <ClanLib/core.h> // for Timer
19
20 class NS_Menu_Play : public NS_MenuGeneric
21 {
22 public:
23 NS_Menu_Play(NS_MenuManager & menu_manager,
24 CL_StyleManager & style_manager,
25 std::string const & path_to_resource);
26 virtual ~NS_Menu_Play();
27 public:
28 // virtual overwrite for kill CL_KeepAlive(10)
29 void run_task();
30 public:
31 // TODO: Check about sig_pre_paing() for double clearing
32 void on_switch_to_main_menu();
33 void on_key_down(CL_InputEvent const & key);
34 // virtual functions
35 public:
36 void on_quit();
37 void switch_to(std::string const & menu_name);
38 void on_timer();
39 public:
40 enum State {
41 game_running,
42 game_failed,
43 game_successful
44 };
45 private:
46 size_t level_number;
47 CL_Timer timer;
48 State state;
49 };
50
51 #endif // !defined(AFX_NS_MENU_PLAY_H__1931A600_09B6_40E1_BAA4_B153D0C0C7AB__INCLUDED_)