summaryrefslogtreecommitdiffhomepage
path: root/Stars45/MsnEventDlg.h
blob: f1965ede1d7201829f19683529c433c401e64b8d (plain)
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
/*  Project Starshatter 4.5
	Destroyer Studios LLC
	Copyright © 1997-2004. All Rights Reserved.

	SUBSYSTEM:    Stars.exe
	FILE:         MsnEventDlg.h
	AUTHOR:       John DiCamillo


	OVERVIEW
	========
	Mission Editor Element Dialog Active Window class
*/

#ifndef MsnEventDlg_h
#define MsnEventDlg_h

#include "Types.h"
#include "FormWindow.h"
#include "Bitmap.h"
#include "Button.h"
#include "ComboBox.h"
#include "ListBox.h"
#include "Font.h"
#include "Text.h"

// +--------------------------------------------------------------------+

class MenuScreen;
class MsnEditDlg;
class Mission;
class MissionElement;
class MissionEvent;

// +--------------------------------------------------------------------+

class MsnEventDlg : public FormWindow
{
public:
	MsnEventDlg(Screen* s, FormDef& def, MenuScreen* mgr);
	virtual ~MsnEventDlg();

	virtual void      RegisterControls();
	virtual void      Show();
	virtual void      ExecFrame();

	// Operations:
	virtual void      SetMission(Mission* msn);
	virtual void      SetMissionEvent(MissionEvent* event);
	virtual void      OnEventSelect(AWEvent* e);
	virtual void      OnAccept(AWEvent* e);
	virtual void      OnCancel(AWEvent* e);

protected:
	virtual void      FillShipList(ComboBox* cmb, const char* seln);
	virtual void      FillRgnList(ComboBox* cmb, const char* seln);

	MenuScreen*       manager;

	ActiveWindow*     lbl_id;
	EditBox*          edt_time;
	EditBox*          edt_delay;

	ComboBox*         cmb_event;
	ComboBox*         cmb_event_ship;
	ComboBox*         cmb_event_source;
	ComboBox*         cmb_event_target;
	EditBox*          edt_event_param;
	EditBox*          edt_event_chance;
	EditBox*          edt_event_sound;
	EditBox*          edt_event_message;

	ComboBox*         cmb_trigger;
	ComboBox*         cmb_trigger_ship;
	ComboBox*         cmb_trigger_target;
	EditBox*          edt_trigger_param;

	Button*           btn_accept;
	Button*           btn_cancel;

	Mission*          mission;
	MissionEvent*     event;
};

#endif MsnEventDlg_h