本文整理汇总了C++中ProjectItem::GetPathString方法的典型用法代码示例。如果您正苦于以下问题:C++ ProjectItem::GetPathString方法的具体用法?C++ ProjectItem::GetPathString怎么用?C++ ProjectItem::GetPathString使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ProjectItem
的用法示例。
在下文中一共展示了ProjectItem::GetPathString方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: WriteNode
//----------------------------------------------------------------
wxXmlNode* ProjectItemFile::WriteNode()
/**
* \brief Writes a 'projectitem' xml element node.
* See class description for more information.
* \return The 'projectitem' xml element node.
**/
{
wxXmlNode* node = PenvHelper::CreateXmlNode(_T("projectitem"));
node->AddProperty(_T("name"), m_name);
node->AddProperty(_T("type"), _T("file"));
node->AddProperty(_T("virtual"), PenvHelper::CreateBoolean(m_virtual));
wxString parentpath;
if (m_parent->GetProjectParent() == NULL) {
ProjectItem* item = m_parent->GetProjectItemParent();
parentpath = item->GetPathString();
} else {
Project* project = m_parent->GetProjectParent();
parentpath = project->GetFileNameString();
}
wxXmlNode* filename = PenvHelper::CreateXmlNode(_T("filename"),
Path::MakeRelative(parentpath, m_filename.GetPath()));
PenvHelper::AddXmlChildNode(node, filename);
wxXmlNode* propnode = m_properties->WriteNode();
PenvHelper::AddXmlChildNode(node, propnode);
return (node);
}