Fix timeline layout for non text messages

Change the target of the hover component and delegate layout to timeline container so it applies to all delegates not just text messages.

BUG: 457689
This commit is contained in:
James Graham
2022-08-22 17:38:50 +00:00
parent 89090690b4
commit 63af4cae77

View File

@@ -58,7 +58,7 @@ QQC2.ItemDelegate {
// updates the global hover component to point to this delegate, and update its position
function updateHoverComponent() {
if (hoverComponent) {
hoverComponent.delegate = messageDelegate
hoverComponent.delegate = timelineContainer
hoverComponent.bubble = bubble
hoverComponent.updateFunction = updateHoverComponent;
hoverComponent.event = model
@@ -71,7 +71,7 @@ QQC2.ItemDelegate {
State {
name: "alignLeft"
AnchorChanges {
target: messageDelegate
target: timelineContainer
anchors.horizontalCenter: undefined
anchors.left: parent ? parent.left : undefined
}
@@ -79,7 +79,7 @@ QQC2.ItemDelegate {
State {
name: "alignCenter"
AnchorChanges {
target: messageDelegate
target: timelineContainer
anchors.horizontalCenter: parent ? parent.horizontalCenter : undefined
anchors.left: undefined
}