feat: async control center

This commit is contained in:
2 * r + 2 * t 2026-03-20 01:02:44 +11:00
parent 94387e7770
commit 96ed5895d8
14 changed files with 31 additions and 0 deletions

View file

@ -42,6 +42,7 @@ Item {
Layout.fillWidth: true
Layout.columnSpan: 2
asynchronous: true
active: root.floating
visible: active

View file

@ -43,6 +43,7 @@ Item {
Loader {
Layout.topMargin: Appearance.spacing.large
asynchronous: true
active: !root.session.floating
visible: active

View file

@ -129,6 +129,7 @@ ClippingRectangle {
id: loader
anchors.fill: parent
asynchronous: true
clip: false
active: false

View file

@ -124,6 +124,7 @@ Item {
Layout.fillHeight: true
Layout.bottomMargin: -Appearance.padding.large * 2
asynchronous: true
active: {
const isActive = root.session.activeIndex === 3;
const isAdjacent = Math.abs(root.session.activeIndex - 3) === 1;

View file

@ -128,6 +128,7 @@ CollapsibleSection {
}
Loader {
asynchronous: true
active: isCurrent
sourceComponent: MaterialIcon {

View file

@ -28,6 +28,7 @@ CollapsibleSection {
Loader {
Layout.fillWidth: true
Layout.preferredHeight: item ? Math.min(item.contentHeight, 300) : 0
asynchronous: true
active: sansFontSection.expanded
sourceComponent: StyledListView {
@ -81,6 +82,7 @@ CollapsibleSection {
}
Loader {
asynchronous: true
active: isCurrent
sourceComponent: MaterialIcon {
@ -107,6 +109,7 @@ CollapsibleSection {
Loader {
Layout.fillWidth: true
Layout.preferredHeight: item ? Math.min(item.contentHeight, 300) : 0
asynchronous: true
active: monoFontSection.expanded
sourceComponent: StyledListView {
@ -160,6 +163,7 @@ CollapsibleSection {
}
Loader {
asynchronous: true
active: isCurrent
sourceComponent: MaterialIcon {
@ -187,6 +191,7 @@ CollapsibleSection {
id: materialFontLoader
Layout.fillWidth: true
Layout.preferredHeight: item ? Math.min(item.contentHeight, 300) : 0
asynchronous: true
active: materialFontSection.expanded
sourceComponent: StyledListView {
@ -240,6 +245,7 @@ CollapsibleSection {
}
Loader {
asynchronous: true
active: isCurrent
sourceComponent: MaterialIcon {

View file

@ -36,6 +36,7 @@ Item {
id: headerLoader
Layout.fillWidth: true
asynchronous: true
sourceComponent: root.headerComponent
visible: root.headerComponent !== null
}
@ -44,6 +45,7 @@ Item {
id: topContentLoader
Layout.fillWidth: true
asynchronous: true
sourceComponent: root.topContent
visible: root.topContent !== null
}
@ -55,6 +57,7 @@ Item {
required property Component modelData
Layout.fillWidth: true
asynchronous: true
sourceComponent: modelData
}
}
@ -63,6 +66,7 @@ Item {
id: bottomContentLoader
Layout.fillWidth: true
asynchronous: true
sourceComponent: root.bottomContent
visible: root.bottomContent !== null
}

View file

@ -32,6 +32,7 @@ ColumnLayout {
id: headerLoader
Layout.fillWidth: true
asynchronous: true
sourceComponent: root.headerComponent
visible: root.headerComponent !== null && root.showHeader
}
@ -50,6 +51,7 @@ ColumnLayout {
}
Loader {
asynchronous: true
sourceComponent: root.titleSuffix
visible: root.titleSuffix !== null
}

View file

@ -49,6 +49,7 @@ RowLayout {
anchors.leftMargin: Appearance.padding.large
anchors.rightMargin: Appearance.padding.large + Appearance.padding.normal / 2
asynchronous: true
sourceComponent: root.leftContent
Component.onCompleted: {
@ -90,6 +91,7 @@ RowLayout {
anchors.fill: parent
anchors.margins: Appearance.padding.large * 2
asynchronous: true
sourceComponent: root.rightContent
Component.onCompleted: {

View file

@ -53,6 +53,7 @@ Item {
anchors.fill: parent
asynchronous: true
opacity: 1
scale: 1
transformOrigin: Item.Center
@ -86,6 +87,7 @@ Item {
id: overlayLoader
anchors.fill: parent
asynchronous: true
z: 1000
sourceComponent: root.overlayComponent
active: root.overlayComponent !== null

View file

@ -80,6 +80,7 @@ Item {
anchors.leftMargin: Appearance.padding.large
anchors.rightMargin: Appearance.padding.large
asynchronous: true
sourceComponent: dashboardContentComponent
}
}

View file

@ -342,6 +342,7 @@ Item {
spacing: Appearance.spacing.normal
IconImage {
asynchronous: true
Layout.alignment: Qt.AlignVCenter
implicitSize: 32
source: {
@ -360,6 +361,7 @@ Item {
Layout.alignment: Qt.AlignVCenter
readonly property bool isHidden: modelData ? Strings.testRegexList(Config.launcher.hiddenApps, modelData.id) : false
readonly property bool isFav: modelData ? Strings.testRegexList(Config.launcher.favouriteApps, modelData.id) : false
asynchronous: true
active: isHidden || isFav
sourceComponent: isHidden ? hiddenIcon : (isFav ? favouriteIcon : null)
@ -414,6 +416,7 @@ Item {
anchors.fill: parent
asynchronous: true
opacity: 1
scale: 1
transformOrigin: Item.Center
@ -536,6 +539,8 @@ Item {
IconImage {
id: appIconImage
asynchronous: true
Layout.alignment: Qt.AlignHCenter
implicitSize: Appearance.font.size.extraLarge * 3 * 2
source: {

View file

@ -120,6 +120,7 @@ Item {
Loader {
Layout.fillWidth: true
asynchronous: true
sourceComponent: Component {
VpnList {
session: root.session
@ -138,6 +139,7 @@ Item {
Loader {
Layout.fillWidth: true
asynchronous: true
sourceComponent: Component {
EthernetList {
session: root.session
@ -156,6 +158,7 @@ Item {
Loader {
Layout.fillWidth: true
asynchronous: true
sourceComponent: Component {
WirelessList {
session: root.session

View file

@ -140,6 +140,7 @@ Item {
anchors.leftMargin: Appearance.padding.large
anchors.rightMargin: Appearance.padding.large
asynchronous: true
sourceComponent: taskbarContentComponent
}
}