本文整理汇总了C++中PropertyPtr::getOwner方法的典型用法代码示例。如果您正苦于以下问题:C++ PropertyPtr::getOwner方法的具体用法?C++ PropertyPtr::getOwner怎么用?C++ PropertyPtr::getOwner使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PropertyPtr
的用法示例。
在下文中一共展示了PropertyPtr::getOwner方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: notifyChangeProperty
void FontTextureController::notifyChangeProperty(PropertyPtr _sender)
{
if (!mActivated || !PropertyUtility::isDataSelected(_sender->getOwner()))
return;
if (_sender->getOwner()->getType()->getName() == "Font")
{
if (_sender->getType()->getName() == "FontName")
updateTexture(_sender->getValue());
}
}
示例2: notifyChangeProperty
void GroupTextureController::notifyChangeProperty(PropertyPtr _sender)
{
if (!mActivated || !PropertyUtility::isDataSelected(_sender->getOwner()))
return;
if (_sender->getOwner()->getType()->getName() == "Group")
{
if (_sender->getType()->getName() == "Texture")
mControl->setTextureValue(_sender->getValue());
else if (_sender->getType()->getName() == "Size")
updateCoords(_sender->getValue());
}
}
示例3: initialise
void UniqueNamePropertyInitialisator::initialise(PropertyPtr _property)
{
DataPtr parent = DataUtility::getSelectedParentDataByType(_property->getOwner()->getType()->getName());
if (parent == nullptr)
return;
std::string name = DataUtility::getUniqueName(parent, "unnamed_");
_property->setValue(name);
}
示例4: notifyChangeProperty
void ListBoxDataControl::notifyChangeProperty(PropertyPtr _sender)
{
if (mParentData == nullptr)
return;
if (mParentData != _sender->getOwner()->getParent())
return;
for (size_t index = 0; index < mListBox->getItemCount(); index ++)
{
DataPtr data = *mListBox->getItemDataAt<DataPtr>(index);
if (data == _sender->getOwner())
{
bool unique = isDataEnabled(data);
if (unique)
mListBox->setItemNameAt(index, data->getPropertyValue(mPropertyForName));
else
mListBox->setItemNameAt(index, replaceTags(mColourName) + data->getPropertyValue(mPropertyForName));
}
}
}