Adapt compositing effect

This commit is contained in:
reionwong 2021-06-16 13:52:47 +08:00
parent ec96594261
commit df7622b0c9

View file

@ -41,9 +41,9 @@ Item {
Rectangle { Rectangle {
id: _background id: _background
anchors.fill: parent anchors.fill: parent
radius: windowRadius radius: windowHelper.compositing ? windowRadius : 0
color: FishUI.Theme.darkMode ? "#333333" : "#F2F2F2" color: FishUI.Theme.darkMode ? "#333333" : "#F2F2F2"
opacity: FishUI.Theme.darkMode ? 0.5 : 0.4 opacity: windowHelper.compositing ? FishUI.Theme.darkMode ? 0.5 : 0.4 : 1
border.width: 0 border.width: 0
Behavior on color { Behavior on color {
@ -54,6 +54,10 @@ Item {
} }
} }
FishUI.WindowHelper {
id: windowHelper
}
FishUI.WindowShadow { FishUI.WindowShadow {
view: mainWindow view: mainWindow
geometry: Qt.rect(root.x, root.y, root.width, root.height) geometry: Qt.rect(root.x, root.y, root.width, root.height)