This commit is contained in:
Zacharias-Brohn
2025-12-03 15:33:29 +01:00
parent 8967e3a1f5
commit 5318d3897b
4 changed files with 115 additions and 132 deletions
+18 -2
View File
@@ -1,3 +1,5 @@
pragma ComponentBehavior: Bound
import QtQuick
import qs.Modules
@@ -8,14 +10,28 @@ Repeater {
property int lastWidth
model: gifsList
Item {
x: index === 0 ? 0 : gifRepeater.itemAt(index - 1).x + gifRepeater.itemAt(index - 1).width
id: gifItem
required property int index
required property string modelData
function xPos(): void {
let xPos = 0;
const item = gifRepeater.itemAt(index - 1);
if ( item ) xPos += item.x + item.width;
return xPos;
}
Component.onCompleted: x = xPos()
x: 0
y: Screen.height - height
width: gif.width
height: gif.height
AnimatedImage {
id: gif
source: modelData
source: gifItem.modelData
fillMode: Image.PreserveAspectFit
}