diff options
author | Jan-Simon Moeller <jsmoeller@linuxfoundation.org> | 2018-01-09 22:12:53 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@automotivelinux.org> | 2018-01-09 22:12:53 +0000 |
commit | 997ff3705532f62bd5b8948b2d00ffc1fffe6b7c (patch) | |
tree | 9f25bb4a64713bef08b020d090075c5f06cc7924 /app/HeatDegree.qml | |
parent | d084bc1f764833566f3e8eafc9fc297c3fa9ee08 (diff) | |
parent | 4b7d58e71e8864a90d3b567f21029968d6e8edef (diff) |
Merge "Add basic translation support"
Diffstat (limited to 'app/HeatDegree.qml')
-rw-r--r-- | app/HeatDegree.qml | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/app/HeatDegree.qml b/app/HeatDegree.qml index aa5770a..a9bc83c 100644 --- a/app/HeatDegree.qml +++ b/app/HeatDegree.qml @@ -28,11 +28,11 @@ ListView { property int degree: currentIndex > -1 ? model.get(currentIndex).value : -1 model: ListModel { Component.onCompleted: { - append({value: 15, modelData: 'LO'}) + append({value: 15, modelData: translator.translate(qsTr('LO'), translator.language)}) for (var d = 16; d < 30; d++) { - append({value: d, modelData: d.toFixed(0) + '\u00b0'}) + append({value: d, modelData: translator.translate(qsTr('%1\u00b0'), translator.language).arg(d.toFixed(0))}) } - append({value: 30, modelData: 'HI'}) + append({value: 30, modelData: translator.translate(qsTr('HI'), translator.language)}) } } delegate: Label { @@ -41,7 +41,7 @@ ListView { horizontalAlignment: Label.AlignHCenter verticalAlignment: Label.AlignVCenter text: model.modelData - font.pixelSize: height * 0.8 + font.pixelSize: height * 0.7 color: (ListView.view.enabled && ListView.isCurrentItem) ? '#00ADDC' : 'white' } |