-
-
Notifications
You must be signed in to change notification settings - Fork 21.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix reparenting after hover delay #91265
Conversation
Seems to work perfectly. Thanks! |
One thing that makes me ticks is that the bug was supposedly introduced by #90653 but this fix does not touch code related. This might still be the proper fix but ask the question on why it does not implicate the code that broke it. I'll try to take a look when I have time most likely sometime between monday and tuesday. |
Hello 👋
Thanks for your test and feedback!
The way I was ensuring that the inspected/hovered Node/TreeItem got selected and added to history when the drag ended was by using While I was at it, I removed the use of the Anyway, if you can take a look at it when you have the time that would be greatly appreciated ! If you think you need to superseed (I think that's the term) it to make some more in depth changes, no problem, or if I need to make more corrections, let me know 👍. Thanks a lot ! |
Retested this, and realized this approach still have issue with the path(s) used in the history when reparenting. EDIT : The issue had nothing to do with this fix |
8634c99
to
d557074
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes look fine. There is a minor issue where the inspected node does not appear at the top, but it can be fixed later:
godot.windows.editor.dev.x86_64_HVzun4zCyh.mp4
Yes indeed, right now it will do it only once the drag is ended. Tho I've realized another small issue caused with those new changes is that if you inspect a node by hovering it, then while dragging towards the inspector you somehow pass the mouse over another node it would not select the inspected node at the end of the drag but the last one hovered instead, so I've made another small change : instead of selecting the |
d557074
to
829bedc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks really good! There is a problem with selection history but this can be fixed later as it is non blocking and only slightly related
|
||
for (Node *E : full_selection) { | ||
editor_selection->add_node(E); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why is this needed? I'm wondering as this might make #91860 resurface
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case it is for consistency so that when you reparent using the right click option Reparent
it also keep all the reparented nodes selected. I will test with the fix for the issue you pointed to make sure it does not brake it again, if it does tho I will just remove that for now since it is not that important
EDIT : Tested with the fix and it does not make the issue you've mentionned resurface
Thanks! |
Fix #91254
Also keep all nodes selected after reparenting and not just top level ones (before hover delay, because after it's the hovered/inspected node that should be the one selected)