mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-26 14:23:09 +00:00
Refactor layers and switch z-index between home and applications
This commit is contained in:
parent
396d88c228
commit
3699efaed5
1 changed files with 13 additions and 11 deletions
|
|
@ -22,6 +22,7 @@ import org.kde.plasma.core 2.0 as PlasmaCore
|
||||||
import "WindowManagement.js" as WindowManagement
|
import "WindowManagement.js" as WindowManagement
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
property bool showHome: true
|
||||||
readonly property alias layers: layers
|
readonly property alias layers: layers
|
||||||
readonly property real topBarHeight: units.iconSizes.small
|
readonly property real topBarHeight: units.iconSizes.small
|
||||||
|
|
||||||
|
|
@ -39,22 +40,23 @@ Rectangle {
|
||||||
onSurfaceDestroyed: WindowManagement.surfaceDestroyed(surface)
|
onSurfaceDestroyed: WindowManagement.surfaceDestroyed(surface)
|
||||||
}
|
}
|
||||||
|
|
||||||
Item {
|
QtObject {
|
||||||
readonly property alias desktop: desktopLayer
|
readonly property alias desktop: desktopLayer
|
||||||
readonly property alias windows: windowsLayer
|
readonly property alias windows: windowsLayer
|
||||||
|
|
||||||
id: layers
|
id: layers
|
||||||
|
}
|
||||||
|
|
||||||
|
Item {
|
||||||
|
id: desktopLayer
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
z: showHome ? 2 : 1
|
||||||
|
}
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: desktopLayer
|
id: windowsLayer
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
}
|
anchors.topMargin: topBarHeight
|
||||||
|
z: showHome ? 1 : 2
|
||||||
Item {
|
|
||||||
id: windowsLayer
|
|
||||||
anchors.fill: parent
|
|
||||||
anchors.topMargin: topBarHeight
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue