a lot of tweaks to make changing slides work

This commit is contained in:
Chris Cochrun 2023-01-20 13:38:40 -06:00
parent a024a0b27d
commit f535bc1500
5 changed files with 75 additions and 52 deletions

View file

@ -368,14 +368,22 @@ ColumnLayout {
]
}
Connections {
target: ServiceItemModel
onDataChanged: {
if (active)
serviceItemList.positionViewAtIndex(index, ListView.Contain);
}
}
Component.onCompleted: {
totalServiceItems = serviceItemList.count;
/* totalServiceItems = serviceItemList.count; */
console.log("THE TOTAL SERVICE ITEMS: " + totalServiceItems);
}
function removeItem(index) {
ServiceItemModel.removeItem(index);
totalServiceItems--;
/* totalServiceItems--; */
}
function addItem(index, name, type,
@ -385,7 +393,7 @@ ColumnLayout {
ServiceItemModel.insertItem(index, name,
type, background,
backgroundType, newtext);
totalServiceItems++;
/* totalServiceItems++; */
}
function appendItem(name, type, background, backgroundType, text, itemID) {
@ -402,7 +410,7 @@ ColumnLayout {
ServiceItemModel.addItem(name, type, background,
backgroundType, lyrics);
totalServiceItems++;
/* totalServiceItems++; */
}
}