diff --git a/ui/app/AppLayouts/Chat/ChatColumn/Message.qml b/ui/app/AppLayouts/Chat/ChatColumn/Message.qml index 6e9da7bbf4..9a38addab4 100644 --- a/ui/app/AppLayouts/Chat/ChatColumn/Message.qml +++ b/ui/app/AppLayouts/Chat/ChatColumn/Message.qml @@ -56,12 +56,13 @@ Item { } } - function clickMessage(isProfileClick) { + function clickMessage(isProfileClick, isSticker = false) { if (!isProfileClick) { SelectedMessage.set(messageId, fromAuthor); } profileClick(userName, fromAuthor, identicon); messageContextMenu.isProfile = !!isProfileClick + messageContextMenu.isSticker = isSticker messageContextMenu.popup() // Position the center of the menu where the mouse is messageContextMenu.x = messageContextMenu.x - messageContextMenu.width / 2 diff --git a/ui/app/AppLayouts/Chat/ChatColumn/MessageComponents/MessageMouseArea.qml b/ui/app/AppLayouts/Chat/ChatColumn/MessageComponents/MessageMouseArea.qml index 619b4f0381..6db5e5f0df 100644 --- a/ui/app/AppLayouts/Chat/ChatColumn/MessageComponents/MessageMouseArea.qml +++ b/ui/app/AppLayouts/Chat/ChatColumn/MessageComponents/MessageMouseArea.qml @@ -8,7 +8,7 @@ MouseArea { z: 50 onClicked: { if(mouse.button & Qt.RightButton) { - clickMessage() + clickMessage(false, isSticker) return; } } diff --git a/ui/app/AppLayouts/Chat/ChatColumn/MessageComponents/Sticker.qml b/ui/app/AppLayouts/Chat/ChatColumn/MessageComponents/Sticker.qml index 20a6f0ecd9..ed9c3073dc 100644 --- a/ui/app/AppLayouts/Chat/ChatColumn/MessageComponents/Sticker.qml +++ b/ui/app/AppLayouts/Chat/ChatColumn/MessageComponents/Sticker.qml @@ -6,5 +6,7 @@ Image { visible: contentType === Constants.stickerType width: 140 height: this.visible ? 140 : 0 + sourceSize.width: width + sourceSize.height: height source: this.visible ? ("https://ipfs.infura.io/ipfs/" + sticker) : "" } diff --git a/ui/app/AppLayouts/Chat/components/MessageContextMenu.qml b/ui/app/AppLayouts/Chat/components/MessageContextMenu.qml index 20f6c66b3a..84f4905a9b 100644 --- a/ui/app/AppLayouts/Chat/components/MessageContextMenu.qml +++ b/ui/app/AppLayouts/Chat/components/MessageContextMenu.qml @@ -8,6 +8,7 @@ import "./" PopupMenu { property bool isProfile: false + property bool isSticker: false id: messageContextMenu width: messageContextMenu.isProfile ? profileHeader.width : emojiContainer.width @@ -109,5 +110,6 @@ PopupMenu { icon.source: "../../../img/messageActive.svg" icon.width: 16 icon.height: 16 + enabled: !isSticker } } diff --git a/ui/app/AppLayouts/Chat/components/StickerList.qml b/ui/app/AppLayouts/Chat/components/StickerList.qml index 583915505f..58d93fe667 100644 --- a/ui/app/AppLayouts/Chat/components/StickerList.qml +++ b/ui/app/AppLayouts/Chat/components/StickerList.qml @@ -25,6 +25,8 @@ GridView { Image { width: 80 height: 80 + sourceSize.width: width + sourceSize.height: height fillMode: Image.PreserveAspectFit source: "https://ipfs.infura.io/ipfs/" + url MouseArea { diff --git a/ui/shared/RoundedImage.qml b/ui/shared/RoundedImage.qml index 9b1b050647..453a009fc8 100644 --- a/ui/shared/RoundedImage.qml +++ b/ui/shared/RoundedImage.qml @@ -28,7 +28,8 @@ Rectangle { smooth: false anchors.fill: parent source: "https://ipfs.infura.io/ipfs/" + thumbnail - + sourceSize.width: width + sourceSize.height: height MouseArea { cursorShape: Qt.PointingHandCursor anchors.fill: parent