From: Matthieu Gallien Date: Mon, 12 Aug 2024 08:18:32 +0000 (+0200) Subject: remove most usages of transparent background: fix visual regressions X-Git-Tag: archive/raspbian/3.16.7-1_deb13u1+rpi1~1^2~12^2~6^2~66^2~3 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=16c1cd1b19cc20e9e394ee5526b908b7ce8f6cfc;p=nextcloud-desktop.git remove most usages of transparent background: fix visual regressions with transparent backgrounds, most of teh time the result is hard to read that is mostly unintended and unless there is some blur added, the UI becomes unusable Close https://github.com/nextcloud/desktop/issues/6992 Signed-off-by: Matthieu Gallien --- diff --git a/src/gui/PredefinedStatusButton.qml b/src/gui/PredefinedStatusButton.qml index 8c5ab851c..f51716a72 100644 --- a/src/gui/PredefinedStatusButton.qml +++ b/src/gui/PredefinedStatusButton.qml @@ -35,7 +35,7 @@ AbstractButton { property string clearAtText: "" background: Rectangle { - color: root.hovered || root.checked ? palette.highlight : "transparent" + color: root.hovered || root.checked ? palette.highlight : palette.base radius: Style.slightlyRoundedButtonRadius } diff --git a/src/gui/filedetails/FileTag.qml b/src/gui/filedetails/FileTag.qml index 2a5207586..f9a340f2c 100644 --- a/src/gui/filedetails/FileTag.qml +++ b/src/gui/filedetails/FileTag.qml @@ -24,7 +24,7 @@ EnforcedPlainTextLabel { border.color: palette.dark border.width: Style.normalBorderWidth radius: Style.veryRoundedButtonRadius - color: "transparent" + color: palette.base } color: palette.midlight diff --git a/src/gui/filedetails/NCTabButton.qml b/src/gui/filedetails/NCTabButton.qml index 8c6c7426f..f1ac3c303 100644 --- a/src/gui/filedetails/NCTabButton.qml +++ b/src/gui/filedetails/NCTabButton.qml @@ -83,7 +83,7 @@ TabButton { implicitWidth: textWidth + Style.standardSpacing * 2 implicitHeight: 2 - color: tabButton.checked ? tabButton.accentColor : tabButton.hovered ? palette.highlight : "transparent" + color: tabButton.checked ? tabButton.accentColor : tabButton.hovered ? palette.highlight : palette.base } } } diff --git a/src/gui/tray/ActivityItemActions.qml b/src/gui/tray/ActivityItemActions.qml index a44fc9880..c233d218e 100644 --- a/src/gui/tray/ActivityItemActions.qml +++ b/src/gui/tray/ActivityItemActions.qml @@ -13,7 +13,7 @@ Repeater { property variant linksContextMenu: [] property bool displayActions: false - property color moreActionsButtonColor: "transparent" + property color moreActionsButtonColor: palette.base property int maxActionButtons: 0 diff --git a/src/gui/tray/CallNotificationDialog.qml b/src/gui/tray/CallNotificationDialog.qml index 77a9fef20..46b2d225f 100644 --- a/src/gui/tray/CallNotificationDialog.qml +++ b/src/gui/tray/CallNotificationDialog.qml @@ -24,7 +24,7 @@ import Qt5Compat.GraphicalEffects ApplicationWindow { id: root - color: "transparent" + color: palette.base flags: Qt.Dialog | Qt.FramelessWindowHint | Qt.WindowStaysOnTopHint readonly property int windowSpacing: 10 diff --git a/src/gui/tray/EditFileLocallyLoadingDialog.qml b/src/gui/tray/EditFileLocallyLoadingDialog.qml index c453279f2..c6d9af6a1 100644 --- a/src/gui/tray/EditFileLocallyLoadingDialog.qml +++ b/src/gui/tray/EditFileLocallyLoadingDialog.qml @@ -9,7 +9,7 @@ ApplicationWindow { id: root flags: Qt.Dialog | Qt.FramelessWindowHint | Qt.WindowStaysOnTopHint - color: "transparent" + color: palette.base width: 320 height: contentLayout.implicitHeight diff --git a/src/gui/tray/HeaderButton.qml b/src/gui/tray/HeaderButton.qml index 3d16aa350..cb217db1c 100644 --- a/src/gui/tray/HeaderButton.qml +++ b/src/gui/tray/HeaderButton.qml @@ -38,7 +38,7 @@ Button { Layout.preferredHeight: Style.trayWindowHeaderHeight background: Rectangle { - color: root.hovered || root.visualFocus ? Style.currentUserHeaderTextColor : "transparent" + color: root.hovered || root.visualFocus ? Style.currentUserHeaderTextColor : palette.base opacity: 0.2 } diff --git a/src/gui/tray/TrayFolderListItem.qml b/src/gui/tray/TrayFolderListItem.qml index b83160bc6..8031d7fcb 100644 --- a/src/gui/tray/TrayFolderListItem.qml +++ b/src/gui/tray/TrayFolderListItem.qml @@ -36,7 +36,7 @@ MenuItem { Rectangle { anchors.fill: parent anchors.margins: Style.normalBorderWidth - color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : "transparent" + color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : palette.base } } diff --git a/src/gui/tray/TrayFoldersMenuButton.qml b/src/gui/tray/TrayFoldersMenuButton.qml index 00c878dcc..b4d466bda 100644 --- a/src/gui/tray/TrayFoldersMenuButton.qml +++ b/src/gui/tray/TrayFoldersMenuButton.qml @@ -100,7 +100,7 @@ HeaderButton { width: Style.folderStateIndicatorSize + Style.trayFolderStatusIndicatorSizeOffset height: width anchors.centerIn: parent - color: root.hovered ? Style.currentUserHeaderTextColor : "transparent" + color: root.hovered ? Style.currentUserHeaderTextColor : palette.base opacity: Style.trayFolderStatusIndicatorMouseHoverOpacityFactor radius: width * Style.trayFolderStatusIndicatorRadiusFactor z: -1 diff --git a/src/gui/tray/UnifiedSearchResultListItem.qml b/src/gui/tray/UnifiedSearchResultListItem.qml index f8a025572..acfee2da5 100644 --- a/src/gui/tray/UnifiedSearchResultListItem.qml +++ b/src/gui/tray/UnifiedSearchResultListItem.qml @@ -46,7 +46,7 @@ MouseArea { Rectangle { id: unifiedSearchResultHoverBackground anchors.fill: parent - color: (parent.containsMouse ? palette.highlight : "transparent") + color: parent.containsMouse ? palette.highlight : palette.base } Loader { diff --git a/src/gui/tray/UserLine.qml b/src/gui/tray/UserLine.qml index a546cf557..28ec40c99 100644 --- a/src/gui/tray/UserLine.qml +++ b/src/gui/tray/UserLine.qml @@ -149,7 +149,7 @@ AbstractButton { background: Rectangle { anchors.fill: parent anchors.margins: 1 - color: userMoreButton.hovered || userMoreButton.visualFocus ? palette.highlight : "transparent" + color: userMoreButton.hovered || userMoreButton.visualFocus ? palette.highlight : palette.base } contentItem: Image { @@ -188,7 +188,7 @@ AbstractButton { Rectangle { anchors.fill: parent anchors.margins: 1 - color: parent.parent.hovered ? palette.highlight : "transparent" + color: parent.parent.hovered ? palette.highlight : palette.base } } @@ -222,7 +222,7 @@ AbstractButton { Rectangle { anchors.fill: parent anchors.margins: 1 - color: parent.parent.hovered ? palette.highlight : "transparent" + color: parent.parent.hovered ? palette.highlight : palette.base } } diff --git a/src/gui/tray/Window.qml b/src/gui/tray/Window.qml index 386c8990b..5e5b12702 100644 --- a/src/gui/tray/Window.qml +++ b/src/gui/tray/Window.qml @@ -345,7 +345,7 @@ ApplicationWindow { Rectangle { anchors.fill: parent anchors.margins: 1 - color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : "transparent" + color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : palette.base } } @@ -397,7 +397,7 @@ ApplicationWindow { Rectangle { anchors.fill: parent anchors.margins: 1 - color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : "transparent" + color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : palette.base } } @@ -419,7 +419,7 @@ ApplicationWindow { Rectangle { anchors.fill: parent anchors.margins: 1 - color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : "transparent" + color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : palette.base } } @@ -441,7 +441,7 @@ ApplicationWindow { Rectangle { anchors.fill: parent anchors.margins: 1 - color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : "transparent" + color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : palette.base } } @@ -452,7 +452,7 @@ ApplicationWindow { } background: Rectangle { - color: parent.hovered || parent.visualFocus ? Style.currentUserHeaderTextColor : "transparent" + color: parent.hovered || parent.visualFocus ? Style.currentUserHeaderTextColor : palette.base opacity: 0.2 } @@ -496,7 +496,7 @@ ApplicationWindow { height: width anchors.bottom: currentAccountAvatar.bottom anchors.right: currentAccountAvatar.right - color: currentAccountButton.hovered ? Style.currentUserHeaderTextColor : "transparent" + color: currentAccountButton.hovered ? Style.currentUserHeaderTextColor : palette.base opacity: Style.trayFolderStatusIndicatorMouseHoverOpacityFactor radius: width * Style.trayFolderStatusIndicatorRadiusFactor } @@ -699,7 +699,7 @@ ApplicationWindow { Rectangle { anchors.fill: parent anchors.margins: 1 - color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : "transparent" + color: parent.parent.hovered || parent.parent.visualFocus ? palette.highlight : palette.base } }