on xenial help sign in
revert to using BorderImage for the window glow
80acb04Lukáš Tinkl
qml/Stages/DecoratedWindow.qml+8−5
@@ -17,7 +17,6 @@
17 */
17 */
18
18
19import QtQuick 2.4
19import QtQuick 2.4
20−import QtGraphicalEffects 1.0
21import Ubuntu.Components 1.2
20import Ubuntu.Components 1.2
22import Unity.Application 0.1
21import Unity.Application 0.1
23
22
@@ -31,6 +30,7 @@ FocusScope {
31
30
32 property bool decorationShown: true
31 property bool decorationShown: true
33 property bool highlightShown: false
32 property bool highlightShown: false
33+ property real shadowOpacity: 1
34
34
35 signal close()
35 signal close()
36 signal maximize()
36 signal maximize()
@@ -52,10 +52,13 @@ FocusScope {
52 visible: highlightShown
52 visible: highlightShown
53 }
53 }
54
54
55− RectangularGlow { // drop shadow around the window
55+ BorderImage {
56− anchors.fill: parent
56+ anchors {
57− color: "#333333"
57+ fill: root
58− glowRadius: active ? units.dp(6) : units.dp(4)
58+ margins: active ? -units.gu(2) : -units.gu(1.5)
59+ }
60+ source: "graphics/dropshadow2gu.sci"
61+ opacity: root.shadowOpacity * .3
59 }
62 }
60
63
61 WindowDecoration {
64 WindowDecoration {