qml gridview don't have an official way to ensure the
current index is visible when the view is first instantiated,
the only way we have is to do positionViewAtIndex when we know the
proper space has already been allocated (Component.onCompleted
is way too early) we used to do that on onCountChanged, but that
too seems to early sometimes, as the selected wallpaper
is visible only sometimes, attaching it to onContentHeightChanged
seems to be more reliable (for all branches)
Details
Details
- Reviewers
davidedmundson - Group Reviewers
Plasma - Commits
- R120:ed2f9de7f4c2: try harder to make the selected wallpaper visible
R871:ff602030827d: try harder to make the selected wallpaper visible
R120:0eab04a3b549: try harder to make the selected wallpaper visible
R120:ff602030827d: try harder to make the selected wallpaper visible
R871:0eab04a3b549: try harder to make the selected wallpaper visible
proper wallpaper is visible every time the window opens
Diff Detail
Diff Detail
- Repository
- R120 Plasma Workspace
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Comment Actions
I've used multiple techniques to do similar "do stuff when positioning is complete". One is using PropertyChange in populate transitions to change a prop when populate is done.
I think Qt 5.9 will actually have an onPositioningComplete (at least for Flow).
Comment Actions
seems is only for positioners tough, not views (in which i guess it would be harder as the model can start to move things around at any moment)