[vlc-devel] [PATCH 28/49] qml: revert list items to have solid background instead of a glowing frame
Pierre Lamot
pierre at videolabs.io
Fri Oct 11 15:17:52 CEST 2019
---
.../qt/qml/mediacenter/MusicAlbumsDisplay.qml | 2 --
.../qt/qml/mediacenter/MusicGenresDisplay.qml | 2 --
modules/gui/qt/qml/utils/ListItem.qml | 27 +++++++++----------
3 files changed, 13 insertions(+), 18 deletions(-)
diff --git a/modules/gui/qt/qml/mediacenter/MusicAlbumsDisplay.qml b/modules/gui/qt/qml/mediacenter/MusicAlbumsDisplay.qml
index 99aaeccc19..43fac861e9 100644
--- a/modules/gui/qt/qml/mediacenter/MusicAlbumsDisplay.qml
+++ b/modules/gui/qt/qml/mediacenter/MusicAlbumsDisplay.qml
@@ -60,8 +60,6 @@ Utils.NavigableFocusScope {
width: root.width
height: VLCStyle.icon_normal + VLCStyle.margin_small
- color: VLCStyle.colors.getBgColor(element.DelegateModel.inSelected, this.hovered, this.activeFocus)
-
cover: Image {
id: cover_obj
fillMode: Image.PreserveAspectFit
diff --git a/modules/gui/qt/qml/mediacenter/MusicGenresDisplay.qml b/modules/gui/qt/qml/mediacenter/MusicGenresDisplay.qml
index 8a1fc52528..7569fa3f08 100644
--- a/modules/gui/qt/qml/mediacenter/MusicGenresDisplay.qml
+++ b/modules/gui/qt/qml/mediacenter/MusicGenresDisplay.qml
@@ -48,8 +48,6 @@ Utils.NavigableFocusScope {
width: root.width
height: VLCStyle.icon_normal + VLCStyle.margin_small
- color: VLCStyle.colors.getBgColor(element.DelegateModel.inSelected, this.hovered, this.activeFocus)
-
cover: Utils.MultiCoverPreview {
albums: MLAlbumModel {
ml: medialib
diff --git a/modules/gui/qt/qml/utils/ListItem.qml b/modules/gui/qt/qml/utils/ListItem.qml
index b4332c0bb2..3f9fe61804 100644
--- a/modules/gui/qt/qml/utils/ListItem.qml
+++ b/modules/gui/qt/qml/utils/ListItem.qml
@@ -39,7 +39,7 @@ NavigableFocusScope {
property alias line2: line2_text.text
property alias imageText: cover_text.text
- property alias color: glow.color
+ property alias color: linerect.color
property bool showContextButton: false
Component {
@@ -50,6 +50,8 @@ NavigableFocusScope {
focus: true
+ font.underline: activeFocus
+
highlightColor: VLCStyle.colors.getBgColor(
root.isSelected, root.hovered,
root.activeFocus)
@@ -69,6 +71,8 @@ NavigableFocusScope {
focus: true
+ font.underline: activeFocus
+
highlightColor: VLCStyle.colors.getBgColor(
root.isSelected, root.hovered,
root.activeFocus)
@@ -81,7 +85,9 @@ NavigableFocusScope {
Rectangle {
id: linerect
anchors.fill: parent
- color: "transparent"
+ color: VLCStyle.colors.getBgColor(
+ root.isSelected, root.hovered,
+ root.activeFocus)
MouseArea {
id: mouse
@@ -97,22 +103,13 @@ NavigableFocusScope {
onDoubleClicked: {
root.itemDoubleClicked(mouse.buttons, mouse.modifiers);
}
- RectangularGlow {
- id: glow
- anchors.fill: innerRect
- spread: 0.1
- glowRadius: VLCStyle.margin_xxsmall
- color: VLCStyle.colors.getBgColor(
- root.isSelected, root.hovered,
- root.activeFocus)
- }
- Rectangle {
+
+
+ Item {
id: innerRect
- radius: height / 10
anchors.fill: parent
anchors.margins: VLCStyle.margin_xxsmall
anchors.verticalCenter: parent.verticalCenter
- color: VLCStyle.colors.bg
RowLayout {
anchors.fill: parent
@@ -201,6 +198,8 @@ NavigableFocusScope {
visible: root.showContextButton
focus: actionButtons.length == toolButtons.focusIndex
+ font.underline: activeFocus
+
highlightColor: VLCStyle.colors.getBgColor(
root.isSelected, root.hovered,
root.activeFocus)
--
2.20.1
More information about the vlc-devel
mailing list