4 #include "IRefObject.h" 27 SelectedItem() :m_bSelected(
false), m_nItemType(TYPE_UNKNOWN){};
32 return m_pObjectRef.get();
36 return Is3DObject() ? (
CBaseObject*)m_pObjectRef.get() : NULL;
40 return (Is2DObject()) ? (
CGUIBase*)m_pObjectRef.get() : NULL;
49 inline bool Is3DObject(){
return m_nItemType == TYPE_CBASEOBJECT && m_pObjectRef; };
50 inline bool Is2DObject(){
return m_nItemType == TYPE_CGUIBASE && m_pObjectRef; };
60 CSelectionGroup() : m_bSelected(
false), m_nMaxItemNumber(1), m_bRemoveFromBack(
false), m_bExclusiveSelect(
true) {};
66 virtual int GetChildAttributeObjectCount(
int nColumnIndex = 0);
67 virtual IAttributeFields* GetChildAttributeObject(
int nRowIndex,
int nColumnIndex = 0);
110 virtual int GetChildAttributeObjectCount(
int nColumnIndex = 0);
111 virtual IAttributeFields* GetChildAttributeObject(
int nRowIndex,
int nColumnIndex = 0);
132 void RemoveObject(
CGUIBase* pObject);
144 void AddObject(
CBaseObject* pObject,
int nGroupID = 0);
145 void AddObject(
CGUIBase* pObject,
int nGroupID = 0);
154 bool GetObject(
int nGroupID,
int nItemIndex,
SelectedItem* pOut);
162 int GetItemNumInGroup(
int nGroupID);
169 void SelectGroup(
int nGroupID,
bool bSelect);
174 void ClearGroup(
int nGroupID);
182 void SetMaxItemNumberInGroup(
int nGroupID,
int nMaxItemsNumber);
189 int GetMaxItemNumberInGroup(
int nGroupID);
214 void UpdateGroup(
int nGroupID);
217 vector< ref_ptr<CSelectionGroup> > m_groups;
int GetGroupCount()
get the group count.
Definition: SelectionManager.h:206
Definition: combase.h:159
vector< SelectedItem > m_items
all items in the selection group.
Definition: SelectionManager.h:80
different physics engine has different winding order.
Definition: EventBinding.h:32
SelectedItem & GetItem(int nIndex)
get item at give index.
Definition: SelectionManager.h:74
int m_nMaxItemNumber
maximum number of objects in the group.
Definition: SelectionManager.h:86
base object for all 2D GUI objects (1) 2D GUI object are not tested against view frustum, instead it is controlled by visibility tag automatically or through user input.
Definition: GUIBase.h:54
bool IsExclusive()
default to true.
Definition: SelectionManager.h:77
A common interface for all classes implementing IAttributeFields By implementing this class's virtual...
Definition: IAttributeFields.h:59
bool m_bExclusiveSelect
default to true.
Definition: SelectionManager.h:93
int GetItemCount()
get item count.
Definition: SelectionManager.h:71
bool m_bRemoveFromBack
if true, objects exceeding the max item number will be removed from the back of the item list...
Definition: SelectionManager.h:90
Defines the base class of all scene elements:CBaseObject for Parallel World Engine.
Definition: BaseObject.h:230
bool m_bSelected
whether the entire group is selected.default value is false
Definition: SelectionManager.h:83
A pool of currently selected objects.
Definition: SelectionManager.h:102
a group of selected object
Definition: SelectionManager.h:57
anything that makes references to other objects.
Definition: IRefObject.h:65
currently selected item.
Definition: SelectionManager.h:15