diff options
| author | Andrew Lee <alee14498@protonmail.com> | 2020-08-20 23:40:50 -0400 |
|---|---|---|
| committer | Andrew Lee <alee14498@protonmail.com> | 2020-08-20 23:40:50 -0400 |
| commit | 3af4c218c0e70167db23a6303d2af30aff37d2fe (patch) | |
| tree | 927f29edcf54ab562f40f3d1c6cb69287c7f5980 /Library/PackageCache/com.unity.timeline@1.2.13/Editor/treeview/ManipulationsTracks.cs | |
| parent | b6daed0af784f4e9bc13329dd87c671b06ee1c65 (diff) | |
| download | Project-Sandbox-3af4c218c0e70167db23a6303d2af30aff37d2fe.tar.gz Project-Sandbox-3af4c218c0e70167db23a6303d2af30aff37d2fe.tar.bz2 Project-Sandbox-3af4c218c0e70167db23a6303d2af30aff37d2fe.zip | |
Removed a bunch of stuff; Changes
Diffstat (limited to 'Library/PackageCache/com.unity.timeline@1.2.13/Editor/treeview/ManipulationsTracks.cs')
| -rw-r--r-- | Library/PackageCache/com.unity.timeline@1.2.13/Editor/treeview/ManipulationsTracks.cs | 103 |
1 files changed, 0 insertions, 103 deletions
diff --git a/Library/PackageCache/com.unity.timeline@1.2.13/Editor/treeview/ManipulationsTracks.cs b/Library/PackageCache/com.unity.timeline@1.2.13/Editor/treeview/ManipulationsTracks.cs deleted file mode 100644 index 3bd2a1c..0000000 --- a/Library/PackageCache/com.unity.timeline@1.2.13/Editor/treeview/ManipulationsTracks.cs +++ /dev/null @@ -1,103 +0,0 @@ -using System.Linq; -using UnityEngine; -using UnityEngine.Timeline; - -namespace UnityEditor.Timeline -{ - class InlineCurveResize : Manipulator - { - bool m_Captured; - - float m_CapturedHeight; - float m_CaptureMouseYPos; - - InlineCurveResizeHandle m_Target; - - protected override bool MouseDown(Event evt, WindowState state) - { - m_Target = PickerUtils.PickedInlineCurveResizer(); - if (m_Target == null) - return false; - - m_Captured = true; - m_CapturedHeight = TimelineWindowViewPrefs.GetInlineCurveHeight(m_Target.trackGUI.track); - m_CaptureMouseYPos = GUIUtility.GUIToScreenPoint(Event.current.mousePosition).y; - state.AddCaptured(this); - - return true; - } - - protected override bool MouseDrag(Event evt, WindowState state) - { - if (!m_Captured || m_Target == null) - return false; - - var trackGUI = m_Target.trackGUI; - - float inlineTrackHeight = m_CapturedHeight + - (GUIUtility.GUIToScreenPoint(Event.current.mousePosition).y - m_CaptureMouseYPos); - - TimelineWindowViewPrefs.SetInlineCurveHeight(trackGUI.track, Mathf.Max(inlineTrackHeight, 60.0f)); - - state.GetWindow().treeView.CalculateRowRects(); - - return true; - } - - protected override bool MouseUp(Event evt, WindowState state) - { - if (!m_Captured) - return false; - - state.RemoveCaptured(this); - m_Captured = false; - - return true; - } - } - - class TrackDoubleClick : Manipulator - { - protected override bool DoubleClick(Event evt, WindowState state) - { - if (evt.button != 0) - return false; - - var trackGUI = PickerUtils.PickedTrackBaseGUI(); - - if (trackGUI == null) - return false; - - // Double-click is only available for AnimationTracks: it conflicts with selection mechanics on other tracks - if ((trackGUI.track as AnimationTrack) == null) - return false; - - return EditTrackInAnimationWindow.Do(state, trackGUI.track); - } - } - - class TrackShortcutManipulator : Manipulator - { - protected override bool ExecuteCommand(Event evt, WindowState state) - { - if (state.IsCurrentEditingASequencerTextField()) - return false; - - var tracks = SelectionManager.SelectedTracks().ToList(); - - var itemGUIs = SelectionManager.SelectedClipGUI(); - - foreach (var itemGUI in itemGUIs) - { - var trackGUI = itemGUI.parent == null ? null : itemGUI.parent as TimelineTrackBaseGUI; - if (trackGUI == null) - continue; - - if (!tracks.Contains(trackGUI.track)) - tracks.Add(trackGUI.track); - } - - return TrackAction.HandleShortcut(state, evt, tracks.ToArray()); - } - } -} |
