Changed: #1246 Build on PPC machines (patch provided by Jeru)
This commit is contained in:
parent
fa63539729
commit
fc1deec2e8
1 changed files with 89 additions and 88 deletions
|
@ -50,46 +50,6 @@ extern ULandscape *Landscape;
|
|||
namespace R2
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
// *********************************************************************************************************
|
||||
CDisplayerVisualGroup::CDisplayerVisualGroup()
|
||||
{
|
||||
_ArrayName = "Components";
|
||||
_DrawnThisFrame = false;
|
||||
_TimeOver = 0;
|
||||
_CurrPrimValid = true;
|
||||
touch();
|
||||
_Active = false;
|
||||
_CurrPrimInaccessible = false;
|
||||
_ContextualVisibilityActive = false;
|
||||
_ContextualVisibilityDate = -1;
|
||||
_VisibleLastFrame = false;
|
||||
}
|
||||
|
||||
// *********************************************************************************************************
|
||||
void CDisplayerVisualGroup::touch()
|
||||
{
|
||||
//H_AUTO(R2_CDisplayerVisualGroup_touch)
|
||||
_PrimTouched = true;
|
||||
_InstanceListTouched = true;
|
||||
_AccessibilityTouched = true;
|
||||
}
|
||||
|
||||
// *********************************************************************************************************
|
||||
void CDisplayerVisualGroup::setDisplayedInstance(CInstance *instance)
|
||||
{
|
||||
//H_AUTO(R2_CDisplayerVisualGroup_setDisplayedInstance)
|
||||
CDisplayerVisual::setDisplayedInstance(instance);
|
||||
_Prim.DisplayedInstance = instance;
|
||||
}
|
||||
|
||||
// *********************************************************************************************************
|
||||
CCtrlPolygon *CDisplayerVisualGroup::CSelectablePrimRender::newCtrlPolygon() const
|
||||
{
|
||||
//H_AUTO(R2_CDisplayerVisualGroup_CSelectablePrimRender)
|
||||
nlassert(DisplayedInstance);
|
||||
// create a special selectable polygon
|
||||
class CCtrlPolygonSelectable : public CCtrlPolygon, public IDisplayerUIHandle
|
||||
{
|
||||
|
@ -134,19 +94,7 @@ CCtrlPolygon *CDisplayerVisualGroup::CSelectablePrimRender::newCtrlPolygon() con
|
|||
gm->worldToWindow(dest, src);
|
||||
}
|
||||
};
|
||||
CCtrlPolygonSelectable *result = new CCtrlPolygonSelectable(*DisplayedInstance);
|
||||
result->setId(DisplayedInstance->getId());
|
||||
result->setToolTipParent(CCtrlBase::TTMouse);
|
||||
result->setToolTipParentPosRef(Hotspot_BR);
|
||||
result->setToolTipPosRef(Hotspot_TL);
|
||||
return result;
|
||||
}
|
||||
|
||||
// *********************************************************************************************************
|
||||
CCtrlQuad *CDisplayerVisualGroup::CSelectablePrimRender::newCtrlQuad(uint edgeIndex) const
|
||||
{
|
||||
//H_AUTO(R2_CDisplayerVisualGroup_CSelectablePrimRender)
|
||||
nlassert(DisplayedInstance);
|
||||
// create a special selectable polygon
|
||||
class CCtrlQuadSelectable : public CCtrlQuad, public IDisplayerUIHandle
|
||||
{
|
||||
|
@ -191,6 +139,59 @@ CCtrlQuad *CDisplayerVisualGroup::CSelectablePrimRender::newCtrlQuad(uint edgeIn
|
|||
CInstance &Instance;
|
||||
uint EdgeIndex;
|
||||
};
|
||||
|
||||
|
||||
|
||||
// *********************************************************************************************************
|
||||
CDisplayerVisualGroup::CDisplayerVisualGroup()
|
||||
{
|
||||
_ArrayName = "Components";
|
||||
_DrawnThisFrame = false;
|
||||
_TimeOver = 0;
|
||||
_CurrPrimValid = true;
|
||||
touch();
|
||||
_Active = false;
|
||||
_CurrPrimInaccessible = false;
|
||||
_ContextualVisibilityActive = false;
|
||||
_ContextualVisibilityDate = -1;
|
||||
_VisibleLastFrame = false;
|
||||
}
|
||||
|
||||
// *********************************************************************************************************
|
||||
void CDisplayerVisualGroup::touch()
|
||||
{
|
||||
//H_AUTO(R2_CDisplayerVisualGroup_touch)
|
||||
_PrimTouched = true;
|
||||
_InstanceListTouched = true;
|
||||
_AccessibilityTouched = true;
|
||||
}
|
||||
|
||||
// *********************************************************************************************************
|
||||
void CDisplayerVisualGroup::setDisplayedInstance(CInstance *instance)
|
||||
{
|
||||
//H_AUTO(R2_CDisplayerVisualGroup_setDisplayedInstance)
|
||||
CDisplayerVisual::setDisplayedInstance(instance);
|
||||
_Prim.DisplayedInstance = instance;
|
||||
}
|
||||
|
||||
// *********************************************************************************************************
|
||||
CCtrlPolygon *CDisplayerVisualGroup::CSelectablePrimRender::newCtrlPolygon() const
|
||||
{
|
||||
//H_AUTO(R2_CDisplayerVisualGroup_CSelectablePrimRender)
|
||||
nlassert(DisplayedInstance);
|
||||
CCtrlPolygonSelectable *result = new CCtrlPolygonSelectable(*DisplayedInstance);
|
||||
result->setId(DisplayedInstance->getId());
|
||||
result->setToolTipParent(CCtrlBase::TTMouse);
|
||||
result->setToolTipParentPosRef(Hotspot_BR);
|
||||
result->setToolTipPosRef(Hotspot_TL);
|
||||
return result;
|
||||
}
|
||||
|
||||
// *********************************************************************************************************
|
||||
CCtrlQuad *CDisplayerVisualGroup::CSelectablePrimRender::newCtrlQuad(uint edgeIndex) const
|
||||
{
|
||||
//H_AUTO(R2_CDisplayerVisualGroup_CSelectablePrimRender)
|
||||
nlassert(DisplayedInstance);
|
||||
CCtrlQuadSelectable *result = new CCtrlQuadSelectable(*DisplayedInstance, edgeIndex);
|
||||
result->setToolTipParent(CCtrlBase::TTMouse);
|
||||
result->setToolTipParentPosRef(Hotspot_BR);
|
||||
|
|
Loading…
Reference in a new issue