-
-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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(Object): dirty unflagging inconsistency #8910
Conversation
Build Stats
|
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.
ready
Can you explain the issue in the PR please? |
Code is heavily overriding the render cycle. There is a state check involving the dirty flag. |
yes i just want to have a PR description that is different from |
Yeah, I get that. For sure. |
Motivation
The Object is technically dirty until a new drawing is completed.
So it make sense to change the flag status AFTER and not before the render operation.
This because
drawObject
could be heavily overridden with custom logic that require the true status of the dirty flag.Before this change the value would be always
false
if called in a caching sequence and that is incorrect.Description
Object should unflag dirty after
drawObject
, see ref:fabric.js/src/shapes/Object/Object.ts
Lines 768 to 769 in d7bb027
Changes
Consistently mark object as not dirty after calling
drawObject
Gist
In Action