Add timeline tracks duplicating option

#519
This commit is contained in:
Wojtek Figat
2021-08-26 12:13:14 +02:00
parent ba09d9111e
commit 7198fdd74a
5 changed files with 154 additions and 3 deletions

View File

@@ -288,6 +288,9 @@ namespace FlaxEditor.GUI.Timeline.Tracks
/// <inheritdoc />
public override bool CanRename => false;
/// <inheritdoc />
public override bool CanCopyPaste => false;
/// <summary>
/// Called when member gets changed.
/// </summary>
@@ -314,6 +317,14 @@ namespace FlaxEditor.GUI.Timeline.Tracks
}
}
/// <inheritdoc />
public override void OnDuplicated(Track clone)
{
base.OnDuplicated(clone);
clone.Name = Guid.NewGuid().ToString("N");
}
private void OnTimelineShowPreviewValuesChanged()
{
_previewValue.Visible = Timeline.ShowPreviewValues;