/// <summary> /// Initializes a new instance of the <see cref="AnimationTimeline"/> class. /// </summary> /// <param name="undo">The undo/redo to use for the history actions recording. Optional, can be null to disable undo support.</param> public AnimationTimeline(FlaxEditor.Undo undo) : base(PlaybackButtons.None, undo, false, false) { PlaybackState = PlaybackStates.Seeking; ShowPreviewValues = false; PropertiesEditObject = new Proxy(this); // Setup track types TrackArchetypes.Add(AnimationChannelTrack.GetArchetype()); TrackArchetypes.Add(AnimationChannelDataTrack.GetArchetype()); }
/// <summary> /// Initializes a new instance of the <see cref="ParticleSystemTimeline"/> class. /// </summary> /// <param name="preview">The particle system preview.</param> public ParticleSystemTimeline(ParticleSystemPreview preview) : base(PlaybackButtons.Play | PlaybackButtons.Stop) { PlaybackState = PlaybackStates.Playing; PropertiesEditObject = new Proxy(this); _preview = preview; // Setup track types TrackArchetypes.Add(ParticleEmitterTrack.GetArchetype()); TrackArchetypes.Add(FolderTrack.GetArchetype()); }
/// <summary> /// Initializes a new instance of the <see cref="SceneAnimationTimeline"/> class. /// </summary> public SceneAnimationTimeline() : base(PlaybackButtons.Play | PlaybackButtons.Stop) { // Setup track types var icons = Editor.Instance.Icons; TrackArchetypes.Add(new TrackArchetype { Name = "Folder", Icon = icons.Folder64, Create = archetype => new FolderTrack(archetype, false), }); }
/// <summary> /// Initializes a new instance of the <see cref="ParticleSystemTimeline"/> class. /// </summary> /// <param name="preview">The particle system preview.</param> public ParticleSystemTimeline(ParticleSystemPreview preview) : base(PlaybackButtons.Play | PlaybackButtons.Stop) { _preview = preview; // Setup track types var icons = Editor.Instance.Icons; TrackArchetypes.Add(new TrackArchetype { Name = "Folder", Icon = icons.Folder64, Create = archetype => new FolderTrack(archetype, false), }); TrackArchetypes.Add(new TrackArchetype { Name = "Emitter", Create = archetype => new ParticleEmitterTrack(archetype, false), }); }