[vlc-devel] [PATCH 16/16] qml: show tooltip when playlist item text is clipped

Fatih Uzunoglu fuzun54 at outlook.com
Wed Jul 29 23:04:39 CEST 2020


---
 modules/gui/qt/playlist/qml/PLItem.qml | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/modules/gui/qt/playlist/qml/PLItem.qml b/modules/gui/qt/playlist/qml/PLItem.qml
index 7a3b786170..bdc5ef4445 100644
--- a/modules/gui/qt/playlist/qml/PLItem.qml
+++ b/modules/gui/qt/playlist/qml/PLItem.qml
@@ -216,6 +216,15 @@ Rectangle {
                 Layout.fillWidth: true
                 Layout.leftMargin: VLCStyle.margin_large
 
+                ToolTip {
+                    id: textInfoExtendTooltip
+                    text: textArtistHider.visible ? (textInfoHider.visible ? textInfo.text + '\n' + textArtist.text : textArtist.text) : textInfo.text
+                    visible: (root.hovered || model.selected) && (textArtistHider.visible || textInfoHider.visible)
+                    opacity: 0.75
+                    delay: 1000
+                    timeout: 2000
+                }
+
                 Widgets.ListLabel {
                     id: textInfo
 
-- 
2.25.1



More information about the vlc-devel mailing list