Hide install more plugins hint when the system does not support it

pull/953/head
Michael Zanetti 2023-01-17 20:11:43 +01:00
parent c703a0a985
commit 1b7d1e1a0e
1 changed files with 4 additions and 3 deletions

View File

@ -157,7 +157,7 @@ Page {
right: parent.right
bottom: parent.bottom
}
bottomMargin: height
bottomMargin: packagesFilterModel.count > 0 ? height : 0
model: ThingClassesProxy {
id: thingClassesProxy
@ -190,14 +190,15 @@ Page {
EmptyViewPlaceholder {
anchors.centerIn: parent
width: parent.width - Style.margins * 2
opacity: thingClassesProxy.count == 0 || listView.contentY >= listView.contentHeight + listView.originY ? 1 : 0
opacity: packagesFilterModel.count > 0 &&
(thingClassesProxy.count == 0 || listView.contentY >= listView.contentHeight + listView.originY)
? 1 : 0
Behavior on opacity { NumberAnimation { duration: Style.shortAnimationDuration } }
visible: opacity > 0
title: qsTr("Looking for something else?")
text: qsTr("Try to install more plugins.")
imageSource: "/ui/images/save.svg"
buttonText: qsTr("Install plugins")
buttonVisible: packagesFilterModel.count > 0
onButtonClicked: {
pageStack.push(Qt.resolvedUrl("/ui/system/PackageListPage.qml"), {filter: "nymea-plugin-"})
}