Skip to content

Commit 4343463

Browse files
committed
Remove commented code
1 parent 16cd820 commit 4343463

File tree

1 file changed

+0
-20
lines changed

1 file changed

+0
-20
lines changed

Packages/com.unity.inputsystem/InputSystem/Plugins/UI/InputSystemUIInputModule.cs

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2077,14 +2077,6 @@ private bool RemovePointerAtIndex(int index)
20772077

20782078
Debug.Assert(m_PointerStates[index].eventData.pointerEnter == null, "Pointer should have exited all objects before being removed");
20792079

2080-
// // We don't want to release touch pointers on the same frame they are released (unpressed). They get cleaned up one frame later in Process()
2081-
// ref var state = ref GetPointerStateForIndex(index);
2082-
// if (state.pointerType == UIPointerType.Touch && (state.leftButton.isPressed || state.leftButton.wasReleasedThisFrame))
2083-
// {
2084-
// // The pointer was not removed
2085-
// return false;
2086-
// }
2087-
20882080
// Retain event data so that we can reuse the event the next time we allocate a PointerModel record.
20892081
var eventData = m_PointerStates[index].eventData;
20902082
Debug.Assert(eventData != null, "Pointer state should have an event instance!");
@@ -2355,18 +2347,6 @@ private void FilterPointerStatesByType()
23552347
// We have input on a mouse or pen. Kill all touch and tracked pointers we may have.
23562348
for (var i = 0; i < m_PointerStates.length; ++i)
23572349
{
2358-
// ref var state = ref GetPointerStateForIndex(i);
2359-
// // Touch pointers need to get forced to no longer be pressed otherwise they will not get released in subsequent frames.
2360-
// if (m_PointerStates[i].pointerType == UIPointerType.Touch)
2361-
// {
2362-
// state.leftButton.isPressed = false;
2363-
// }
2364-
// if (m_PointerStates[i].pointerType != UIPointerType.MouseOrPen && m_PointerStates[i].pointerType != UIPointerType.Touch || (m_PointerStates[i].pointerType == UIPointerType.Touch && !state.leftButton.isPressed && !state.leftButton.wasReleasedThisFrame))
2365-
// {
2366-
// if (SendPointerExitEventsAndRemovePointer(i))
2367-
// --i;
2368-
// }
2369-
23702350
if (m_PointerStates[i].pointerType != UIPointerType.MouseOrPen)
23712351
{
23722352
if (SendPointerExitEventsAndRemovePointer(i))

0 commit comments

Comments
 (0)