Use let kconfig register the config class

This commit is contained in:
Tobias Fella
2024-07-20 23:11:04 +02:00
parent 8ae7141851
commit d43aa169c3
33 changed files with 218 additions and 231 deletions

View File

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