Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import QtQuick 2.13
- ListView {
- id: _listView
- property string text // Пользовательское значение
- anchors.fill: parent
- model: test_model
- delegate: Internal {}
- ListModel {
- id: test_model
- ListElement {name: "first"}
- ListElement {name: "second"}
- }
- }
- // Internal.qml
- import QtQuick 2.13
- import QtQuick.Controls 2.13
- Rectangle {
- height: 28
- width: parent.width
- Label {
- property string text: _listView.text != "" ? _listView.text : "default"
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement