Merge branch 'main' into zshell-img-tools
This commit is contained in:
@@ -20,7 +20,7 @@ Item {
|
||||
required property PersistentProperties visibilities
|
||||
|
||||
implicitHeight: content.implicitHeight
|
||||
implicitWidth: content.implicitWidth || 854 // Hard coded fallback for first open
|
||||
implicitWidth: content.implicitWidth || 854
|
||||
opacity: 1 - offsetScale
|
||||
visible: offsetScale < 1
|
||||
|
||||
|
||||
@@ -9,18 +9,17 @@ Item {
|
||||
id: root
|
||||
|
||||
property int contentHeight
|
||||
property real offsetScale: shouldBeActive ? 0 : 1
|
||||
required property var panels
|
||||
required property ShellScreen screen
|
||||
readonly property bool shouldBeActive: visibilities.dock && Config.dock.enable
|
||||
required property PersistentProperties visibilities
|
||||
|
||||
readonly property bool shouldBeActive: visibilities.dock
|
||||
property real offsetScale: shouldBeActive ? 0 : 1
|
||||
|
||||
visible: offsetScale < 1
|
||||
anchors.bottomMargin: (-implicitHeight - 5) * offsetScale
|
||||
implicitHeight: content.implicitHeight
|
||||
implicitWidth: content.implicitWidth || 400
|
||||
opacity: 1 - offsetScale
|
||||
visible: offsetScale < 1
|
||||
|
||||
Behavior on offsetScale {
|
||||
Anim {
|
||||
@@ -32,10 +31,10 @@ Item {
|
||||
Loader {
|
||||
id: content
|
||||
|
||||
active: root.shouldBeActive || root.visible
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
|
||||
active: root.shouldBeActive || root.visible
|
||||
asynchronous: true
|
||||
|
||||
sourceComponent: Content {
|
||||
panels: root.panels
|
||||
|
||||
@@ -47,6 +47,7 @@ Item {
|
||||
active: Qt.binding(() => root.shouldBeActive || root.visible)
|
||||
anchors.right: parent.right
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
asynchronous: true
|
||||
height: content.contentItem.height
|
||||
opacity: root.expanded ? 0 : 1
|
||||
|
||||
@@ -65,6 +66,7 @@ Item {
|
||||
|
||||
anchors.right: parent.right
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
asynchronous: true
|
||||
opacity: root.expanded ? 1 : 0
|
||||
|
||||
Behavior on opacity {
|
||||
|
||||
@@ -8,7 +8,7 @@ import QtQuick
|
||||
Item {
|
||||
id: root
|
||||
|
||||
readonly property int padding: 6
|
||||
readonly property int padding: Appearance.padding.smaller
|
||||
required property Item panels
|
||||
required property PersistentProperties visibilities
|
||||
|
||||
@@ -54,7 +54,7 @@ Item {
|
||||
anchors.fill: parent
|
||||
anchors.margins: root.padding
|
||||
color: "transparent"
|
||||
radius: Appearance.rounding.smallest / 2
|
||||
radius: Appearance.rounding.normal - root.padding
|
||||
|
||||
CustomListView {
|
||||
id: list
|
||||
@@ -72,7 +72,7 @@ Item {
|
||||
required property NotifServer.Notif modelData
|
||||
readonly property alias nonAnimHeight: notif.nonAnimHeight
|
||||
|
||||
implicitHeight: notif.implicitHeight + (idx === 0 ? 0 : 8)
|
||||
implicitHeight: notif.implicitHeight + (idx === 0 ? 0 : Appearance.spacing.small)
|
||||
implicitWidth: notif.implicitWidth
|
||||
|
||||
ListView.onRemove: removeAnim.start()
|
||||
@@ -151,48 +151,6 @@ Item {
|
||||
property: "y"
|
||||
}
|
||||
}
|
||||
|
||||
ExtraIndicator {
|
||||
anchors.top: parent.top
|
||||
extra: {
|
||||
const count = list.count;
|
||||
if (count === 0)
|
||||
return 0;
|
||||
|
||||
const scrollY = list.contentY;
|
||||
|
||||
let height = 0;
|
||||
for (let i = 0; i < count; i++) {
|
||||
height += (list.itemAtIndex(i)?.nonAnimHeight ?? 0) + 8;
|
||||
|
||||
if (height - 8 >= scrollY)
|
||||
return i;
|
||||
}
|
||||
|
||||
return count;
|
||||
}
|
||||
}
|
||||
|
||||
ExtraIndicator {
|
||||
anchors.bottom: parent.bottom
|
||||
extra: {
|
||||
const count = list.count;
|
||||
if (count === 0)
|
||||
return 0;
|
||||
|
||||
const scrollY = list.contentHeight - (list.contentY + list.height);
|
||||
|
||||
let height = 0;
|
||||
for (let i = count - 1; i >= 0; i--) {
|
||||
height += (list.itemAtIndex(i)?.nonAnimHeight ?? 0) + 8;
|
||||
|
||||
if (height - 8 >= scrollY)
|
||||
return count - i - 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -134,7 +134,7 @@ Item {
|
||||
anchors.right: parent.right
|
||||
anchors.top: searchBar.bottom
|
||||
anchors.topMargin: Appearance.spacing.smaller
|
||||
color: DynamicColors.tPalette.m3surfaceContainerLowest
|
||||
color: DynamicColors.tPalette.m3surfaceContainer
|
||||
radius: Appearance.rounding.normal
|
||||
|
||||
StackView {
|
||||
|
||||
Reference in New Issue
Block a user