You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
36 lines
1021 B
C++
36 lines
1021 B
C++
|
|
// Copyright 1998-2014 Epic Games, Inc. All Rights Reserved.
|
||
|
|
|
||
|
|
#include "SequencerPrivatePCH.h"
|
||
|
|
#include "SectionLayoutBuilder.h"
|
||
|
|
|
||
|
|
|
||
|
|
FSectionLayoutBuilder::FSectionLayoutBuilder( TSharedRef<FTrackNode> InRootNode )
|
||
|
|
: RootNode( InRootNode )
|
||
|
|
, CurrentNode( InRootNode )
|
||
|
|
{}
|
||
|
|
|
||
|
|
void FSectionLayoutBuilder::PushCategory( FName CategoryName, const FString& DisplayLabel )
|
||
|
|
{
|
||
|
|
CurrentNode = CurrentNode->AddCategoryNode( CategoryName, DisplayLabel );
|
||
|
|
}
|
||
|
|
|
||
|
|
void FSectionLayoutBuilder::PopCategory()
|
||
|
|
{
|
||
|
|
// Pop a category if the current node is a category
|
||
|
|
if( CurrentNode->GetParent().IsValid() && CurrentNode->GetType() == ESequencerNode::Category )
|
||
|
|
{
|
||
|
|
CurrentNode = CurrentNode->GetParent().ToSharedRef();
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
void FSectionLayoutBuilder::SetSectionAsKeyArea( TSharedRef<IKeyArea> KeyArea )
|
||
|
|
{
|
||
|
|
RootNode->SetSectionAsKeyArea( KeyArea );
|
||
|
|
}
|
||
|
|
|
||
|
|
void FSectionLayoutBuilder::AddKeyArea( FName KeyAreaName, const FString& DisplayName, TSharedRef<IKeyArea> KeyArea )
|
||
|
|
{
|
||
|
|
CurrentNode->AddKeyAreaNode( KeyAreaName, DisplayName, KeyArea );
|
||
|
|
}
|
||
|
|
|