fix: Added `SystemMessagePinnedMessage` contentType
This commit is contained in:
parent
6997e05586
commit
98d8a70572
|
@ -17,6 +17,8 @@ type
|
|||
ContactRequest = 11
|
||||
DiscordMessage = 12
|
||||
ContactIdentityVerification = 13
|
||||
# Local only
|
||||
SystemMessagePinnedMessage = 14
|
||||
|
||||
type
|
||||
StatusType* {.pure.} = enum
|
||||
|
|
|
@ -21,7 +21,8 @@ Control {
|
|||
Audio = 5,
|
||||
Transaction = 6,
|
||||
Invitation = 7,
|
||||
DiscordMessage = 8
|
||||
DiscordMessage = 8,
|
||||
SystemMessagePinnedMessage = 14
|
||||
}
|
||||
|
||||
property list<Item> quickActions
|
||||
|
@ -186,9 +187,10 @@ Control {
|
|||
id: messageLayout
|
||||
anchors.fill: parent
|
||||
spacing: 2
|
||||
|
||||
Loader {
|
||||
Layout.fillWidth: true
|
||||
active: isAReply
|
||||
active: isAReply && root.messageDetails.contentType !== StatusMessage.ContentType.SystemMessagePinnedMessage
|
||||
visible: active
|
||||
sourceComponent: StatusMessageReply {
|
||||
objectName: "StatusMessage_replyDetails"
|
||||
|
|
|
@ -204,6 +204,8 @@ Loader {
|
|||
return fetchMoreMessagesButtonComponent
|
||||
case Constants.messageContentType.systemMessagePrivateGroupType:
|
||||
return privateGroupHeaderComponent
|
||||
case Constants.messageContentType.systemMessagePinnedMessage:
|
||||
return null
|
||||
case Constants.messageContentType.gapType:
|
||||
return gapComponent
|
||||
case Constants.messageContentType.newMessagesMarker:
|
||||
|
@ -276,6 +278,8 @@ Loader {
|
|||
return StatusMessage.ContentType.Invitation;
|
||||
case Constants.messageContentType.discordMessageType:
|
||||
return StatusMessage.ContentType.DiscordMessage;
|
||||
case Constants.messageContentType.systemMessagePinnedMessage:
|
||||
return StatusMessage.ContentType.SystemMessagePinnedMessage;
|
||||
case Constants.messageContentType.fetchMoreMessagesButton:
|
||||
case Constants.messageContentType.chatIdentifier:
|
||||
case Constants.messageContentType.unknownContentType:
|
||||
|
@ -372,7 +376,6 @@ Loader {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
Component {
|
||||
id: messageComponent
|
||||
|
||||
|
|
|
@ -407,6 +407,7 @@ QtObject {
|
|||
readonly property int gapType: 10
|
||||
readonly property int contactRequestType: 11
|
||||
readonly property int discordMessageType: 12
|
||||
readonly property int systemMessagePinnedMessage: 14
|
||||
}
|
||||
|
||||
readonly property QtObject messageModelRoles: QtObject {
|
||||
|
|
Loading…
Reference in New Issue