decouple background layer plasma shadows svg

--the multilayered background first layer is not
decoupled and is not the parent layer for all the
rest layer. This way we can really hide it without
influence the rest background layers.
pull/20/head
Michail Vourlakos 5 years ago
parent 0d941d05f2
commit 148e3956b1

@ -242,22 +242,12 @@ BackgroundProperties{
id: shadowsSvgItem id: shadowsSvgItem
width: root.isVertical ? background.thickness + totals.shadowsThickness : totals.visualLength width: root.isVertical ? background.thickness + totals.shadowsThickness : totals.visualLength
height: root.isVertical ? totals.visualLength : background.thickness + totals.shadowsThickness height: root.isVertical ? totals.visualLength : background.thickness + totals.shadowsThickness
enabledBorders: latteView && latteView.effects ? latteView.effects.enabledBorders : PlasmaCore.FrameSvg.NoBorder
imagePath: "widgets/panel-background" imagePath: "widgets/panel-background"
prefix: "shadow" prefix: "shadow"
opacity: hideShadow || !root.useThemePanel || (root.forceTransparentPanel && !root.forcePanelForBusyBackground) ? 0 : 1
visible: (opacity == 0) ? false : true visible: (opacity == 0) ? false : true
opacity: {
if ((root.forceTransparentPanel && !root.forcePanelForBusyBackground)
|| !root.useThemePanel)
return 0;
else
return 1;
}
enabledBorders: latteView && latteView.effects && !hideShadow ? latteView.effects.enabledBorders : PlasmaCore.FrameSvg.NoBorder
//! set true by default in order to avoid crash on startup because imagePath is set to "" //! set true by default in order to avoid crash on startup because imagePath is set to ""
readonly property bool themeHasShadow: themeExtended ? themeExtended.hasShadow : true readonly property bool themeHasShadow: themeExtended ? themeExtended.hasShadow : true
@ -287,6 +277,7 @@ BackgroundProperties{
enabled: !LatteCore.WindowSystem.compositingActive enabled: !LatteCore.WindowSystem.compositingActive
NumberAnimation { duration: 0 } NumberAnimation { duration: 0 }
} }
}
//! Layer 2: Provide visual solidness. Plasma themes by design may provide a panel-background svg that is not //! Layer 2: Provide visual solidness. Plasma themes by design may provide a panel-background svg that is not
//! solid. That means that user can not gain full solidness in such cases. This layer is responsible //! solid. That means that user can not gain full solidness in such cases. This layer is responsible
@ -323,7 +314,7 @@ BackgroundProperties{
anchors.rightMargin: LatteCore.WindowSystem.compositingActive ? shadows.right : 0 anchors.rightMargin: LatteCore.WindowSystem.compositingActive ? shadows.right : 0
anchors.topMargin: LatteCore.WindowSystem.compositingActive ? shadows.top : 0 anchors.topMargin: LatteCore.WindowSystem.compositingActive ? shadows.top : 0
anchors.bottomMargin: LatteCore.WindowSystem.compositingActive ? shadows.bottom : 0 anchors.bottomMargin: LatteCore.WindowSystem.compositingActive ? shadows.bottom : 0
anchors.fill:parent anchors.fill: shadowsSvgItem
opacity: normalizedOpacity opacity: normalizedOpacity
@ -584,7 +575,7 @@ BackgroundProperties{
borderColor: "red" borderColor: "red"
roundness: overlayedBackground.roundness roundness: overlayedBackground.roundness
}*/ }*/
}
//BEGIN states //BEGIN states
//user set Panel Positions //user set Panel Positions

Loading…
Cancel
Save