controlcenter: correcting containers (network details)

This commit is contained in:
ATMDA 2025-11-16 23:01:51 -05:00
parent 57bb5cede1
commit 9f8f8ac731
3 changed files with 37 additions and 43 deletions

View file

@ -16,6 +16,8 @@ Item {
required property Session session required property Session session
readonly property var device: session.ethernet.active readonly property var device: session.ethernet.active
anchors.fill: parent
Component.onCompleted: { Component.onCompleted: {
if (device && device.interface) { if (device && device.interface) {
Nmcli.getEthernetDeviceDetails(device.interface, () => {}); Nmcli.getEthernetDeviceDetails(device.interface, () => {});
@ -30,25 +32,12 @@ Item {
} }
} }
StyledFlickable { ColumnLayout {
id: flickable id: layout
anchors.fill: parent anchors.left: parent.left
anchors.right: parent.right
flickableDirection: Flickable.VerticalFlick spacing: Appearance.spacing.normal
clip: true
contentHeight: layout.height
StyledScrollBar.vertical: StyledScrollBar {
flickable: flickable
}
ColumnLayout {
id: layout
anchors.left: parent.left
anchors.right: parent.right
spacing: Appearance.spacing.normal
ConnectionHeader { ConnectionHeader {
icon: "cable" icon: "cable"
@ -112,8 +101,6 @@ Item {
deviceDetails: Nmcli.ethernetDeviceDetails deviceDetails: Nmcli.ethernetDeviceDetails
} }
} }
}
} }
} }

View file

@ -463,6 +463,7 @@ Item {
opacity: 1 opacity: 1
scale: 1 scale: 1
transformOrigin: Item.Center transformOrigin: Item.Center
clip: false
asynchronous: true asynchronous: true
sourceComponent: pane ? (ethernetPane ? ethernetDetails : wirelessDetails) : settings sourceComponent: pane ? (ethernetPane ? ethernetDetails : wirelessDetails) : settings
@ -533,16 +534,34 @@ Item {
Component { Component {
id: ethernetDetails id: ethernetDetails
EthernetDetails { StyledFlickable {
session: root.session flickableDirection: Flickable.VerticalFlick
contentHeight: ethernetDetailsInner.height
EthernetDetails {
id: ethernetDetailsInner
anchors.left: parent.left
anchors.right: parent.right
session: root.session
}
} }
} }
Component { Component {
id: wirelessDetails id: wirelessDetails
WirelessDetails { StyledFlickable {
session: root.session flickableDirection: Flickable.VerticalFlick
contentHeight: wirelessDetailsInner.height
WirelessDetails {
id: wirelessDetailsInner
anchors.left: parent.left
anchors.right: parent.right
session: root.session
}
} }
} }
} }

View file

@ -17,6 +17,8 @@ Item {
required property Session session required property Session session
readonly property var network: session.network.active readonly property var network: session.network.active
anchors.fill: parent
Component.onCompleted: { Component.onCompleted: {
updateDeviceDetails(); updateDeviceDetails();
checkSavedProfile(); checkSavedProfile();
@ -98,25 +100,12 @@ Item {
} }
} }
StyledFlickable { ColumnLayout {
id: flickable id: layout
anchors.fill: parent anchors.left: parent.left
anchors.right: parent.right
flickableDirection: Flickable.VerticalFlick spacing: Appearance.spacing.normal
clip: true
contentHeight: layout.height
StyledScrollBar.vertical: StyledScrollBar {
flickable: flickable
}
ColumnLayout {
id: layout
anchors.left: parent.left
anchors.right: parent.right
spacing: Appearance.spacing.normal
ConnectionHeader { ConnectionHeader {
icon: root.network?.isSecure ? "lock" : "wifi" icon: root.network?.isSecure ? "lock" : "wifi"
@ -214,7 +203,6 @@ Item {
deviceDetails: Nmcli.wirelessDeviceDetails deviceDetails: Nmcli.wirelessDeviceDetails
} }
} }
}
} }
function handleConnect(): void { function handleConnect(): void {