Commit 3567fd34 authored by Lasath Fernando's avatar Lasath Fernando

[User Switcher] Fix sessions not updating

It seems that the Connections object wasn't actually connecting to
the signals, preventing the sessionsModel from reloading. This works
around it by creating the binding manually in Javascript.

BUG: 386254
Differential Revision: https://phabricator.kde.org/D9353
parent c73ff7a5
......@@ -132,15 +132,6 @@ Item {
id: sessionsModel
}
Connections {
target: plasmoid
onExpandedChanged: {
if (plasmoid.expanded) {
sessionsModel.reload()
}
}
}
PlasmaComponents.Highlight {
id: delegateHighlight
visible: false
......@@ -249,5 +240,13 @@ Item {
onClicked: pmEngine.performOperation("requestShutDown")
}
}
Component.onCompleted: {
plasmoid.expandedChanged.connect(function (expanded) {
if (expanded) {
sessionsModel.reload();
}
});
}
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment