[vlc-commits] [Git][videolan/vlc][master] qml: fix bad color cast in TeletextWidget

Steve Lhomme (@robUx4) gitlab at videolan.org
Fri Aug 16 11:34:50 UTC 2024



Steve Lhomme pushed to branch master at VideoLAN / VLC


Commits:
49fadff8 by Pierre Lamot at 2024-08-16T11:14:00+00:00
qml: fix bad color cast in TeletextWidget

- - - - -


1 changed file:

- modules/gui/qt/player/qml/controlbarcontrols/TeletextWidget.qml


Changes:

=====================================
modules/gui/qt/player/qml/controlbarcontrols/TeletextWidget.qml
=====================================
@@ -40,7 +40,7 @@ T.Pane {
     Keys.priority: Keys.AfterItem
     Keys.onPressed: (event) => Navigation.defaultKeyAction(event)
 
-    function _teletextButtonColor(item, base)
+    function _teletextButtonColor(item : Item, base : color) : color
     {
         if (!item.enabled)
             return base.alpha(0.2)
@@ -196,7 +196,7 @@ T.Pane {
 
                 description: qsTr("Red key")
 
-                color: root._teletextButtonColor(this, "red")
+                color: root._teletextButtonColor(this, Qt.color("red"))
 
                 Navigation.parentItem: root
                 Navigation.leftItem: indexKeyBtn
@@ -215,7 +215,7 @@ T.Pane {
 
                 description: qsTr("Green key")
 
-                color: root._teletextButtonColor(this, "green")
+                color: root._teletextButtonColor(this, Qt.color("green"))
 
                 Navigation.parentItem: root
                 Navigation.leftItem: redKeyBtn
@@ -234,7 +234,7 @@ T.Pane {
 
                 description: qsTr("Yellow key")
 
-                color: root._teletextButtonColor(this, "yellow")
+                color: root._teletextButtonColor(this, Qt.color("yellow"))
 
                 Navigation.parentItem: root
                 Navigation.leftItem: greenKeyBtn
@@ -253,7 +253,7 @@ T.Pane {
 
                 description: qsTr("Blue key")
 
-                color: root._teletextButtonColor(this, "blue")
+                color: root._teletextButtonColor(this, Qt.color("blue"))
 
                 Navigation.parentItem: root
                 Navigation.leftItem: yellowKeyBtn



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/49fadff8a2dc68a2112ce0e84e6a8be9b74fe55e

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/49fadff8a2dc68a2112ce0e84e6a8be9b74fe55e
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list