mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-17 03:18:07 +00:00
fix file preview display #LINQT-2098
This commit is contained in:
parent
b3b40d6f99
commit
d741e79e2e
1 changed files with 21 additions and 11 deletions
|
|
@ -67,20 +67,30 @@ Item {
|
|||
sourceSize.height: mainItem.height
|
||||
fillMode: Image.PreserveAspectFit
|
||||
}
|
||||
Rectangle {
|
||||
Image {
|
||||
anchors.fill: parent
|
||||
color: DefaultStyle.main1_200
|
||||
opacity: 0.5
|
||||
Image {
|
||||
z: image.z + 1
|
||||
visible: image.status == Image.Error || image.status == Image.Null || !UtilsCpp.fileExists(mainItem.filePath)
|
||||
source: AppIcons.fileImage
|
||||
sourceSize.width: mainItem.width
|
||||
sourceSize.height: mainItem.height
|
||||
fillMode: Image.PreserveAspectFit
|
||||
}
|
||||
Item {
|
||||
id: loadingImageItem
|
||||
anchors.fill: parent
|
||||
visible: mainItem.isImage && image.status === Image.Loading
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
z: parent.z + 1
|
||||
visible: image.status == Image.Error || image.status == Image.Null || !UtilsCpp.fileExists(mainItem.filePath)
|
||||
source: AppIcons.fileImage
|
||||
sourceSize.width: mainItem.width
|
||||
sourceSize.height: mainItem.height
|
||||
fillMode: Image.PreserveAspectFit
|
||||
color: DefaultStyle.main1_200
|
||||
opacity: 0.2
|
||||
}
|
||||
BusyIndicator {
|
||||
anchors.centerIn: parent
|
||||
width: Utils.getSizeWithScreenRatio(20)
|
||||
}
|
||||
}
|
||||
|
||||
Image {
|
||||
id: image
|
||||
visible: mainItem.isImage && status !== Image.Loading
|
||||
|
|
@ -343,4 +353,4 @@ Item {
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue