Use required properties to fix some more qmllint warnings

Change-Id: I4489bd55e8777b7bf591c41a21e2b6dfdf9ea996
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
This commit is contained in:
Ulf Hermann 2019-08-19 11:12:20 +02:00
parent be7e33e5dd
commit 87e7203532
2 changed files with 6 additions and 2 deletions

View File

@ -75,6 +75,7 @@ Rectangle {
id: launcherList
clip: true
delegate: SimpleLauncherDelegate{
required property url url
onClicked: root.showExample(url)
}
model: ListModel {id:myModel}

View File

@ -51,6 +51,9 @@ import QtQuick 2.12
Rectangle {
id: container
required property string name
required property string description
property Item exampleItem
width: ListView.view.width
height: button.implicitHeight + 22
@ -110,7 +113,7 @@ Rectangle {
anchors.leftMargin: 10
anchors.right: parent.right
anchors.rightMargin: 10
text: name
text: container.name
color: "black"
font.pixelSize: 22
wrapMode: Text.WrapAtWordBoundaryOrAnywhere
@ -122,7 +125,7 @@ Rectangle {
id: buttonLabel2
anchors.left: parent.left
anchors.leftMargin: 10
text: description
text: container.description
wrapMode: Text.WrapAtWordBoundaryOrAnywhere
color: "#666"
font.pixelSize: 12