Esempio n. 1
0
        static void FinalizeInsertItemsUsingCurrentEditMode(WindowState state, IList <ItemsPerTrack> itemsGroups, double candidateTime)
        {
            EditMode.FinalizeInsertItemsAtTime(itemsGroups, candidateTime);

            SelectionManager.Clear();
            foreach (var itemsGroup in itemsGroups)
            {
                var track = itemsGroup.targetTrack;
                var items = itemsGroup.items;

                EditModeUtils.SetParentTrack(items, track);

                track.SortClips();

                TrackExtensions.ComputeBlendsFromOverlaps(track.clips);
                track.CalculateExtrapolationTimes();

                foreach (var item in items)
                {
                    if (item.gui != null)
                    {
                        item.gui.Select();
                    }
                }
            }

            var allItems = itemsGroups.SelectMany(x => x.items).ToList();

            foreach (var item in allItems)
            {
                SelectionManager.Add(item);
            }

            FrameItems(state, allItems);
        }
Esempio n. 2
0
        public override bool Execute(WindowState state, TrackAsset[] tracks)
        {
            if (tracks.Any())
            {
                SelectionManager.RemoveTimelineSelection();
            }

            foreach (var track in TrackExtensions.FilterTracks(tracks))
            {
                var newTrack = track.Duplicate(TimelineEditor.inspectedDirector, TimelineEditor.inspectedDirector);
                SelectionManager.Add(newTrack);
                foreach (var childTrack in newTrack.GetFlattenedChildTracks())
                {
                    SelectionManager.Add(childTrack);
                }

                if (TimelineEditor.inspectedDirector != null)
                {
                    var binding = TimelineEditor.inspectedDirector.GetGenericBinding(track);
                    if (binding != null)
                    {
                        TimelineUndo.PushUndo(TimelineEditor.inspectedDirector, "Duplicate");
                        TimelineEditor.inspectedDirector.SetGenericBinding(newTrack, binding);
                    }
                }
            }

            state.Refresh();

            return(true);
        }
        void DrawRemoveMenu(Rect headerRect, WindowState state)
        {
            const float pad        = 3;
            const float buttonSize = 16;
            var         buttonRect = new Rect(headerRect.xMax - buttonSize - pad, headerRect.y + ((headerRect.height - buttonSize) / 2f) + 2, buttonSize, buttonSize);

            if (GUI.Button(buttonRect, GUIContent.none, DirectorStyles.Instance.trackOptions))
            {
                GenericMenu menu = new GenericMenu();

                var owner            = m_Owner;
                var scriptableObject = m_ScriptableObject;

                menu.AddItem(Styles.RemoveTrack, false, () =>
                {
                    if (TrackExtensions.RemoveBrokenTrack(owner, scriptableObject))
                    {
                        state.Refresh();
                    }
                }
                             );

                menu.ShowAsContext();
            }
        }
Esempio n. 4
0
        public void CopyTracks(IEnumerable <TrackAsset> tracks)
        {
            using (new TimelineUndo.DisableUndoGuard(true))
            {
                foreach (var track in TrackExtensions.FilterTracks(tracks))
                {
                    var newTrack = track.Duplicate(TimelineEditor.inspectedDirector, TimelineEditor.clipboard.exposedPropertyTable, rootTimeline);

                    var originalTracks = track.GetFlattenedChildTracks().Append(track);
                    var newTracks      = newTrack.GetFlattenedChildTracks().Append(newTrack);

                    var toBind = new List <Object>();

                    // Collect all track bindings to duplicate
                    var originalIt = originalTracks.GetEnumerator();
                    var newIt      = newTracks.GetEnumerator();
                    while (originalIt.MoveNext() && newIt.MoveNext())
                    {
                        toBind.Add(TimelineEditor.inspectedDirector != null ? TimelineEditor.inspectedDirector.GetGenericBinding(originalIt.Current) : null);
                    }
                    m_trackData.Add(new ClipboardTrackEntry {
                        item = newTrack, parent = track.parent as TrackAsset, bindings = toBind
                    });
                }
            }
        }
