on xenial help sign in
don't hide the decoration when the window is not visible
c45daa8Lukáš Tinkl
qml/Stages/DecoratedWindow.qml+4−3
@@ -24,7 +24,7 @@ FocusScope {
24 id: root
24 id: root
25
25
26 width: applicationWindow.width
26 width: applicationWindow.width
27− height: (decoration.visible ? decoration.height : 0) + applicationWindow.height
27+ height: (decorationShown ? decoration.height : 0) + applicationWindow.height
28
28
29 property alias window: applicationWindow
29 property alias window: applicationWindow
30 property alias application: applicationWindow.application
30 property alias application: applicationWindow.application
@@ -32,6 +32,7 @@ FocusScope {
32 property alias title: decoration.title
32 property alias title: decoration.title
33 property alias fullscreen: applicationWindow.fullscreen
33 property alias fullscreen: applicationWindow.fullscreen
34
34
35+ readonly property bool decorationShown: !fullscreen
35 property bool highlightShown: false
36 property bool highlightShown: false
36 property real shadowOpacity: 1
37 property real shadowOpacity: 1
37
38
@@ -76,7 +77,7 @@ FocusScope {
76 height: units.gu(3)
77 height: units.gu(3)
77 width: root.width
78 width: root.width
78 title: window.title
79 title: window.title
79− visible: !root.fullscreen
80+ visible: root.decorationShown
80
81
81 onClose: root.close();
82 onClose: root.close();
82 onMaximize: { root.decorationPressed(); root.maximize(); }
83 onMaximize: { root.decorationPressed(); root.maximize(); }
@@ -90,7 +91,7 @@ FocusScope {
90 anchors.top: parent.top
91 anchors.top: parent.top
91 anchors.topMargin: decoration.height
92 anchors.topMargin: decoration.height
92 anchors.left: parent.left
93 anchors.left: parent.left
93− requestedHeight: root.requestedHeight - (decoration.visible ? decoration.height : 0)
94+ requestedHeight: root.requestedHeight - (root.decorationShown ? decoration.height : 0)
94 interactive: true
95 interactive: true
95 focus: true
96 focus: true
96 }
97 }