-
-
Notifications
You must be signed in to change notification settings - Fork 3.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
[SelectiveMasking] Fix masks UI update #57679
Conversation
Create a data structure on stack to avoid useless QTreeWidgetItem heap memory allocation which slows down considerably widget populate.
Fixes qgis#57248 Remove flaky code used to avoid as much as possible masking widget populate. This cause refresh issues and populate is now way more efficient.
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.
Looks good to me. I've left some nitpicking comments but I specially love the testcase !
The backport to
stderr
stdout
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-queued_ltr_backports queued_ltr_backports
# Navigate to the new working tree
cd .worktrees/backport-queued_ltr_backports
# Create a new branch
git switch --create backport-57679-to-queued_ltr_backports
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick bc107e5ecc2cbd8c57d18d88cb5bbb78199c9d12,e6646ec4c47e56019e2d64373d9d575d8904476a,738295481b92364884f8f6fbf933e9cccb27cbb4,02adff26d4e7b5d622dd6e40a6354a411bc01264
# Push it to GitHub
git push --set-upstream origin backport-57679-to-queued_ltr_backports
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-queued_ltr_backports Then, create a pull request where the |
Create a data structure on stack to avoid useless QTreeWidgetItem heap memory allocation which slows down considerably widget populate. That allows then to remove some flaky code used to avoid as much as possible masking widget update, causing refresh issues.
I tested it with the #34942 use case where masking widget populate was almost 3s. Since those modifications, populate is less than 50ms, so we can just update the masking widget every time it's useful.