예제 #1
0
bool nuiWindow::Load(const nuiXMLNode* pNode)
{
  nuiSimpleContainer::Load(pNode);
  mpCloseButton = NULL;
  mMoving = eNoMove;

  // FIXME: interpret other attributes...

  nuiWindowFlags Flags = NoFlag;
  if (nuiGetBool (pNode, _T("StaticChildren"), false)) Flags |= StaticChildren;
  if (nuiGetBool (pNode, _T("NoResize"), false)) Flags |= NoResize;
  if (nuiGetBool (pNode, _T("NoMove"), false)) Flags |= NoMove;
  if (nuiGetBool (pNode, _T("NoCaption"), false)) Flags |= NoCaption;
  if (nuiGetBool (pNode, _T("NoClose"), false)) Flags |= NoClose;
  if (nuiGetBool (pNode, _T("Raw"), false)) Flags |= Raw;
  if (nuiGetBool (pNode, _T("Modal"), false)) Flags |= Modal;

  SetFlags(Flags);

  mTitle = nuiGetString(pNode, _T("Title"), _T(""));
  mMinimumHeight = nuiGetVal(pNode, _T("MinimumHeight"), 16.0f);
  mMinimumWidth = nuiGetVal(pNode, _T("MinimumWidth"), 40.0f);
  InitProperties();
  
  return true;
}
예제 #2
0
파일: nuiArc.cpp 프로젝트: jbl2024/nui3
nuiArc::nuiArc(nuiXMLNode* pNode)
{
  mStartVertex.Elt[0] = nuiGetVal(pNode, _T("X0"), 0.0f);
  mStartVertex.Elt[1] = nuiGetVal(pNode, _T("Y0"), 0.0f);
  mStartVertex.Elt[2] = nuiGetVal(pNode, _T("Z0"), 0.0f);
                                                  
  mStopVertex.Elt[0] = nuiGetVal(pNode, _T("X1"), 0.0f);
  mStopVertex.Elt[1] = nuiGetVal(pNode, _T("Y1"), 0.0f);
  mStopVertex.Elt[2] = nuiGetVal(pNode, _T("Z1"), 0.0f);

  mXRadius = nuiGetVal(pNode, _T("XRadius"), 0.0f);
  mYRadius = nuiGetVal(pNode, _T("YRadius"), 0.0f);
  mAngle = nuiGetVal(pNode, _T("Angle"), 0.0f);
  mLargeArc = nuiGetBool(pNode, _T("LargeArc"), false);
  mSweep = nuiGetBool(pNode, _T("Sweep"), false);
}