From 4065aa6a2ebff257bc8dcc2a729602919d249f28 Mon Sep 17 00:00:00 2001 From: James Graham Date: Sat, 11 Nov 2023 17:29:15 +0000 Subject: [PATCH] Fix linkpreview tooltip Fix linkpreview tooltip so that the correct text is always shown. BUG: 467106 --- src/qml/LinkPreviewDelegate.qml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/qml/LinkPreviewDelegate.qml b/src/qml/LinkPreviewDelegate.qml index cf7ea6c68..69c61c08f 100644 --- a/src/qml/LinkPreviewDelegate.qml +++ b/src/qml/LinkPreviewDelegate.qml @@ -110,11 +110,15 @@ Loader { anchors.bottom: parent.bottom visible: componentRoot.hovered && (componentRoot.truncated || checked) checkable: true + text: checked ? i18n("Shrink preview") : i18n("Expand preview") icon.name: checked ? "go-up" : "go-down" + display: QQC2.AbstractButton.IconOnly - QQC2.ToolTip.text: checked ? i18n("Shrink preview") : i18n("Expand preview") - QQC2.ToolTip.visible: hovered - QQC2.ToolTip.delay: Kirigami.Units.toolTipDelay + QQC2.ToolTip { + text: maximizeButton.text + visible: hovered + delay: Kirigami.Units.toolTipDelay + } } } }