linphone-desktop/linphone-app/ui/modules/Linphone/Chat/ChatForwardMessage.qml
Julien Wadel 4532e278ac New chat layout :
- Split content type to be filtered by proxy lists.
- Add a message in notification when receiving a conference invitation.
- Change chat bubbles colors to match mobile application.
- Change date display on messages to remove sections. It allows to be more coherent when sorting messages.
- Change Chat Layout : outgoing messages to right, incoming messages to left.
- Change bubble design to be squared when grouped.
- Group messages on 1 second away from previous (and same sender).
- Add a background color with radius to files in reply messages.
- Make color corners on reply.
- Fix filename to 2 lines in file download icon.
- Add a background color on conference invitations.
- Change conference title from bold to normal on invitations.
- Rework chat message content layout to be used with grids and lists : files are now displayed in grid.
- Remove cyclic dependencies with reply design (which was recursivly linked with ChatContent).
- Fix center layouts that were not bind to the correct one.
- Align pictures to center.
- Fix hidden admin usernames in participant view.
2023-03-03 17:09:25 +01:00

63 lines
1.9 KiB
QML

import QtQuick 2.7
import QtQuick.Layouts 1.3
import Clipboard 1.0
import Common 1.0
import Linphone 1.0
import Common.Styles 1.0
import Linphone.Styles 1.0
import TextToSpeech 1.0
import Utils 1.0
import Units 1.0
import UtilsCpp 1.0
import LinphoneEnums 1.0
import ColorsList 1.0
import 'Message.js' as Logic
// =============================================================================
Item {
id: mainItem
property ChatMessageModel mainChatMessageModel
property int availableWidth : parent.width
property int fitWidth: visible ? headerArea.fitWidth + 7 + ChatForwardMessageStyle.padding * 2 : 0
property int fitHeight: visible ? icon.height + 5 : 0
property font customFont : SettingsModel.textMessageFont
visible: mainChatMessageModel && mainChatMessageModel.isForward
width: availableWidth > fitWidth ? fitWidth : availableWidth
height: fitHeight
ColumnLayout{
anchors.fill: parent
spacing: 5
Row{
id: headerArea
property int fitWidth: icon.width + headerText.implicitWidth
Layout.fillHeight: true
Layout.topMargin: 5
Icon{
id: icon
icon: ChatForwardMessageStyle.header.forwardIcon.icon
iconSize: ChatForwardMessageStyle.header.forwardIcon.iconSize
height: iconSize
overwriteColor: ChatForwardMessageStyle.header.colorModel.color
}
Text{
id: headerText
height: icon.height
verticalAlignment: Qt.AlignVCenter
// Anonymized forward : do not get display name, this is wanted.
//property string forwardInfo: mainChatMessageModel ? mainChatMessageModel.getForwardInfoDisplayName : ''
//: 'Forwarded' : Header on a message that contains a forward.
text: qsTr('Forwarded')// + (forwardInfo ? ' : ' +forwardInfo : '')
font.family: mainItem.customFont.family
font.pointSize: Units.dp * (mainItem.customFont.pointSize + ChatForwardMessageStyle.header.pointSizeOffset)
color: ChatForwardMessageStyle.header.colorModel.color
}
}
}
}