QAbstractListModel view of the live toplevel set.
Translates ForeignToplevelManager's toplevelAdded / toplevelRemoved signals into proper beginInsertRows / beginRemoveRows model events, so a Repeater { model: Toplevels.model } patches one delegate in / out per change instead of rebuilding the whole list (which is what happens when model: is bound to a QList<...> value property — every change re-evaluates the binding and resets every delegate).
Roles:
- toplevel — the ForeignToplevel* for the row.
Usage from QML:
Repeater {
model: Toplevels.model
delegate: Rectangle {
required property var toplevel
Text { text: toplevel.title }
}
}