Pascaldietz (Talk | contribs) (→API properties) |
Pascaldietz (Talk | contribs) (→Example) |
||
| Line 71: | Line 71: | ||
onTriggered: { | onTriggered: { | ||
//do something | //do something | ||
| + | } | ||
| + | |||
| + | Component.onCompleted: { | ||
| + | selectedIndex = 0 | ||
} | } | ||
} | } | ||
Contents |
This is a button which carries a title and shows a flyout when clicked. The flyout can hold any content.
-
-
DropDown {
id: ddown
anchors.centerIn: parent
title: "DropDown"
titleColor: "black"
width: 400
minWidth: 400
maxWidth: 440
model: [ "First choice", "Second choice", "Third choice" ]
payload: [ 1, 2, 3 ]
iconRow: [
Image {
height: parent.height * 0.9
anchors.verticalCenter: parent.verticalCenter
fillMode: Image.PreserveAspectFit
source: "image://themedimage/images/camera/camera_lens_sm_up"
}
]
onTriggered: {
//do something
}
Component.onCompleted: {
selectedIndex = 0
}
}