launcher: anim wallpaperitem creation
Also fix cachingimage
This commit is contained in:
parent
07e6f1b417
commit
0505ba8f92
2 changed files with 13 additions and 3 deletions
|
|
@ -10,10 +10,15 @@ StyledRect {
|
||||||
|
|
||||||
required property Wallpapers.Wallpaper modelData
|
required property Wallpapers.Wallpaper modelData
|
||||||
|
|
||||||
scale: PathView.isCurrentItem ? 1 : PathView.onPath ? 0.8 : 0
|
scale: 0.5
|
||||||
opacity: PathView.onPath ? 1 : 0
|
opacity: 0
|
||||||
z: PathView.z
|
z: PathView.z
|
||||||
|
|
||||||
|
Component.onCompleted: {
|
||||||
|
scale = Qt.binding(() => PathView.isCurrentItem ? 1 : PathView.onPath ? 0.8 : 0);
|
||||||
|
opacity = Qt.binding(() => PathView.onPath ? 1 : 0);
|
||||||
|
}
|
||||||
|
|
||||||
implicitWidth: image.width + Appearance.padding.larger * 2
|
implicitWidth: image.width + Appearance.padding.larger * 2
|
||||||
implicitHeight: image.height + label.height + Appearance.spacing.small / 2 + Appearance.padding.large + Appearance.padding.normal
|
implicitHeight: image.height + label.height + Appearance.spacing.small / 2 + Appearance.padding.large + Appearance.padding.normal
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,12 @@ Image {
|
||||||
required property string path
|
required property string path
|
||||||
property string thumbnail: path
|
property string thumbnail: path
|
||||||
|
|
||||||
source: `file://${thumbnail}`
|
source: {
|
||||||
|
if (thumbnail)
|
||||||
|
return `file://${thumbnail}`;
|
||||||
|
shaProc.running = true;
|
||||||
|
return "";
|
||||||
|
}
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
fillMode: Image.PreserveAspectCrop
|
fillMode: Image.PreserveAspectCrop
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue