Starshatter_Open
Open source Starshatter engine
Main Page
Classes
Files
File List
File Members
All
Classes
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
MsnNavDlg.cpp
Go to the documentation of this file.
1
/* Project Starshatter 4.5
2
Destroyer Studios LLC
3
Copyright © 1997-2004. All Rights Reserved.
4
5
SUBSYSTEM: Stars.exe
6
FILE: MsnNavDlg.cpp
7
AUTHOR: John DiCamillo
8
9
10
OVERVIEW
11
========
12
Mission Briefing Dialog Active Window class
13
*/
14
15
#include "
MemDebug.h
"
16
#include "
MsnNavDlg.h
"
17
#include "
PlanScreen.h
"
18
#include "
Campaign.h
"
19
#include "
Mission.h
"
20
#include "
Instruction.h
"
21
#include "
Ship.h
"
22
#include "
ShipDesign.h
"
23
#include "
StarSystem.h
"
24
25
#include "
Keyboard.h
"
26
27
// +--------------------------------------------------------------------+
28
// DECLARE MAPPING FUNCTIONS:
29
DEF_MAP_CLIENT
(
MsnNavDlg
, OnCommit);
30
DEF_MAP_CLIENT
(
MsnNavDlg
, OnCancel);
31
DEF_MAP_CLIENT
(
MsnNavDlg
, OnTabButton);
32
33
// +--------------------------------------------------------------------+
34
35
MsnNavDlg::MsnNavDlg
(
Screen
* s,
FormDef
& def,
PlanScreen
* mgr)
36
:
NavDlg
(s, def, mgr),
MsnDlg
(mgr)
37
{
38
RegisterControls
();
39
}
40
41
MsnNavDlg::~MsnNavDlg
()
42
{
43
}
44
45
// +--------------------------------------------------------------------+
46
47
void
48
MsnNavDlg::RegisterControls
()
49
{
50
RegisterMsnControls
(
this
);
51
52
if
(
commit
)
53
REGISTER_CLIENT
(
EID_CLICK
,
commit
,
MsnNavDlg
,
OnCommit
);
54
55
if
(
cancel
)
56
REGISTER_CLIENT
(
EID_CLICK
,
cancel
,
MsnNavDlg
,
OnCancel
);
57
58
if
(
sit_button
)
59
REGISTER_CLIENT
(
EID_CLICK
,
sit_button
,
MsnNavDlg
,
OnTabButton
);
60
61
if
(
pkg_button
)
62
REGISTER_CLIENT
(
EID_CLICK
,
pkg_button
,
MsnNavDlg
,
OnTabButton
);
63
64
if
(
nav_button
)
65
REGISTER_CLIENT
(
EID_CLICK
,
nav_button
,
MsnNavDlg
,
OnTabButton
);
66
67
if
(
wep_button
)
68
REGISTER_CLIENT
(
EID_CLICK
,
wep_button
,
MsnNavDlg
,
OnTabButton
);
69
}
70
71
// +--------------------------------------------------------------------+
72
73
void
74
MsnNavDlg::Show
()
75
{
76
NavDlg::Show
();
77
ShowMsnDlg
();
78
}
79
80
void
81
MsnNavDlg::ExecFrame
()
82
{
83
NavDlg::ExecFrame
();
84
85
if
(
Keyboard::KeyDown
(VK_RETURN)) {
86
OnCommit
(0);
87
}
88
}
89
90
// +--------------------------------------------------------------------+
91
92
void
93
MsnNavDlg::OnCommit
(
AWEvent
* event)
94
{
95
MsnDlg::OnCommit
(event);
96
NavDlg::OnCommit
(event);
97
}
98
99
void
100
MsnNavDlg::OnCancel
(
AWEvent
* event)
101
{
102
MsnDlg::OnCancel
(event);
103
NavDlg::OnCancel
(event);
104
}
Stars45
MsnNavDlg.cpp
Generated on Tue Jun 5 2012 20:46:59 for Starshatter_Open by
1.8.1