2019-03-26 18:19:55 +11:00
|
|
|
import QtQuick 2.7
|
|
|
|
import QtQuick.Controls 2.2
|
|
|
|
import QtQuick.Layouts 1.4
|
2019-03-26 20:52:43 +11:00
|
|
|
import "../base" as Base
|
2019-03-26 18:19:55 +11:00
|
|
|
|
|
|
|
ListView {
|
2019-04-21 07:36:21 +10:00
|
|
|
property var forUserId: null
|
2019-03-26 18:19:55 +11:00
|
|
|
|
2019-04-13 22:59:10 +10:00
|
|
|
property int childrenHeight: 36
|
2019-03-26 18:19:55 +11:00
|
|
|
property int contentHeight: 0
|
|
|
|
|
|
|
|
onCountChanged: {
|
2019-04-13 22:59:10 +10:00
|
|
|
contentHeight = childrenHeight * model.count +
|
|
|
|
spacing * (model.count - 1)
|
2019-03-26 18:19:55 +11:00
|
|
|
}
|
|
|
|
|
|
|
|
id: "roomList"
|
|
|
|
spacing: 8
|
2019-04-21 07:36:21 +10:00
|
|
|
model: Backend.models.rooms.get(forUserId)
|
2019-03-26 18:19:55 +11:00
|
|
|
delegate: RoomDelegate {}
|
|
|
|
}
|