Skip to content

HeaderFooterLayout: Hide old items

Old items should be hidden when assigning new ones, otherwise they'd just stay there being visible, even if behind the new items. QQuickControl and QQuickPage do that (Control also goes a bit overboard and in addition makes old contentItem explicitly invisible).

Ideally, we should be able to use "Deferred" pointer execution like Q_CLASSINFO("DeferredPropertyNames", "background,contentItem"), but at the moment of writing QQuickDeferredPointer is a private API.

Before:
image

After:
image

Merge request reports