Fix ReplyComponent warnings
This commit is contained in:
@@ -62,11 +62,11 @@ Item {
|
|||||||
id: loader
|
id: loader
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.maximumHeight: loader.item && (reply.type == MessageEventModel.Image || reply.type == MessageEventModel.Sticker) ? loader.item.height : -1
|
Layout.maximumHeight: loader.item && (model.reply.type == MessageEventModel.Image || model.reply.type == MessageEventModel.Sticker) ? loader.item.height : -1
|
||||||
Layout.columnSpan: 2
|
Layout.columnSpan: 2
|
||||||
|
|
||||||
sourceComponent: {
|
sourceComponent: {
|
||||||
switch (reply.type) {
|
switch (model.reply.type) {
|
||||||
case MessageEventModel.Image:
|
case MessageEventModel.Image:
|
||||||
case MessageEventModel.Sticker:
|
case MessageEventModel.Sticker:
|
||||||
return imageComponent;
|
return imageComponent;
|
||||||
@@ -96,7 +96,7 @@ Item {
|
|||||||
Component {
|
Component {
|
||||||
id: textComponent
|
id: textComponent
|
||||||
RichLabel {
|
RichLabel {
|
||||||
textMessage: reply.display
|
textMessage: model.reply.display
|
||||||
textFormat: Text.RichText
|
textFormat: Text.RichText
|
||||||
|
|
||||||
HoverHandler {
|
HoverHandler {
|
||||||
@@ -141,8 +141,8 @@ Item {
|
|||||||
id: mimeComponent
|
id: mimeComponent
|
||||||
MimeComponent {
|
MimeComponent {
|
||||||
mimeIconSource: replyComponent.mediaInfo.mimeIcon
|
mimeIconSource: replyComponent.mediaInfo.mimeIcon
|
||||||
label: reply.display
|
label: model.reply.display
|
||||||
subLabel: reply.type === MessageEventModel.File ? Controller.formatByteSize(replyComponent.mediaInfo.size) : Controller.formatDuration(replyComponent.mediaInfo.duration)
|
subLabel: model.reply.type === MessageEventModel.File ? Controller.formatByteSize(replyComponent.mediaInfo.size) : Controller.formatDuration(replyComponent.mediaInfo.duration)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Component {
|
Component {
|
||||||
|
|||||||
Reference in New Issue
Block a user