fix(StatusEmojiAndColorComboBox): proper setting initial selection
This commit is contained in:
parent
f1d2646fec
commit
720971c9db
|
@ -49,11 +49,24 @@ StatusComboBox {
|
|||
*/
|
||||
property int delegateHeight: 44
|
||||
|
||||
ModelChangeTracker {
|
||||
id: modelTracker
|
||||
|
||||
model: root.model
|
||||
}
|
||||
|
||||
QtObject {
|
||||
id: d
|
||||
|
||||
readonly property string emoji: ModelUtils.get(root.model, currentIndex, "emoji") ?? ""
|
||||
readonly property string color: ModelUtils.get(root.model, currentIndex, "color") ?? ""
|
||||
readonly property string emoji: {
|
||||
modelTracker.revision
|
||||
return ModelUtils.get(root.model, currentIndex, "emoji") ?? ""
|
||||
}
|
||||
|
||||
readonly property string color: {
|
||||
modelTracker.revision
|
||||
return ModelUtils.get(root.model, currentIndex, "color") ?? ""
|
||||
}
|
||||
}
|
||||
|
||||
control.textRole: "name"
|
||||
|
|
Loading…
Reference in New Issue