Richard Boegli's CnC_Generals_Zero_Hour Fork WIP
This is documentation of Richard Boegil's Zero Hour Fork
 
Loading...
Searching...
No Matches
PickUnitDialog Class Reference

#include <PickUnitDialog.h>

Inherits CDialog.

Inherited by ReplaceUnitDialog.

Public Types

enum  { IDD = IDD_PICKUNIT }
 

Public Member Functions

 PickUnitDialog (CWnd *pParent=NULL)
 
 PickUnitDialog (UINT id, CWnd *pParent=NULL)
 
 ~PickUnitDialog (void)
 standard destructor
 
AsciiString getPickedUnit (void)
 
Bool IsAllowableType (EditorSortingType sort, Bool isBuildable)
 
void SetAllowableType (EditorSortingType sort)
 
const ThingTemplategetPickedThing (void)
 
void SetFactionOnly (Bool faction)
 
void SetupAsPanel (void)
 

Protected Types

enum  { NAME_MAX_LEN = 64 }
 

Protected Member Functions

void addObject (MapObject *mapObject, const char *pPath, Int index, HTREEITEM parent)
 
HTREEITEM findOrAdd (HTREEITEM parent, const char *pLabel)
 
virtual void DoDataExchange (CDataExchange *pDX)
 
virtual BOOL OnNotify (WPARAM wParam, LPARAM lParam, LRESULT *pResult)
 
virtual BOOL OnInitDialog ()
 
afx_msg void OnMove (int x, int y)
 

Protected Attributes

Int m_currentObjectIndex
 
char m_currentObjectName [NAME_MAX_LEN]
 
CTreeCtrl m_objectTreeView
 
MapObjectm_objectsList
 
Bool m_allowable [ES_NUM_SORTING_TYPES]
 
Bool m_factionOnly
 

Detailed Description

Definition at line 38 of file PickUnitDialog.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
IDD 

Definition at line 59 of file PickUnitDialog.h.

◆ anonymous enum

anonymous enum
protected
Enumerator
NAME_MAX_LEN 

Definition at line 41 of file PickUnitDialog.h.

Constructor & Destructor Documentation

◆ PickUnitDialog() [1/2]

PickUnitDialog::PickUnitDialog ( CWnd * pParent = NULL)

Definition at line 67 of file PickUnitDialog.cpp.

◆ PickUnitDialog() [2/2]

PickUnitDialog::PickUnitDialog ( UINT id,
CWnd * pParent = NULL )

Definition at line 81 of file PickUnitDialog.cpp.

◆ ~PickUnitDialog()

PickUnitDialog::~PickUnitDialog ( void )

standard destructor

Definition at line 95 of file PickUnitDialog.cpp.

Member Function Documentation

◆ addObject()

void PickUnitDialog::addObject ( MapObject * mapObject,
const char * pPath,
Int index,
HTREEITEM parent )
protected

Add the object hierarchy paths to the tree view.

Definition at line 284 of file PickUnitDialog.cpp.

◆ DoDataExchange()

void PickUnitDialog::DoDataExchange ( CDataExchange * pDX)
protectedvirtual

Definition at line 103 of file PickUnitDialog.cpp.

◆ findOrAdd()

HTREEITEM PickUnitDialog::findOrAdd ( HTREEITEM parent,
const char * pLabel )
protected

Locate the child item in tree item parent with name pLabel. If not found, add it. Either way, return child.

Definition at line 211 of file PickUnitDialog.cpp.

◆ getPickedThing()

const ThingTemplate * PickUnitDialog::getPickedThing ( void )

Definition at line 394 of file PickUnitDialog.cpp.

◆ getPickedUnit()

AsciiString PickUnitDialog::getPickedUnit ( void )

Definition at line 385 of file PickUnitDialog.cpp.

◆ IsAllowableType()

Bool PickUnitDialog::IsAllowableType ( EditorSortingType sort,
Bool isBuildable )

Definition at line 131 of file PickUnitDialog.cpp.

◆ OnInitDialog()

BOOL PickUnitDialog::OnInitDialog ( )
protectedvirtual

Reimplemented in ReplaceUnitDialog.

Definition at line 156 of file PickUnitDialog.cpp.

◆ OnMove()

void PickUnitDialog::OnMove ( int x,
int y )
protected

Definition at line 118 of file PickUnitDialog.cpp.

◆ OnNotify()

BOOL PickUnitDialog::OnNotify ( WPARAM wParam,
LPARAM lParam,
LRESULT * pResult )
protectedvirtual

Definition at line 241 of file PickUnitDialog.cpp.

◆ SetAllowableType()

void PickUnitDialog::SetAllowableType ( EditorSortingType sort)

Definition at line 140 of file PickUnitDialog.cpp.

◆ SetFactionOnly()

void PickUnitDialog::SetFactionOnly ( Bool faction)
inline

Definition at line 87 of file PickUnitDialog.h.

◆ SetupAsPanel()

void PickUnitDialog::SetupAsPanel ( void )

Definition at line 145 of file PickUnitDialog.cpp.

Member Data Documentation

◆ m_allowable

Bool PickUnitDialog::m_allowable[ES_NUM_SORTING_TYPES]
protected

Definition at line 48 of file PickUnitDialog.h.

◆ m_currentObjectIndex

Int PickUnitDialog::m_currentObjectIndex
protected

Definition at line 44 of file PickUnitDialog.h.

◆ m_currentObjectName

char PickUnitDialog::m_currentObjectName[NAME_MAX_LEN]
protected

Definition at line 45 of file PickUnitDialog.h.

◆ m_factionOnly

Bool PickUnitDialog::m_factionOnly
protected

Definition at line 49 of file PickUnitDialog.h.

◆ m_objectsList

MapObject* PickUnitDialog::m_objectsList
protected

Definition at line 47 of file PickUnitDialog.h.

◆ m_objectTreeView

CTreeCtrl PickUnitDialog::m_objectTreeView
protected

Definition at line 46 of file PickUnitDialog.h.


The documentation for this class was generated from the following files: