Skip to content

Commit

Permalink
Optim: optimize controlling sense of tab dragging
Browse files Browse the repository at this point in the history
  • Loading branch information
inmny committed Nov 27, 2023
1 parent f1fb7a6 commit bca2001
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions general/ui/tab/TabManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -237,8 +237,11 @@ void swap(bool left)
_updateTabEntryRectAs(tab_entries[index], index);
_updateTabEntryRectAs(tab_entries[index + (left ? -1 : 1)], index + (left ? -1 : 1));
var position = tab_entry_rect.localPosition;
delta.x = 0;
current_pos = position;
if(Math.Abs(position.y - current_pos.y) > 0.01f)
{
delta.x = 0;
current_pos = position;
}
}

if (index == 0)
Expand Down

0 comments on commit bca2001

Please sign in to comment.