[vlc-devel] [PATCH 02/28] qml: bring back playlist toolbar label

Fatih Uzunoglu fuzun54 at outlook.com
Tue Jul 21 19:28:32 CEST 2020


---
 .../gui/qt/playlist/qml/PlaylistListView.qml  | 39 +++++++++++++++++++
 1 file changed, 39 insertions(+)

diff --git a/modules/gui/qt/playlist/qml/PlaylistListView.qml b/modules/gui/qt/playlist/qml/PlaylistListView.qml
index 67b59404eb..481f09bf90 100644
--- a/modules/gui/qt/playlist/qml/PlaylistListView.qml
+++ b/modules/gui/qt/playlist/qml/PlaylistListView.qml
@@ -19,6 +19,7 @@ import QtQuick 2.11
 import QtQuick.Controls 2.4
 import QtQuick.Layouts 1.3
 import QtQml.Models 2.2
+import QtGraphicalEffects 1.0
 
 import org.videolan.vlc 0.1
 
@@ -440,6 +441,44 @@ Widgets.NavigableFocusScope {
             }
         }
 
+        Item {
+            Layout.fillWidth: true
+            Layout.alignment: Qt.AlignHCenter
+            height: VLCStyle.heightBar_normal
+            visible: !(infoText.text === "")
+
+            RectangularGlow {
+                anchors.top: parent.top
+                anchors.bottom: parent.bottom
+                anchors.horizontalCenter: parent.horizontalCenter
+
+                width: infoText.width + VLCStyle.dp(18)
+                height: infoText.height + VLCStyle.dp(12)
+
+                glowRadius: 2
+                cornerRadius: 10
+                spread: 0.1
+                color: VLCStyle.colors.glowColorBanner
+            }
+
+            Label {
+                id: infoText
+                anchors.top: parent.top
+                anchors.bottom: parent.bottom
+                anchors.centerIn: parent
+                horizontalAlignment: Text.AlignHCenter
+
+                text: (view.mode === "select")
+                        ? i18n.qtr("Select tracks (%1)").arg(plmodel.selectedCount)
+                    : (view.mode === "move")
+                        ? i18n.qtr("Move tracks (%1)").arg(plmodel.selectedCount)
+                    : ""
+                font.pixelSize: VLCStyle.fontSize_large
+                color: VLCStyle.colors.text
+                elide: Text.ElideRight
+            }
+        }
+
         PlaylistToolbar {
             Layout.fillWidth: true
 
-- 
2.25.1



More information about the vlc-devel mailing list