~ubuntu-clock-dev/ubuntu-clock-app/trunk

« back to all changes in this revision

Viewing changes to app/alarm/EditAlarmPage.qml

Made the default alarm label translatable and updated the pot file. Fixes: https://bugs.launchpad.net/bugs/1365012.

Approved by PS Jenkins bot, David Planella, Ubuntu Phone Apps Jenkins Bot.

Show diffs side-by-side

added added

removed removed

Lines of Context:
173
173
    Alarm {
174
174
        id: _alarm
175
175
 
 
176
        Component.onCompleted: {
 
177
            /*
 
178
             Sets the alarm name manually to "Alarm" to ensure that it is
 
179
             translatable instead of using the default name set by the SDK
 
180
             Alarms API.
 
181
            */
 
182
            if (isNewAlarm) {
 
183
                _alarm.message = i18n.tr("Alarm")
 
184
            }
 
185
        }
 
186
 
176
187
        onErrorChanged: {
177
188
            if (error !== Alarm.NoError) {
178
189
                Utils.log(debugMode, "Error saving alarm, code: " + error)