diff options
Diffstat (limited to 'components/package/contents/ui/Settings.qml')
-rw-r--r-- | components/package/contents/ui/Settings.qml | 62 |
1 files changed, 34 insertions, 28 deletions
diff --git a/components/package/contents/ui/Settings.qml b/components/package/contents/ui/Settings.qml index 164512ea..f6a03945 100644 --- a/components/package/contents/ui/Settings.qml +++ b/components/package/contents/ui/Settings.qml | |||
@@ -68,49 +68,55 @@ Rectangle { | |||
68 | SplitView { | 68 | SplitView { |
69 | anchors.fill: parent | 69 | anchors.fill: parent |
70 | 70 | ||
71 | ListView { | 71 | ScrollView { |
72 | id: accountsList | 72 | id: accountsList |
73 | 73 | ||
74 | width: Unit.size * 55 | 74 | width: Unit.size * 55 |
75 | Layout.maximumWidth: Unit.size * 150 | 75 | Layout.maximumWidth: Unit.size * 150 |
76 | Layout.minimumWidth: Unit.size * 30 | 76 | Layout.minimumWidth: Unit.size * 30 |
77 | 77 | ||
78 | model: accountsController.accounts | 78 | ListView { |
79 | id: listView | ||
79 | 80 | ||
80 | delegate: PlasmaComponents.ListItem { | 81 | model: accountsController.accounts |
81 | width: accountsList.width | ||
82 | 82 | ||
83 | height: Unit.size * 10 | 83 | currentIndex: -1 |
84 | 84 | ||
85 | enabled: true | 85 | delegate: PlasmaComponents.ListItem { |
86 | checked: accountsList.currentIndex == index | ||
87 | 86 | ||
88 | KubeFramework.AccountFactory { | 87 | width: listView.width |
89 | id: accountFactory | 88 | height: Unit.size * 10 |
90 | accountId: modelData | 89 | |
91 | } | 90 | enabled: true |
91 | checked: listView.currentIndex == index | ||
92 | 92 | ||
93 | MouseArea { | 93 | KubeFramework.AccountFactory { |
94 | anchors { | 94 | id: accountFactory |
95 | fill: parent | 95 | accountId: modelData |
96 | } | 96 | } |
97 | 97 | ||
98 | onClicked: { | 98 | MouseArea { |
99 | accountDetails.source = accountFactory.uiPath | 99 | anchors { |
100 | fill: parent | ||
101 | } | ||
102 | |||
103 | onClicked: { | ||
104 | accountDetails.source = accountFactory.uiPath | ||
100 | 105 | ||
101 | accountsList.currentIndex = model.index | 106 | listView.currentIndex = model.index |
107 | } | ||
102 | } | 108 | } |
103 | } | ||
104 | 109 | ||
105 | RowLayout { | 110 | RowLayout { |
106 | anchors.fill: parent | 111 | anchors.fill: parent |
107 | 112 | ||
108 | PlasmaCore.IconItem { | 113 | PlasmaCore.IconItem { |
109 | source: accountFactory.icon | 114 | source: accountFactory.icon |
110 | } | 115 | } |
111 | 116 | ||
112 | Label { | 117 | Label { |
113 | text: accountFactory.name | 118 | text: accountFactory.name |
119 | } | ||
114 | } | 120 | } |
115 | } | 121 | } |
116 | } | 122 | } |