-
Bug
-
Resolution: Done
-
P1: Critical
-
5.10.0
-
None
Consider the following example
Column
{
property bool started: false
Text
{
text: started?qsTr("Stop"):qsTr("Start")
}
Text
{
id: stateText
states: [
State {
name: "stopped"
when: !started
PropertyChanges {
target: stateText
text: qsTr("Start")
}
},
State {
name: "started"
when: started
PropertyChanges {
target: stateText
text: qsTr("Stop")
}
}
]
}
}
When I call QQmlApplicationEngine::retranslate, only the first text is correctly translated.
It seems that once the PropertyChange has been applied at least once, the text is not translated anymore.
| For Gerrit Dashboard: QTBUG-66541 | ||||||
|---|---|---|---|---|---|---|
| # | Subject | Branch | Project | Status | CR | V |
| 221008,7 | Fix QQmlEngine::retranslate() with PropertyChanges | 5.11 | qt/qtdeclarative | Status: MERGED | +2 | 0 |