Make use of the proposed new KColorScheme API

Make use of new API proposed in frameworks/kcolorscheme!12
This commit is contained in:
James Graham
2024-09-01 14:17:41 +00:00
parent cbc2e65856
commit 05a2f03c18
6 changed files with 7 additions and 41 deletions

View File

@@ -15,10 +15,6 @@ FormCard.FormComboBoxDelegate {
textRole: "display"
valueRole: "display"
model: ColorSchemer.model
Component.onCompleted: currentIndex = ColorSchemer.indexForScheme(NeoChatConfig.colorScheme)
onCurrentValueChanged: {
ColorSchemer.apply(currentIndex);
NeoChatConfig.colorScheme = ColorSchemer.nameForIndex(currentIndex);
NeoChatConfig.save();
}
Component.onCompleted: currentIndex = ColorSchemer.indexForCurrentScheme()
onCurrentValueChanged: ColorSchemer.apply(currentIndex);
}