Changed the showPage() function. This is because the normal function would take you to the next index, but if you would want to skip a index, you need to change the index to a fixed number (or redo the whole index-tab-system)

This commit is contained in:
CommanderRedYT
2021-08-16 17:36:05 +02:00
parent 6955c9cc6f
commit 8507df1bcf

View File

@ -23,11 +23,13 @@ Item {
__currentIndex = lastPages.length-1;
}
function showPage(name)
function showPage(name, index = -1)
{
lastPages.push(name)
pageLoader.setSource(name)
__currentIndex = lastPages.length-1;
if(index === -1)
__currentIndex = lastPages.length-1
else __currentIndex = index
}
TitleBar {