Skip to content
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 WTreeView loading. See #11240 #199

Closed
wants to merge 1 commit into from

Conversation

jhnstrk
Copy link
Contributor

@jhnstrk jhnstrk commented Jan 10, 2023

When rows are removed, WTreeView::modelRowsAboutToBeRemoved calls isExpandedRecursive to determine if rendered tree nodes are impacted by the removal. However, isExpandedRecursive was always returning false for the root node. This seems odd, when the root node is always expanded. This behaviour caused a bug because the removedHeight_ was not being set. This lead to the childrenHeight not being updated, and the loading isn't triggered.

Switching isExpandedRecursive to true for the root index fixes the issue ... but maybe it was intentionally set like this, but I can't see why.

@emweb
Copy link
Collaborator

emweb commented Jan 11, 2023

Thanks. Having it return false on the root index doesn't make any sense to me either.

I manually merged this with some changes (adding your description to the commit message and adding release notes), so I'm closing this PR.

Roel

@emweb emweb closed this Jan 11, 2023
@jhnstrk jhnstrk deleted the 11240_lazy_loading branch January 12, 2023 20:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants