Initial Commit

This commit is contained in:
Sebastian Cabrera 2021-08-02 05:44:37 -04:00
parent 53eb92e9af
commit 270ab7d11f
15341 changed files with 700234 additions and 0 deletions

View file

@ -0,0 +1,49 @@
using System;
using UnityEngine;
namespace UnityEditor.Timeline
{
class HeaderSplitterManipulator : Manipulator
{
bool m_Captured;
protected override bool MouseDown(Event evt, WindowState state)
{
Rect headerSplitterRect = state.GetWindow().headerSplitterRect;
if (headerSplitterRect.Contains(evt.mousePosition))
{
m_Captured = true;
state.AddCaptured(this);
return true;
}
return false;
}
protected override bool MouseDrag(Event evt, WindowState state)
{
if (!m_Captured)
return false;
state.sequencerHeaderWidth = evt.mousePosition.x;
return true;
}
protected override bool MouseUp(Event evt, WindowState state)
{
if (!m_Captured)
return false;
state.RemoveCaptured(this);
m_Captured = false;
return true;
}
public override void Overlay(Event evt, WindowState state)
{
Rect rect = state.GetWindow().sequenceRect;
EditorGUIUtility.AddCursorRect(rect, MouseCursor.SplitResizeLeftRight);
}
}
}