1
0
Fork 0
mirror of https://git.jami.net/savoirfairelinux/jami-client-qt.git synced 2025-08-26 09:43:56 +02:00

messagelistview: ui fixes

1. Add handler for DataTransferMessageDelegate MouseArea
2. Fix TextMessageDelegate crash caused by Loader
3. Fix SBSMessageBase padding when resizing
4. Use JamiListView for MessageListView
5. Fix ScrollToBottomButton DropShadow
6. Fix Typing indicator binding loop

Change-Id: I59b97f3850fceb30f72c64f6cae54889fe4a18db
This commit is contained in:
Ming Rui Zhang 2021-10-04 15:53:00 -04:00 committed by Sébastien Blin
parent 45b86d56d9
commit 71b98aed56
7 changed files with 15 additions and 9 deletions

View file

@ -185,10 +185,15 @@ Loader {
JamiTheme.messageInTxtColor
MouseArea {
anchors.fill: parent
propagateComposedEvents: true
cursorShape: canOpen ?
Qt.PointingHandCursor :
Qt.ArrowCursor
onClicked: function (mouse) {
dataTransferItem.hoveredLink = canOpen ?
("file:///" + Body) : ""
if (dataTransferItem.hoveredLink)
Qt.openUrlExternally(dataTransferItem.hoveredLink)
}
}
}
Label {

View file

@ -21,7 +21,7 @@ import QtQuick.Controls
import net.jami.Constants 1.1
Label {
TextEdit {
id: root
property string eText : ""
@ -38,6 +38,9 @@ Label {
verticalAlignment: Text.AlignVCenter
color: JamiTheme.textColor
readOnly: true
selectByMouse: true
TextMetrics {
id: elided

View file

@ -40,6 +40,7 @@ TextField {
wrapMode: Text.Wrap
readOnly: false
selectByMouse: true
mouseSelectionMode: TextInput.SelectCharacters
selectionColor: JamiTheme.placeholderTextColor
font.pointSize: JamiTheme.materialLineEditPointSize

View file

@ -61,7 +61,7 @@ Control {
anchors.centerIn: parent
width: parent.width
width: parent.width - hPadding * 2
spacing: 2

View file

@ -67,8 +67,6 @@ SBSMessageBase {
},
Loader {
id: extraContent
width: sourceComponent.width
height: sourceComponent.height
anchors.right: isOutgoing ? parent.right : undefined
property real minSize: 192
property real maxSize: 320

View file

@ -28,7 +28,7 @@ import net.jami.Constants 1.1
import "../../commoncomponents"
ListView {
JamiListView {
id: root
function getDistanceToBottom() {
@ -178,12 +178,9 @@ ListView {
displayMarginEnd: 4096
maximumFlickVelocity: 2048
verticalLayoutDirection: ListView.BottomToTop
clip: true
boundsBehavior: Flickable.StopAtBounds
currentIndex: -1
ScrollBar.vertical: ScrollBar {}
model: MessagesAdapter.messageListModel
delegate: DelegateChooser {

View file

@ -120,10 +120,12 @@ Control {
layer {
enabled: true
effect: DropShadow {
z: -1
horizontalOffset: 3.0
verticalOffset: 3.0
radius: 8.0
color: JamiTheme.shadowColor
transparentBorder: true
}
}
}