-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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 insertion point showing up unexpectedly #44702
Conversation
Size Change: +113 B (0%) Total Size: 1.27 MB
ℹ️ View Unchanged
|
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.
Huge improvement! In trunk, I can move the cursor to where the sibling inserter will be, then move it outside of the canvas, and it appears after a while regardless:
In this branch, if I move the cursor outside of the canvas, it doesn't appear:
This is the desired behavior, green check for that! I'll defer to others on a code review. Thanks Riad!
I'm still seeing an errant inserter under some conditions: sibling-what-is-going-on.mov |
Unfortunately, I was not able to fix all the issues here while keeping the performance tweaks made in #44325. So I now reverted some of these optimizations. |
dce5432
to
5013124
Compare
Closes #44694
What?
Recently, I did a performance optimization to avoid calling too much actions when moving the mouse or scrolling. That introduced a race condition that was causing the insertion point to show up unexpectedly in some situations. Basically a delayed showInsertionPoint function call was not being "canceled" properly as we left the insertion point position. This PR fixes it by making sure that all calls to hideInsertionPoint cancel any scheduled call to showInsertionPoint.
Testing Instructions
1- Open the site editor
2- Hover the area right after the header template part
3- Move the mouse on the template part
4- The insertion point should not appear again.