Modelowanie_Wirtualnych_Swi.../Library/PackageCache/com.unity.timeline@1.5.4/Editor/Utilities/TrackModifier.cs

22 lines
585 B
C#
Raw Permalink Normal View History

2021-07-09 23:35:24 +02:00
using UnityEngine;
using UnityEditor;
using UnityEngine.Timeline;
using UnityEngine.Playables;
namespace UnityEditor.Timeline
{
static class TrackModifier
{
public static bool DeleteTrack(TimelineAsset timeline, TrackAsset track)
{
if (TimelineEditor.inspectedDirector != null)
{
TimelineUndo.PushUndo(TimelineEditor.inspectedDirector, L10n.Tr("Delete Track"));
TimelineEditor.inspectedDirector.ClearGenericBinding(track);
}
return timeline.DeleteTrack(track);
}
}
}