本文整理汇总了C++中Modify函数的典型用法代码示例。如果您正苦于以下问题:C++ Modify函数的具体用法?C++ Modify怎么用?C++ Modify使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了Modify函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: Modify
UEdGraphPin* UEdGraphNode::CreatePin(EEdGraphPinDirection Dir, const FEdGraphPinType& InPinType, const FString& PinName, int32 Index /*= INDEX_NONE*/)
{
UEdGraphPin* NewPin = NewObject<UEdGraphPin>(this);
NewPin->PinName = PinName;
NewPin->Direction = Dir;
NewPin->PinType = InPinType;
NewPin->SetFlags(RF_Transactional);
if (HasAnyFlags(RF_Transient))
{
NewPin->SetFlags(RF_Transient);
}
Modify(false);
if (Pins.IsValidIndex(Index))
{
Pins.Insert(NewPin, Index);
}
else
{
Pins.Add(NewPin);
}
return NewPin;
}
示例2: Modify
void UMovieSceneShotSection::SetShotNameAndNumber(const FText& InDisplayName, int32 InShotNumber)
{
Modify();
DisplayName = InDisplayName;
ShotNumber = InShotNumber;
}
示例3: Modify
void UEdGraphPin::MakeLinkTo(UEdGraphPin* ToPin)
{
Modify();
if (ToPin != NULL)
{
ToPin->Modify();
// Make sure we don't already link to it
if (!LinkedTo.Contains(ToPin))
{
UEdGraphNode* MyNode = GetOwningNode();
// Check that the other pin does not link to us
ensureMsg(!ToPin->LinkedTo.Contains(this), *GetLinkInfoString( LOCTEXT("MakeLinkTo", "MakeLinkTo").ToString(), LOCTEXT("IsLinked", "is linked with pin").ToString(), ToPin));
ensureMsg(MyNode->GetOuter() == ToPin->GetOwningNode()->GetOuter(), *GetLinkInfoString( LOCTEXT("MakeLinkTo", "MakeLinkTo").ToString(), LOCTEXT("OuterMismatch", "has a different outer than pin").ToString(), ToPin)); // Ensure both pins belong to the same graph
// Add to both lists
LinkedTo.Add(ToPin);
ToPin->LinkedTo.Add(this);
GraphPinHelpers::EnableAllConnectedNodes(MyNode);
GraphPinHelpers::EnableAllConnectedNodes(ToPin->GetOwningNode());
}
}
}
示例4: Modify
bool UMovieScene::RemoveSpawnable( const FGuid& Guid )
{
bool bAnythingRemoved = false;
if( ensure( Guid.IsValid() ) )
{
for( auto SpawnableIter( Spawnables.CreateIterator() ); SpawnableIter; ++SpawnableIter )
{
auto& CurSpawnable = *SpawnableIter;
if( CurSpawnable.GetGuid() == Guid )
{
Modify();
{
UClass* GeneratedClass = CurSpawnable.GetClass();
UBlueprint* Blueprint = GeneratedClass ? Cast<UBlueprint>(GeneratedClass->ClassGeneratedBy) : nullptr;
check(nullptr != Blueprint);
// @todo sequencer: Also remove created Blueprint inner object. Is this sufficient? Needs to work with Undo too!
Blueprint->ClearFlags( RF_Standalone ); // @todo sequencer: Probably not needed for Blueprint
Blueprint->MarkPendingKill();
}
RemoveBinding( Guid );
// Found it!
Spawnables.RemoveAt( SpawnableIter.GetIndex() );
bAnythingRemoved = true;
break;
}
}
}
return bAnythingRemoved;
}
示例5: Modify
void Beam::AddLayerElement(LayerElement *element)
{
element->SetParent( this );
m_children.push_back(element);
Modify();
}
示例6: GetPinInformation
void UAnimGraphNode_BlendListByEnum::RemovePinFromBlendList(UEdGraphPin* Pin)
{
int32 RawArrayIndex = 0;
bool bIsPosePin = false;
bool bIsTimePin = false;
GetPinInformation(Pin->PinName, /*out*/ RawArrayIndex, /*out*/ bIsPosePin, /*out*/ bIsTimePin);
const int32 ExposedEnumIndex = (bIsPosePin || bIsTimePin) ? (RawArrayIndex - 1) : INDEX_NONE;
if (ExposedEnumIndex != INDEX_NONE)
{
FScopedTransaction Transaction( LOCTEXT("RemovePin", "RemovePin") );
Modify();
// Record it as no longer exposed
VisibleEnumEntries.RemoveAt(ExposedEnumIndex);
// Remove the pose from the node
UProperty* AssociatedProperty;
int32 ArrayIndex;
GetPinAssociatedProperty(GetFNodeType(), Pin, /*out*/ AssociatedProperty, /*out*/ ArrayIndex);
ensure(ArrayIndex == (ExposedEnumIndex + 1));
// setting up removed pins info
RemovedPinArrayIndex = ArrayIndex;
Node.RemovePose(ArrayIndex);
ReconstructNode();
//@TODO: Just want to invalidate the visual representation currently
FBlueprintEditorUtils::MarkBlueprintAsStructurallyModified(GetBlueprint());
}
}
示例7: main
void main()
{
ABList L;
printf("nnttWelcom to the information management system!nttt Copyright. Huang Wenbo,2010.n");
InitList_AB(L);
load(L);
system("color 18");
int flag=1;
while(flag)
{
switch(menu())
{
case 1:CreatABList(L);break;
case 2:Increase(L);break;
case 3:del(L);break;
case 4:Modify(L);break;
case 5:search(L);break;
case 6:save(L);break;
case 7:destroy(L);break;
case 8:system("cls");break;
case 9:flag = 0;printf("ttt欢迎下次使用! nttCopyright.Huang Wenbo,2010.n");
}
}
}
示例8: assert
void Measure::AddChild(Object *child)
{
if (child->IsControlElement()) {
assert(dynamic_cast<ControlElement *>(child));
}
else if (child->IsEditorialElement()) {
assert(dynamic_cast<EditorialElement *>(child));
}
else if (child->Is(STAFF)) {
Staff *staff = dynamic_cast<Staff *>(child);
assert(staff);
if (staff && (staff->GetN() < 1)) {
// This is not 100% safe if we have a <app> and <rdg> with more than
// one staff as a previous child.
staff->SetN(this->GetChildCount());
}
}
else {
LogError("Adding '%s' to a '%s'", child->GetClassName().c_str(), this->GetClassName().c_str());
assert(false);
}
child->SetParent(this);
m_children.push_back(child);
Modify();
}
示例9: Modify
void AGroupActor::Add(AActor& InActor)
{
// See if the incoming actor already belongs to a group
AGroupActor* InActorParent = AGroupActor::GetParentForActor(&InActor);
if(InActorParent) // If so, detach it first
{
if(InActorParent == this)
{
return;
}
InActorParent->Modify();
InActorParent->Remove(InActor);
}
Modify();
AGroupActor* InGroupPtr = Cast<AGroupActor>(&InActor);
if(InGroupPtr)
{
check(InGroupPtr != this);
SubGroups.AddUnique(InGroupPtr);
}
else
{
GroupActors.AddUnique(&InActor);
InActor.Modify();
InActor.GroupActor = this;
}
}
示例10: UpdateVersion_NestedNodes
void UEnvironmentQueryGraph::UpdateVersion()
{
if (GraphVersion == EQSGraphVersion::Latest)
{
return;
}
// convert to nested nodes
if (GraphVersion < EQSGraphVersion::NestedNodes)
{
UpdateVersion_NestedNodes();
}
if (GraphVersion < EQSGraphVersion::CopyPasteOutersBug)
{
UpdateVersion_FixupOuters();
}
if (GraphVersion < EQSGraphVersion::BlueprintClasses)
{
UpdateVersion_CollectClassData();
}
GraphVersion = EQSGraphVersion::Latest;
Modify();
}
示例11: assert
void ScoreDef::AddStaffGrp( StaffGrp *staffGrp )
{
assert( m_children.empty() );
staffGrp->SetParent( this );
m_children.push_back( staffGrp );
Modify();
}
示例12: strdup
/*!
* \brief Set value of a string item.
*/
bool CNutConfDoc::SetValue(CConfigItem & item, const wxString & strValue)
{
if (item.m_option) {
char *newval = strdup(strValue.mb_str());
/* Check if edited value changed. */
if (item.m_option->nco_value == NULL || strcmp(item.m_option->nco_value, newval)) {
/* Remove any previously edited value. */
if (item.m_option->nco_value) {
free(item.m_option->nco_value);
item.m_option->nco_value = NULL;
}
/* Check if new value differs from configured value. */
char *cfgval = GetConfigValue(m_repository, item.m_option->nco_name);
if ((cfgval == NULL && *newval) || (cfgval && strcmp(cfgval, newval))) {
item.m_option->nco_value = newval;
item.m_option->nco_active = 1;
Modify(true);
} else {
free(newval);
}
if (cfgval) {
free(cfgval);
}
CNutConfHint hint(&item, nutValueChanged);
UpdateAllViews(NULL, &hint);
} else {
free(newval);
}
}
return true;
}
示例13: Modify
void UStaticMeshComponent::InvalidateLightingCacheDetailed(bool bInvalidateBuildEnqueuedLighting, bool bTranslationOnly)
{
if(bHasCachedStaticLighting)
{
// Save the static mesh state for transactions, force it to be marked dirty if we are going to discard any static lighting data.
Modify(true);
// Detach the component from the scene for the duration of this function.
FComponentReregisterContext ReregisterContext(this);
// Block until the RT processes the unregister before modifying variables that it may need to access
FlushRenderingCommands();
Super::InvalidateLightingCacheDetailed(bInvalidateBuildEnqueuedLighting, bTranslationOnly);
// Discard all cached lighting.
check(AttachmentCounter.GetValue() == 0);
IrrelevantLights.Empty();
for(int32 i = 0; i < LODData.Num(); i++)
{
FStaticMeshComponentLODInfo& LODDataElement = LODData[i];
LODDataElement.LightMap = NULL;
LODDataElement.ShadowMap = NULL;
}
}
if (bInvalidateBuildEnqueuedLighting)
{
bStaticLightingBuildEnqueued = false;
}
}
示例14: FRawStructWriter
void UDataTable::CleanBeforeStructChange()
{
RowsSerializedWithTags.Reset();
TemporarilyReferencedObjects.Empty();
{
class FRawStructWriter : public FObjectWriter
{
TSet<UObject*>& TemporarilyReferencedObjects;
public:
FRawStructWriter(TArray<uint8>& InBytes, TSet<UObject*>& InTemporarilyReferencedObjects)
: FObjectWriter(InBytes), TemporarilyReferencedObjects(InTemporarilyReferencedObjects) {}
virtual FArchive& operator<<(class UObject*& Res) override
{
FObjectWriter::operator<<(Res);
TemporarilyReferencedObjects.Add(Res);
return *this;
}
};
FRawStructWriter MemoryWriter(RowsSerializedWithTags, TemporarilyReferencedObjects);
SaveStructData(MemoryWriter);
}
EmptyTable();
Modify();
}
示例15: Modify
void USimpleConstructionScript::RemoveNode(USCS_Node* Node)
{
// If it's a root node we are removing, clear it from the list
if(RootNodes.Contains(Node))
{
Modify();
RootNodes.Remove(Node);
Node->Modify();
Node->bIsParentComponentNative = false;
Node->ParentComponentOrVariableName = NAME_None;
Node->ParentComponentOwnerClassName = NAME_None;
ValidateSceneRootNodes();
}
// Not the root, so iterate over all nodes looking for the one with us in its ChildNodes array
else
{
USCS_Node* ParentNode = FindParentNode(Node);
if(ParentNode != NULL)
{
ParentNode->Modify();
ParentNode->ChildNodes.Remove(Node);
}
}
}