garettbass / UnityExtensions.ArrayDrawer

ArrayDrawer is a base class like PropertyDrawer, but for arrays and lists.
MIT License
131 stars 21 forks source link

Wrong ordering on drag/drop #9

Closed belzecue closed 5 years ago

belzecue commented 5 years ago

https://imgur.com/ybzdGWD

Not sure what's happening here with the out of sequence ordering...

garettbass commented 5 years ago

I recall fixing this bug in a fork of the project. I believe the error is in the commit titled “new features for ReorderableLists“, in the changes to ReorderableListOfValues.cs, possibly around the methods OnSelectCallback() and OnReorderCallback(), maybe something wrong with my assumptions about the drag or drop index.

garettbass commented 5 years ago

If you are git-savvy, you may try syncing to just before that commit to see if the problem goes away.

belzecue commented 5 years ago

Thanks for looking into it.

I rolled back to 158770e11d7c0698ea941fcc2e5324128ebba9b5 (behind “new features for ReorderableLists“) and the ordering works as expected.

https://imgur.com/tY6PiT3

extrawurst commented 5 years ago

How can this be fixed?

garettbass commented 5 years ago

Hello, I have pushed a fix for this issue.

extrawurst commented 5 years ago

Thank you @garettbass so much! 👍