本文整理汇总了C++中NodeAbstractProperty::name方法的典型用法代码示例。如果您正苦于以下问题:C++ NodeAbstractProperty::name方法的具体用法?C++ NodeAbstractProperty::name怎么用?C++ NodeAbstractProperty::name使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类NodeAbstractProperty
的用法示例。
在下文中一共展示了NodeAbstractProperty::name方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: nodeRemoved
void StatesEditorView::nodeRemoved(const ModelNode & /*removedNode*/, const NodeAbstractProperty &parentProperty, PropertyChangeFlags /*propertyChange*/)
{
if (parentProperty.isValid() && parentProperty.parentModelNode().isRootNode() && parentProperty.name() == "states") {
m_statesEditorModel->removeState(m_lastIndex);
m_lastIndex = -1;
}
}
示例2: nodeAboutToBeRemoved
void StatesEditorView::nodeAboutToBeRemoved(const ModelNode &removedNode)
{
if (removedNode.hasParentProperty()) {
const NodeAbstractProperty propertyParent = removedNode.parentProperty();
if (propertyParent.parentModelNode().isRootNode() && propertyParent.name() == "states")
m_lastIndex = propertyParent.indexOf(removedNode);
}
if (currentState().isValid() && removedNode == currentState())
setCurrentState(baseState());
}
示例3: isInEditedPath
static bool isInEditedPath(const NodeAbstractProperty &propertyParent, const ModelNode &editingPathViewModelNode)
{
if (editingPathViewModelNode.isValid()) {
if (editingPathViewModelNode.hasNodeProperty("path")) {
ModelNode pathModelNode = editingPathViewModelNode.nodeProperty("path").modelNode();
if (pathModelNode.metaInfo().isSubclassOf("QtQuick.Path")) {
if (propertyParent.name() == "pathElements" && propertyParent.parentModelNode() == pathModelNode)
return true;
}
}
}
return false;
}
示例4: AbstractProperty
NodeAbstractProperty::NodeAbstractProperty(const NodeAbstractProperty &property, AbstractView *view)
: AbstractProperty(property.name(), property.internalNode(), property.model(), view)
{
}
示例5:
QDebug operator<<(QDebug debug, const NodeAbstractProperty &property)
{
return debug.nospace() << "NodeAbstractProperty(" << (property.isValid() ? property.name() : QLatin1String("invalid")) << ')';
}
示例6: nodeReparented
void StatesEditorView::nodeReparented(const ModelNode &node, const NodeAbstractProperty &newPropertyParent, const NodeAbstractProperty &oldPropertyParent, AbstractView::PropertyChangeFlags /*propertyChange*/)
{
if (oldPropertyParent.isValid() && oldPropertyParent.parentModelNode().isRootNode() && oldPropertyParent.name() == "states")
m_statesEditorModel->removeState(m_lastIndex);
m_lastIndex = -1;
if (newPropertyParent.isValid() && newPropertyParent.parentModelNode().isRootNode() && newPropertyParent.name() == "states") {
int index = newPropertyParent.indexOf(node);
m_statesEditorModel->insertState(index);
}
}
示例7: nodeAboutToBeReparented
void StatesEditorView::nodeAboutToBeReparented(const ModelNode &node, const NodeAbstractProperty &/*newPropertyParent*/, const NodeAbstractProperty &oldPropertyParent, AbstractView::PropertyChangeFlags /*propertyChange*/)
{
if (oldPropertyParent.isValid() && oldPropertyParent.parentModelNode().isRootNode() && oldPropertyParent.name() == "states")
m_lastIndex = oldPropertyParent.indexOf(node);
}