Starshatter_Open
Open source Starshatter engine
Main Page
Classes
Files
File List
File Members
All
Classes
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
FormWindow.h
Go to the documentation of this file.
1
/* Project nGenEx
2
Destroyer Studios LLC
3
Copyright © 1997-2004. All Rights Reserved.
4
5
SUBSYSTEM: nGenEx.lib
6
FILE: FormWindow.h
7
AUTHOR: John DiCamillo
8
9
10
OVERVIEW
11
========
12
Form Window class (a window that manages controls)
13
*/
14
15
#ifndef FormWindow_h
16
#define FormWindow_h
17
18
#include "
Types.h
"
19
#include "
ActiveWindow.h
"
20
#include "
FormDef.h
"
21
#include "
List.h
"
22
23
// +--------------------------------------------------------------------+
24
25
class
Button
;
26
class
ComboBox
;
27
class
EditBox
;
28
class
ImageBox
;
29
class
ListBox
;
30
class
RichTextBox
;
31
class
Slider
;
32
33
// +--------------------------------------------------------------------+
34
35
class
FormWindow
:
public
ActiveWindow
36
{
37
public
:
38
FormWindow
(
Screen
* s,
int
ax,
int
ay,
int
aw,
int
ah,
39
DWORD aid=0, DWORD
style
=0,
ActiveWindow
*
parent
=0);
40
virtual
~FormWindow
();
41
42
// operations:
43
virtual
void
Init
();
44
virtual
void
Init
(
const
FormDef
& def);
45
virtual
void
Destroy
();
46
virtual
ActiveWindow
*
FindControl
(DWORD
id
);
47
virtual
ActiveWindow
*
FindControl
(
int
x,
int
y);
48
virtual
void
RegisterControls
() { }
49
50
virtual
void
AdoptFormDef
(
const
FormDef
& def);
51
virtual
void
AddControl
(
ActiveWindow
* ctrl);
52
53
virtual
ActiveWindow
*
CreateLabel
(
const
char
*
text
,
int
x,
int
y,
int
w,
int
h, DWORD
id
=0, DWORD pid=0, DWORD
style
=0);
54
virtual
Button
*
CreateButton
(
const
char
*
text
,
int
x,
int
y,
int
w,
int
h, DWORD
id
=0, DWORD pid=0);
55
virtual
ImageBox
*
CreateImageBox
(
const
char
*
text
,
int
x,
int
y,
int
w,
int
h, DWORD
id
=0, DWORD pid=0);
56
virtual
ListBox
*
CreateListBox
(
const
char
*
text
,
int
x,
int
y,
int
w,
int
h, DWORD
id
=0, DWORD pid=0);
57
virtual
ComboBox
*
CreateComboBox
(
const
char
*
text
,
int
x,
int
y,
int
w,
int
h, DWORD
id
=0, DWORD pid=0);
58
virtual
EditBox
*
CreateEditBox
(
const
char
*
text
,
int
x,
int
y,
int
w,
int
h, DWORD
id
=0, DWORD pid=0);
59
virtual
RichTextBox
*
CreateRichTextBox
(
const
char
*
text
,
int
x,
int
y,
int
w,
int
h, DWORD
id
=0, DWORD pid=0, DWORD
style
=0);
60
virtual
Slider
*
CreateSlider
(
const
char
*
text
,
int
x,
int
y,
int
w,
int
h, DWORD
id
=0, DWORD pid=0, DWORD
style
=0);
61
62
// property accessors:
63
ListIter<ActiveWindow>
Controls
() {
return
children
; }
64
65
protected
:
66
virtual
void
CreateDefLabel
(
CtrlDef
& def);
67
virtual
void
CreateDefButton
(
CtrlDef
& def);
68
virtual
void
CreateDefImage
(
CtrlDef
& def);
69
virtual
void
CreateDefList
(
CtrlDef
& def);
70
virtual
void
CreateDefCombo
(
CtrlDef
& def);
71
virtual
void
CreateDefEdit
(
CtrlDef
& def);
72
virtual
void
CreateDefSlider
(
CtrlDef
& def);
73
virtual
void
CreateDefRichText
(
CtrlDef
& def);
74
};
75
76
#endif FormWindow_h
77
nGenEx
FormWindow.h
Generated on Tue Jun 5 2012 20:46:22 for Starshatter_Open by
1.8.1