mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-22 04:21:44 +00:00
parent
663fac9fa7
commit
22ee49c551
@ -132,7 +132,7 @@ QtObject:
|
|||||||
|
|
||||||
proc setEditModeOnAndScrollToLastMessage*(self: View, pubkey: string) {.slot.} =
|
proc setEditModeOnAndScrollToLastMessage*(self: View, pubkey: string) {.slot.} =
|
||||||
let lastMessage = self.model.getLastItemFrom(pubKey)
|
let lastMessage = self.model.getLastItemFrom(pubKey)
|
||||||
if lastMessage != nil and lastMessage.id != "" and lastMessage.contentType != ContentType.Image:
|
if lastMessage != nil and lastMessage.id != "":
|
||||||
self.model.setEditModeOn(lastMessage.id)
|
self.model.setEditModeOn(lastMessage.id)
|
||||||
self.jumpToMessage(lastMessage.id)
|
self.jumpToMessage(lastMessage.id)
|
||||||
|
|
||||||
|
@ -318,31 +318,32 @@ Control {
|
|||||||
spacing: 9
|
spacing: 9
|
||||||
Repeater {
|
Repeater {
|
||||||
model: root.messageDetails.albumCount
|
model: root.messageDetails.albumCount
|
||||||
Loader {
|
|
||||||
|
delegate: Loader {
|
||||||
active: true
|
active: true
|
||||||
property bool imageLoaded: index < root.messageDetails.album.length
|
readonly property bool imageLoaded: index < root.messageDetails.album.length
|
||||||
property string imagePath: imageLoaded ? root.messageDetails.album[index] : ""
|
readonly property string imagePath: imageLoaded ? root.messageDetails.album[index] : ""
|
||||||
sourceComponent: imageLoaded ? imageComponent : imagePlaceholderComponent
|
sourceComponent: imageLoaded ? imageComponent : imagePlaceholderComponent
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
Component {
|
Component {
|
||||||
id: imageComponent
|
id: imageComponent
|
||||||
StatusImageMessage {
|
StatusImageMessage {
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
imageWidth: Math.min(parent.width / root.messageDetails.albumCount - 9 * (root.messageDetails.albumCount - 1), 144)
|
imageWidth: Math.min(messageLayout.width / root.messageDetails.albumCount - 9 * (root.messageDetails.albumCount - 1), 144)
|
||||||
source: root.messageDetails.album[index]
|
source: imagePath
|
||||||
onClicked: root.imageClicked(image, mouse, imageSource)
|
onClicked: root.imageClicked(image, mouse, imageSource)
|
||||||
shapeType: root.messageDetails.amISender ? StatusImageMessage.ShapeType.RIGHT_ROUNDED : StatusImageMessage.ShapeType.LEFT_ROUNDED
|
shapeType: root.messageDetails.amISender ? StatusImageMessage.ShapeType.RIGHT_ROUNDED : StatusImageMessage.ShapeType.LEFT_ROUNDED
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Component {
|
Component {
|
||||||
id: imagePlaceholderComponent
|
id: imagePlaceholderComponent
|
||||||
LoadingComponent {
|
LoadingComponent {
|
||||||
radius: 4
|
radius: 4
|
||||||
height: 194
|
height: 194
|
||||||
width: 144
|
width: 144
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
2
vendor/status-go
vendored
2
vendor/status-go
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 96532f97c460f849ed8b1ed5d2507593e3ca5c1c
|
Subproject commit 2950d37e430844d83d9897084b51a028d56e8052
|
Loading…
x
Reference in New Issue
Block a user