Esempio n. 5
0
        public override bool Execute(IEnumerable <TrackAsset> tracks)
        {
            tracks = tracks.RemoveTimelineMarkerTrackFromList(TimelineEditor.inspectedAsset);
            if (tracks.Any())
            {
                SelectionManager.RemoveTimelineSelection();
            }

            foreach (var track in TrackExtensions.FilterTracks(tracks))
            {
                var newTrack = track.Duplicate(TimelineEditor.inspectedDirector, TimelineEditor.inspectedDirector);
                SelectionManager.Add(newTrack);
                foreach (var childTrack in newTrack.GetFlattenedChildTracks())
                {
                    SelectionManager.Add(childTrack);
                }

                if (TimelineEditor.inspectedDirector != null)
                {
                    var binding = TimelineEditor.inspectedDirector.GetGenericBinding(track);
                    if (binding != null)
                    {
                        TimelineUndo.PushUndo(TimelineEditor.inspectedDirector, L10n.Tr("Duplicate"));
                        TimelineEditor.inspectedDirector.SetGenericBinding(newTrack, binding);
                    }
                }
            }

            TimelineEditor.Refresh(RefreshReason.ContentsAddedOrRemoved);

            return(true);
        }
Esempio n. 6
0
        public static TimelineClip Duplicate(this TimelineClip clip, PlayableDirector director)
        {
            TrackAsset    parentTrack   = clip.parentTrack;
            TimelineAsset timelineAsset = parentTrack.timelineAsset;
            TimelineClip  result;

            if (parentTrack == null || timelineAsset == null)
            {
                result = null;
            }
            else
            {
                double num = ClipExtensions.FindClipInsertionTime(clip, parentTrack.clips);
                if (double.IsInfinity(num))
                {
                    result = null;
                }
                else
                {
                    TimelineUndo.PushUndo(parentTrack, "Clone Clip");
                    TimelineClip timelineClip = TimelineHelpers.Clone(clip, director);
                    timelineClip.start = num;
                    clip.parentTrack.AddClip(timelineClip);
                    clip.parentTrack.SortClips();
                    TrackExtensions.ComputeBlendsFromOverlaps(clip.parentTrack.clips);
                    result = timelineClip;
                }
            }
            return(result);
        }
        public override bool Execute(IEnumerable <TrackAsset> tracks)
        {
            tracks = tracks.RemoveTimelineMarkerTrackFromList(TimelineEditor.inspectedAsset);
            if (tracks.Any())
            {
                SelectionManager.RemoveTimelineSelection();
            }

            foreach (var track in TrackExtensions.FilterTracks(tracks))
            {
                var newTrack = track.Duplicate(TimelineEditor.inspectedDirector, TimelineEditor.inspectedDirector);
                //Add all duplicated tracks to selection
                SelectionManager.Add(newTrack);
                foreach (var childTrack in newTrack.GetFlattenedChildTracks())
                {
                    SelectionManager.Add(childTrack);
                }

                //Duplicate bindings for tracks and subtracks
                if (TimelineEditor.inspectedDirector != null)
                {
                    DuplicateBindings(track, newTrack, TimelineEditor.inspectedDirector);
                }
            }

            TimelineEditor.Refresh(RefreshReason.ContentsAddedOrRemoved);

            return(true);
        }
Esempio n. 8
0
        static void PasteTracks()
        {
            var trackData = TimelineEditor.clipboard.GetTracks().ToList();

            if (trackData.Any())
            {
                SelectionManager.RemoveTimelineSelection();
            }

            foreach (var track in trackData)
            {
                var newTrack = track.item.Duplicate(TimelineEditor.clipboard.exposedPropertyTable, TimelineEditor.inspectedDirector, TimelineEditor.inspectedAsset);
                if (track.binding != null)
                {
                    TimelineHelpers.Bind(newTrack, track.binding, TimelineEditor.inspectedDirector);
                }

                SelectionManager.Add(newTrack);
                foreach (var childTrack in newTrack.GetFlattenedChildTracks())
                {
                    SelectionManager.Add(childTrack);
                }

                if (track.parent != null && track.parent.timelineAsset == TimelineEditor.inspectedAsset)
                {
                    TrackExtensions.ReparentTracks(new List <TrackAsset> {
                        newTrack
                    }, track.parent, track.item);
                }
            }
        }
Esempio n. 9
0
        static void PasteTracks(WindowState state)
        {
            var trackData = TimelineEditor.clipboard.GetTracks().ToList();

            if (trackData.Any())
            {
                SelectionManager.RemoveTimelineSelection();
            }

            foreach (var track in trackData)
            {
                var newTrack = track.item.Duplicate(state.editSequence.director, state.editSequence.asset);
                SelectionManager.Add(newTrack);
                foreach (var childTrack in newTrack.GetFlattenedChildTracks())
                {
                    SelectionManager.Add(childTrack);
                }

                if (track.parent != null && track.parent.timelineAsset == state.editSequence.asset)
                {
                    TrackExtensions.ReparentTracks(new List <TrackAsset> {
                        newTrack
                    }, track.parent, track.item);
                }
            }
        }
Esempio n. 10
0
        public static TimelineClip DuplicateAtTime(this TimelineClip clip, TrackAsset track, double time, PlayableDirector director)
        {
            TimelineUndo.PushUndo(track, "Clone Clip");
            TimelineClip timelineClip = TimelineHelpers.Clone(clip, director);

            timelineClip.start       = time;
            timelineClip.parentTrack = track;
            track.AddClip(timelineClip);
            track.SortClips();
            TrackExtensions.ComputeBlendsFromOverlaps(track.clips);
            return(timelineClip);
        }
Esempio n. 11
0
 public void CopyTracks(IEnumerable <TrackAsset> tracks)
 {
     using (new TimelineUndo.DisableUndoGuard(true))
     {
         foreach (var track in TrackExtensions.FilterTracks(tracks))
         {
             var newTrack = track.Duplicate(TimelineEditor.inspectedDirector, TimelineEditor.clipboard.exposedPropertyTable, rootTimeline);
             m_trackData.Add(new ClipboardTrackEntry {
                 item = newTrack, parent = track.parent as TrackAsset
             });
         }
     }
 }
        internal static void RecursiveSubtrackClone(TrackAsset source, TrackAsset duplicate, PlayableDirector director)
        {
            List <TrackAsset> subTracks = source.subTracks;

            foreach (TrackAsset current in subTracks)
            {
                TrackAsset trackAsset = TimelineHelpers.Clone(duplicate, current, director);
                duplicate.AddChild(trackAsset);
                TrackExtensions.RecursiveSubtrackClone(current, trackAsset, director);
                Undo.RegisterCreatedObjectUndo(trackAsset, "Duplicate");
                TimelineCreateUtilities.SaveAssetIntoObject(trackAsset, source);
            }
        }
 public void CopyTracks(IEnumerable <TrackAsset> tracks)
 {
     using (new TimelineUndo.DisableUndoGuard(true))
     {
         foreach (var track in TrackExtensions.FilterTracks(tracks))
         {
             var newTrack = track.Duplicate(TimelineWindow.instance.state.editSequence.director,
                                            rootTimeline);
             m_trackData.Add(new ClipboardTrackEntry {
                 item = newTrack, parent = track.parent as TrackAsset
             });
         }
     }
 }
        internal static bool Duplicate(this TrackAsset track, PlayableDirector director, TimelineAsset destinationTimeline = null)
        {
            bool result;

            if (track == null)
            {
                result = false;
            }
            else
            {
                if (destinationTimeline == track.timelineAsset)
                {
                    destinationTimeline = null;
                }
                TimelineAsset timelineAsset = track.parent as TimelineAsset;
                TrackAsset    trackAsset    = track.parent as TrackAsset;
                if (timelineAsset == null && trackAsset == null)
                {
                    Debug.LogWarning("Cannot duplicate track because it is not parented to known type");
                    result = false;
                }
                else
                {
                    PlayableAsset playableAsset = destinationTimeline ?? track.parent;
                    TrackAsset    trackAsset2   = TimelineHelpers.Clone(playableAsset, track, director);
                    TrackExtensions.RecursiveSubtrackClone(track, trackAsset2, director);
                    Undo.RegisterCreatedObjectUndo(trackAsset2, "Duplicate");
                    TimelineCreateUtilities.SaveAssetIntoObject(trackAsset2, playableAsset);
                    TimelineUndo.PushUndo(playableAsset, "Duplicate");
                    if (destinationTimeline != null)
                    {
                        destinationTimeline.AddTrackInternal(trackAsset2);
                    }
                    else if (timelineAsset != null)
                    {
                        TrackExtensions.ReparentTracks(new List <TrackAsset>
                        {
                            trackAsset2
                        }, timelineAsset, track, false);
                    }
                    else
                    {
                        trackAsset.AddChildAfter(trackAsset2, track);
                    }
                    result = true;
                }
            }
            return(result);
        }
Esempio n. 15
0
        public static TimelineClip Clone(TimelineClip clip, IExposedPropertyTable sourceTable, IExposedPropertyTable destTable, double time, PlayableAsset newOwner = null)
        {
            if (newOwner == null)
            {
                newOwner = clip.parentTrack;
            }

            TimelineClip newClip = DuplicateClip(clip, sourceTable, destTable, newOwner);

            newClip.start = time;
            var track = newClip.parentTrack;

            track.SortClips();
            TrackExtensions.ComputeBlendsFromOverlaps(track.clips);
            return(newClip);
        }
Esempio n. 16
0
        public static TimelineClip Clone(TimelineClip clip, PlayableDirector director, double time, PlayableAsset newOwner = null)
        {
            if (newOwner == null)
            {
                newOwner = clip.parentTrack;
            }

            TimelineClip newClip = DuplicateClip(clip, director, newOwner);

            newClip.start = time;
            var track = newClip.parentTrack;

            track.SortClips();
            TrackExtensions.ComputeBlendsFromOverlaps(track.clips);
            return(newClip);
        }
        public override bool Execute(WindowState state, TrackAsset[] tracks)
        {
            if (tracks.Any())
            {
                SelectionManager.RemoveTimelineSelection();
            }

            foreach (var track in TrackExtensions.FilterTracks(tracks))
            {
                var newTrack = track.Duplicate(TimelineEditor.inspectedDirector, TimelineEditor.inspectedDirector);
                SelectionManager.Add(newTrack);
                foreach (var childTrack in newTrack.GetFlattenedChildTracks())
                {
                    SelectionManager.Add(childTrack);
                }
            }

            state.Refresh();

            return(true);
        }
 internal static void ComputeBlendsFromOverlaps(TimelineClip[] clips)
 {
     for (int i = 0; i < clips.Length; i++)
     {
         TimelineClip timelineClip = clips[i];
         timelineClip.blendInDuration  = -1.0;
         timelineClip.blendOutDuration = -1.0;
     }
     for (int j = 0; j < clips.Length; j++)
     {
         TimelineClip blendIn2      = clips[j];
         TimelineClip blendIn       = blendIn2;
         TimelineClip timelineClip2 = (from c in clips
                                       where TrackExtensions.Overlaps(c, blendIn)
                                       orderby c.start
                                       select c).FirstOrDefault <TimelineClip>();
         if (timelineClip2 != null)
         {
             TrackExtensions.UpdateClipIntersection(timelineClip2, blendIn);
         }
     }
 }
        static void PasteTracks()
        {
            var trackData = TimelineEditor.clipboard.GetTracks().ToList();

            if (trackData.Any())
            {
                SelectionManager.RemoveTimelineSelection();
            }

            foreach (var track in trackData)
            {
                var newTrack  = track.item.Duplicate(TimelineEditor.clipboard.exposedPropertyTable, TimelineEditor.inspectedDirector, TimelineEditor.inspectedAsset);
                var newTracks = newTrack.GetFlattenedChildTracks().Append(newTrack);

                var bindingIt  = track.bindings.GetEnumerator();
                var newTrackIt = newTracks.GetEnumerator();

                while (bindingIt.MoveNext() && newTrackIt.MoveNext())
                {
                    if (bindingIt.Current != null)
                    {
                        BindingUtility.Bind(TimelineEditor.inspectedDirector, newTrackIt.Current, bindingIt.Current);
                    }
                }

                SelectionManager.Add(newTrack);
                foreach (var childTrack in newTrack.GetFlattenedChildTracks())
                {
                    SelectionManager.Add(childTrack);
                }

                if (track.parent != null && track.parent.timelineAsset == TimelineEditor.inspectedAsset)
                {
                    TrackExtensions.ReparentTracks(new List <TrackAsset> {
                        newTrack
                    }, track.parent, track.item);
                }
            }
        }
 public static void ComputeBlendsFromOverlaps(this TrackAsset asset)
 {
     TrackExtensions.ComputeBlendsFromOverlaps(asset.clips);
 }
Esempio n. 21
0
 private void UpdateClipOverlaps()
 {
     TrackExtensions.ComputeBlendsFromOverlaps((from c in this.m_ClipGUICache
                                                select c.clip).ToArray <TimelineClip>());
 }
