blob: 8a8545f0fa878da98e0bb8c685fc51b452a795f9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
import QtQuick
import "./state"
import qs.modules.controlcenter
QtObject {
readonly property list<string> panes: PaneRegistry.labels
required property var root
property bool floating: false
property string active: "network"
property int activeIndex: 0
property bool navExpanded: false
readonly property BluetoothState bt: BluetoothState {}
readonly property NetworkState network: NetworkState {}
readonly property EthernetState ethernet: EthernetState {}
readonly property LauncherState launcher: LauncherState {}
readonly property VpnState vpn: VpnState {}
onActiveChanged: activeIndex = Math.max(0, panes.indexOf(active))
onActiveIndexChanged: if (panes[activeIndex])
active = panes[activeIndex]
}
|