fix ListViewWithLabelsType
This commit is contained in:
parent
0f98fc955f
commit
26ba520022
1 changed files with 3 additions and 3 deletions
|
|
@ -17,7 +17,7 @@ ListView {
|
|||
|
||||
property bool dividerVisible: false
|
||||
|
||||
currentIndex: 0
|
||||
property int selectedIndex: 0
|
||||
|
||||
width: rootWidth
|
||||
height: menuContent.contentItem.height
|
||||
|
|
@ -45,7 +45,7 @@ ListView {
|
|||
rightImageSource: imageSource
|
||||
|
||||
clickedFunction: function() {
|
||||
menuContent.currentIndex = index
|
||||
menuContent.selectedIndex = index
|
||||
menuContent.selectedText = name
|
||||
if (menuContent.clickedFunction && typeof menuContent.clickedFunction === "function") {
|
||||
menuContent.clickedFunction()
|
||||
|
|
@ -62,7 +62,7 @@ ListView {
|
|||
}
|
||||
|
||||
Component.onCompleted: {
|
||||
if (menuContent.currentIndex === index) {
|
||||
if (menuContent.selectedIndex === index) {
|
||||
menuContent.selectedText = name
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue