TabBar: don't cull tabs when contentItem isn't a view


QQuickTabBar::itemAdded() culls every tab, relying on the contentItem
(a ListView) to uncull the ones that it shows. A contentItem that
isn't a view, such as a Row containing a Repeater, never does that.

19637c2241724cac55315afbb70b5f4333a2065b worked around this for
Repeater by unculling items from an ObjectModel as it creates them.
However, for a tab that is added after the Repeater was created, that
happens before itemAdded() is called, so the tab ends up culled and is
never shown.

Only cull the tab if the contentItem is a view, like
QQuickContainerPrivate::maybeCullItem() does.

Introduced by 167f38750f23d226e1b5fc18f783fe6f4d4adf3e (TabBar: cull
tabs outside the bar).

Pick-to: 6.12
Change-Id: I08e9aa9953018b4b1f44504050483182810f0434
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
commit002c60cfa9ed63a27636c26008e965cdcbd2541d
parentea9a01d16ae886cacc7c1fc9f6e68a6f3a60a804
authorMitch Curtis <mitch.curtis@qt.io>
committerMitch Curtis <mitch.curtis@qt.io>
commit timeWed, 7 Oct 2026 05:15:15 +0000