Show special text when room has no events yet

e.g. if invited to a room but there's no history provided by
another account.

Also add a signal for the ListModel.count property.
This commit is contained in:
miruka
2019-04-22 11:31:06 -04:00
parent d47bf34522
commit 4607f53b7a
4 changed files with 34 additions and 14 deletions

View File

@@ -1,6 +1,7 @@
import QtQuick 2.7
import QtQuick.Controls 2.2
import QtQuick.Layouts 1.4
import "../base" as Base
Rectangle {
property int space: 8
@@ -34,4 +35,17 @@ Rectangle {
}
}
}
Base.HLabel {
visible: messageListView.model.count < 1
anchors.centerIn: parent
text: qsTr("Nothing to see here yet…")
padding: 10
topPadding: padding / 3
bottomPadding: topPadding
background: Rectangle {
color: "lightgray"
radius: 5
}
}
}