Esempio n. 22
0
 public override void Init(IControl parent)
 {
     parent.MouseDown += delegate(object target, Event evt, TimelineWindow.TimelineState state)
     {
         this.m_UndoSet    = false;
         this.m_IsCaptured = (this.m_CaptureOnNextMouseDrag = false);
         bool result;
         if (evt.get_modifiers() == 4 || evt.get_button() == 2 || evt.get_button() == 1)
         {
             result = base.IgnoreEvent();
         }
         else if (!SelectionManager.IsMouseHoveringOnItem())
         {
             result = base.IgnoreEvent();
         }
         else
         {
             TimelineClipGUI timelineClipGUI = (TimelineClipGUI)target;
             if (!SelectionManager.Contains(timelineClipGUI.clip))
             {
                 result = base.IgnoreEvent();
             }
             else
             {
                 this.m_FrameSnap.Reset();
                 this.m_CaptureOnNextMouseDrag = true;
                 this.m_MouseDownPosition      = evt.get_mousePosition();
                 this.m_HasValidDropTarget     = false;
                 result = base.ConsumeEvent();
             }
         }
         return(result);
     };
     parent.MouseUp += delegate(object target, Event evt, TimelineWindow.TimelineState state)
     {
         bool result;
         if (!this.m_IsCaptured)
         {
             result = base.IgnoreEvent();
         }
         else
         {
             this.m_MagnetEngine = null;
             if (this.m_IsVerticalDrag)
             {
                 state.captured.Clear();
                 this.m_IsVerticalDrag = false;
                 state.isDragging      = false;
                 if (this.m_HasValidDropTarget && this.m_DropTarget != null)
                 {
                     TimelineClipGUI timelineClipGUI = (TimelineClipGUI)target;
                     if (TrackExtensions.MoveClipToTrack(timelineClipGUI.clip, this.m_DropTarget.track))
                     {
                         timelineClipGUI.clip.start = (double)state.PixelToTime(this.m_PreviewRect.get_x());
                         timelineClipGUI.parentTrackGUI.SortClipsByStartTime();
                         this.m_DropTarget.SortClipsByStartTime();
                         state.Refresh();
                     }
                 }
             }
             state.Evaluate();
             state.captured.Remove(target as IControl);
             this.m_IsCaptured   = false;
             this.m_IsDragDriver = false;
             result = base.ConsumeEvent();
         }
         return(result);
     };
     parent.DragExited += delegate(object target, Event evt, TimelineWindow.TimelineState state)
     {
         this.m_IsVerticalDrag = false;
         return(base.IgnoreEvent());
     };
     parent.MouseDrag += delegate(object target, Event evt, TimelineWindow.TimelineState state)
     {
         if (!this.m_IsCaptured && this.m_CaptureOnNextMouseDrag)
         {
             state.captured.Add(target as IControl);
             this.m_IsCaptured             = true;
             this.m_CaptureOnNextMouseDrag = false;
             TimelineClipGUI timelineClipGUI = (TimelineClipGUI)target;
             this.m_IsDragDriver = MoveItemUtilities.IsDriver(timelineClipGUI, evt, state);
             if (this.m_IsDragDriver)
             {
                 this.m_DragPixelOffset    = Vector2.get_zero();
                 this.m_IsDragDriverActive = false;
                 if (!SelectionManager.IsMultiSelect() && state.edgeSnaps)
                 {
                     this.m_MagnetEngine = new MagnetEngine(timelineClipGUI, new MoveClipAttractionHandler(), state);
                 }
             }
         }
         bool result;
         if (!this.m_IsCaptured)
         {
             result = base.IgnoreEvent();
         }
         else
         {
             TimelineClipGUI timelineClipGUI2 = (TimelineClipGUI)target;
             if (SelectionManager.Count() == 1)
             {
                 TimelineClipGUI timelineClipGUI3 = SelectionManager.SelectedClipGUI().FirstOrDefault <TimelineClipGUI>();
                 if (timelineClipGUI3 != null)
                 {
                     TimelineTrackGUI dropTargetAt = MoveClip.GetDropTargetAt(state, evt.get_mousePosition());
                     if (dropTargetAt != null)
                     {
                         bool flag = dropTargetAt != timelineClipGUI3.parentTrackGUI;
                         if (flag && !this.m_IsVerticalDrag)
                         {
                             state.isDragging           = true;
                             this.m_HasValidDropTarget  = false;
                             this.m_DropTarget          = null;
                             this.m_MouseDownPosition.x = evt.get_mousePosition().x;
                             this.m_PreviewOffset       = this.m_MouseDownPosition - timelineClipGUI2.bounds.get_position();
                         }
                         else if (this.m_IsVerticalDrag && !flag)
                         {
                             state.isDragging          = false;
                             this.m_HasValidDropTarget = false;
                             this.m_DropTarget         = null;
                             this.m_DragPixelOffset    = evt.get_mousePosition() - this.m_MouseDownPosition - evt.get_delta();
                         }
                         this.m_IsVerticalDrag = flag;
                     }
                 }
             }
             if (this.m_IsVerticalDrag)
             {
                 this.m_PreviewRect = new Rect(evt.get_mousePosition().x, evt.get_mousePosition().y, timelineClipGUI2.bounds.get_width(), timelineClipGUI2.bounds.get_height());
                 this.m_PreviewRect.set_position(this.m_PreviewRect.get_position() - this.m_PreviewOffset);
                 this.UpdateDragTarget(timelineClipGUI2, evt.get_mousePosition(), state);
                 result = base.ConsumeEvent();
             }
             else
             {
                 if (this.m_IsDragDriver)
                 {
                     this.m_DragPixelOffset    += evt.get_delta();
                     this.m_IsDragDriverActive |= (Math.Abs(this.m_DragPixelOffset.x) > MoveClip.kDragBufferInPixels);
                     if (this.m_IsDragDriverActive)
                     {
                         float delta = this.m_DragPixelOffset.x / state.timeAreaScale.x;
                         this.m_DragPixelOffset = Vector3.get_zero();
                         this.SetUndo();
                         if (SelectionManager.IsMultiSelect())
                         {
                             double currentValue = (from x in SelectionManager.SelectedItems <TimelineClip>()
                                                    select x.start).DefaultIfEmpty(timelineClipGUI2.clip.start).Min();
                             this.m_FrameSnap.ApplyOffset(currentValue, delta, state);
                             foreach (TimelineClip current in from x in SelectionManager.SelectedItems <TimelineClip>()
                                      orderby x.start
                                      select x)
                             {
                                 if (current.start + this.m_FrameSnap.lastOffsetApplied < 0.0)
                                 {
                                     break;
                                 }
                                 current.start += this.m_FrameSnap.lastOffsetApplied;
                             }
                         }
                         else
                         {
                             timelineClipGUI2.clip.start = this.m_FrameSnap.ApplyOffset(timelineClipGUI2.clip.start, delta, state);
                         }
                         if (this.m_MagnetEngine != null)
                         {
                             this.m_MagnetEngine.Snap(evt.get_delta().x);
                         }
                         timelineClipGUI2.InvalidateEditor();
                         timelineClipGUI2.parentTrackGUI.SortClipsByStartTime();
                         state.Evaluate();
                     }
                 }
                 result = base.ConsumeEvent();
             }
         }
         return(result);
     };
     parent.Overlay += delegate(object target, Event evt, TimelineWindow.TimelineState state)
     {
         if (this.m_MagnetEngine != null)
         {
             this.m_MagnetEngine.OnGUI();
         }
         bool result;
         if (this.m_IsVerticalDrag)
         {
             TimelineClipGUI timelineClipGUI = (TimelineClipGUI)target;
             Color           color           = (!this.m_HasValidDropTarget) ? DirectorStyles.Instance.customSkin.colorInvalidDropTarget : DirectorStyles.Instance.customSkin.colorValidDropTarget;
             timelineClipGUI.DrawDragPreview(this.m_PreviewRect, color);
             result = base.ConsumeEvent();
         }
         else if (this.m_IsDragDriver)
         {
             IEnumerable <TimelineClip> enumerable = SelectionManager.SelectedItems <TimelineClip>();
             double num  = 1.7976931348623157E+308;
             double num2 = -1.7976931348623157E+308;
             foreach (TimelineClip current in enumerable)
             {
                 if (current.start < num)
                 {
                     num = current.start;
                 }
                 if (current.end > num2)
                 {
                     num2 = current.end;
                 }
             }
             this.m_SelectionIndicator.Draw(num, num2, this.m_MagnetEngine);
             result = base.ConsumeEvent();
         }
         else
         {
             result = base.IgnoreEvent();
         }
         return(result);
     };
 }
Esempio n. 23
0
 void UpdateClipOverlaps()
 {
     TrackExtensions.ComputeBlendsFromOverlaps(track.clips);
 }