Merge lp:~gang65/ubuntu-clock-app/ubuntu-clock-app-disabled-alarm-fix into lp:ubuntu-clock-app

Proposed by Bartosz Kosiorek
Status: Merged
Merged at revision: 399
Proposed branch: lp:~gang65/ubuntu-clock-app/ubuntu-clock-app-disabled-alarm-fix
Merge into: lp:ubuntu-clock-app
Diff against target: 181 lines (+25/-25)
3 files modified
app/alarm/AlarmDelegate.qml (+3/-4)
debian/changelog (+1/-0)
po/com.ubuntu.clock.pot (+21/-21)
To merge this branch: bzr merge lp:~gang65/ubuntu-clock-app/ubuntu-clock-app-disabled-alarm-fix
Reviewer Review Type Date Requested Status
Ubuntu Phone Apps Jenkins Bot continuous-integration Needs Fixing
Nekhelesh Ramananthan Approve
Victor Thompson Needs Fixing
Bartosz Kosiorek Approve
Review via email: mp+274661@code.launchpad.net

Commit message

Disable alarms which have passed due to timezone changes (or phone is turned off) made by the user (LP: #1505522)

Description of the change

Disable alarms which have passed due to timezone changes (or phone is turned off) made by the user (LP: #1505522)

To post a comment you must log in.
Revision history for this message
Bartosz Kosiorek (gang65) wrote :

Already approved by Nekhelesh with MR:
https://code.launchpad.net/~gang65/ubuntu-clock-app/ubuntu-clock-app-alarm-order-fix/+merge/274270

This MR is only to separate changes from others one.

review: Approve
Revision history for this message
Victor Thompson (vthompson) wrote :

1 inline comment.

review: Needs Fixing
Revision history for this message
Bartosz Kosiorek (gang65) wrote :

@Victor Nice catch. Already fixed. Thanks

Revision history for this message
Nekhelesh Ramananthan (nik90) wrote :

Tiny little detail, the comment "It is important to keep the alarm list in order of occurrence (also for disabled alarms)." is not true. That if loop does not affect the alarm list order. Can you remove that statement?

Revision history for this message
Nekhelesh Ramananthan (nik90) :
review: Approve
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :

FAILED: Continuous integration, rev:399
http://91.189.93.70:8080/job/ubuntu-clock-app-ci/854/
Executed test runs:

Click here to trigger a rebuild:
http://91.189.93.70:8080/job/ubuntu-clock-app-ci/854/rebuild

review: Needs Fixing (continuous-integration)
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :

FAILED: Autolanding.
More details in the following jenkins job:
http://91.189.93.70:8080/job/ubuntu-clock-app-autolanding/320/
Executed test runs:

review: Needs Fixing (continuous-integration)
Revision history for this message
Bartosz Kosiorek (gang65) wrote :

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'app/alarm/AlarmDelegate.qml'
--- app/alarm/AlarmDelegate.qml 2015-08-17 18:28:28 +0000
+++ app/alarm/AlarmDelegate.qml 2015-10-19 02:19:20 +0000
@@ -137,11 +137,10 @@
137 alarmData.enabled = checked137 alarmData.enabled = checked
138138
139 /*139 /*
140 Calculate the new alarm time if it is a one-time alarm and has140 Calculate the alarm time if it is a one-time alarm.
141 gone-off and the user is re-enabling the alarm. Repeating141 Repeating alarms do this automatically.
142 alarms do this automatically.
143 */142 */
144 if(checked && type === Alarm.OneTime) {143 if(type === Alarm.OneTime) {
145 alarmData.daysOfWeek = Alarm.AutoDetect144 alarmData.daysOfWeek = Alarm.AutoDetect
146 var now = new Date()145 var now = new Date()
147 if (alarmData.date.getHours()*60+alarmData.date.getMinutes() <= now.getHours()*60+now.getMinutes()) {146 if (alarmData.date.getHours()*60+alarmData.date.getMinutes() <= now.getHours()*60+now.getMinutes()) {
148147
=== modified file 'debian/changelog'
--- debian/changelog 2015-09-17 04:33:11 +0000
+++ debian/changelog 2015-10-19 02:19:20 +0000
@@ -16,6 +16,7 @@
16 * Fix stopwatch issue appering during changing timezone during runtime (LP: #1493358)16 * Fix stopwatch issue appering during changing timezone during runtime (LP: #1493358)
17 * Fix Daylight Saving Time issues (LP: #1437805)17 * Fix Daylight Saving Time issues (LP: #1437805)
18 * Fix time for second location wrong after daylight saving started (LP: #1457523)18 * Fix time for second location wrong after daylight saving started (LP: #1457523)
19 * Disable alarms which have passed due to timezone changes made by the user (LP: #1505522)
1920
20 -- Bartosz Kosiorek <gang65@poczta.onet.pl> Wed, 02 Sep 2015 15:16:29 +020021 -- Bartosz Kosiorek <gang65@poczta.onet.pl> Wed, 02 Sep 2015 15:16:29 +0200
2122
2223
=== modified file 'po/com.ubuntu.clock.pot'
--- po/com.ubuntu.clock.pot 2015-09-10 11:10:13 +0000
+++ po/com.ubuntu.clock.pot 2015-10-19 02:19:20 +0000
@@ -8,7 +8,7 @@
8msgstr ""8msgstr ""
9"Project-Id-Version: \n"9"Project-Id-Version: \n"
10"Report-Msgid-Bugs-To: \n"10"Report-Msgid-Bugs-To: \n"
11"POT-Creation-Date: 2015-09-10 13:06+0200\n"11"POT-Creation-Date: 2015-10-19 04:17+0200\n"
12"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"12"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
13"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"13"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14"Language-Team: LANGUAGE <LL@li.org>\n"14"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -18,7 +18,7 @@
18"Content-Transfer-Encoding: 8bit\n"18"Content-Transfer-Encoding: 8bit\n"
19"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"19"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
2020
21#: ../app/MainPage.qml:47 ../app/alarm/AlarmUtils.qml:5521#: ../app/MainPage.qml:53 ../app/alarm/AlarmUtils.qml:55
22msgid "No active alarms"22msgid "No active alarms"
23msgstr ""23msgstr ""
2424
@@ -54,11 +54,11 @@
54msgid "Select All"54msgid "Select All"
55msgstr ""55msgstr ""
5656
57#: ../app/alarm/AlarmPage.qml:14157#: ../app/alarm/AlarmPage.qml:152
58msgid "No saved alarms"58msgid "No saved alarms"
59msgstr ""59msgstr ""
6060
61#: ../app/alarm/AlarmPage.qml:14261#: ../app/alarm/AlarmPage.qml:153
62msgid "Tap the + icon to add an alarm"62msgid "Tap the + icon to add an alarm"
63msgstr ""63msgstr ""
6464
@@ -136,26 +136,26 @@
136msgid "Daily"136msgid "Daily"
137msgstr ""137msgstr ""
138138
139#: ../app/alarm/AlarmUtils.qml:72139#: ../app/alarm/AlarmUtils.qml:82
140#, qt-format140#, qt-format
141msgid "Next Alarm %1"141msgid "Next Alarm %1"
142msgstr ""142msgstr ""
143143
144#: ../app/alarm/AlarmUtils.qml:79144#: ../app/alarm/AlarmUtils.qml:89
145msgid "Alarm Passed"145msgid "Alarm Passed"
146msgstr ""146msgstr ""
147147
148#: ../app/alarm/AlarmUtils.qml:89148#: ../app/alarm/AlarmUtils.qml:99
149#, no-c-format, qt-format149#, no-c-format, qt-format
150msgid "in %1d %2h %3m"150msgid "in %1d %2h %3m"
151msgstr ""151msgstr ""
152152
153#: ../app/alarm/AlarmUtils.qml:99153#: ../app/alarm/AlarmUtils.qml:109
154#, no-c-format, qt-format154#, no-c-format, qt-format
155msgid "in %1h %2m"155msgid "in %1h %2m"
156msgstr ""156msgstr ""
157157
158#: ../app/alarm/AlarmUtils.qml:108158#: ../app/alarm/AlarmUtils.qml:118
159#, no-c-format, qt-format159#, no-c-format, qt-format
160msgid "in %1m"160msgid "in %1m"
161msgstr ""161msgstr ""
@@ -177,13 +177,13 @@
177msgid "Add sound from"177msgid "Add sound from"
178msgstr ""178msgstr ""
179179
180#: ../app/clock/ClockPage.qml:225180#: ../app/clock/ClockPage.qml:249
181msgid "Retrieving location..."181msgid "Retrieving location..."
182msgstr ""182msgstr ""
183183
184#. TRANSLATORS: This refers to the stopwatch lap and is shown as a header where space is limited. Constrain184#. TRANSLATORS: This refers to the stopwatch lap and is shown as a header where space is limited. Constrain
185#. translation length to a few characters.185#. translation length to a few characters.
186#: ../app/stopwatch/LapListView.qml:46 ../app/stopwatch/StopwatchPage.qml:131186#: ../app/stopwatch/LapListView.qml:46 ../app/stopwatch/StopwatchPage.qml:83
187msgid "Lap"187msgid "Lap"
188msgstr ""188msgstr ""
189189
@@ -195,19 +195,19 @@
195msgid "Total Time"195msgid "Total Time"
196msgstr ""196msgstr ""
197197
198#: ../app/stopwatch/StopwatchPage.qml:114198#: ../app/stopwatch/StopwatchPage.qml:66
199msgid "Stop"199msgid "Stop"
200msgstr ""200msgstr ""
201201
202#: ../app/stopwatch/StopwatchPage.qml:114202#: ../app/stopwatch/StopwatchPage.qml:66
203msgid "Start"203msgid "Start"
204msgstr ""204msgstr ""
205205
206#: ../app/stopwatch/StopwatchPage.qml:114206#: ../app/stopwatch/StopwatchPage.qml:66
207msgid "Resume"207msgid "Resume"
208msgstr ""208msgstr ""
209209
210#: ../app/stopwatch/StopwatchPage.qml:131210#: ../app/stopwatch/StopwatchPage.qml:83
211msgid "Clear"211msgid "Clear"
212msgstr ""212msgstr ""
213213
@@ -222,37 +222,37 @@
222222
223#. TRANSLATORS: this indicates if the time in a world clock223#. TRANSLATORS: this indicates if the time in a world clock
224#. is behind or ahead of the time at the current location224#. is behind or ahead of the time at the current location
225#: ../app/worldclock/UserWorldCityDelegate.qml:147225#: ../app/worldclock/UserWorldCityDelegate.qml:133
226msgid "behind"226msgid "behind"
227msgstr ""227msgstr ""
228228
229#: ../app/worldclock/UserWorldCityDelegate.qml:148229#: ../app/worldclock/UserWorldCityDelegate.qml:134
230msgid "ahead"230msgid "ahead"
231msgstr ""231msgstr ""
232232
233#. TRANSLATORS: the first argument is hour, followed by233#. TRANSLATORS: the first argument is hour, followed by
234#. minute, and the translation for either 'behind' or234#. minute, and the translation for either 'behind' or
235#. 'ahead'235#. 'ahead'
236#: ../app/worldclock/UserWorldCityDelegate.qml:158236#: ../app/worldclock/UserWorldCityDelegate.qml:144
237#, qt-format237#, qt-format
238msgid "%1h %2m %3"238msgid "%1h %2m %3"
239msgstr ""239msgstr ""
240240
241#. TRANSLATORS: the first argument is hour, followed by the241#. TRANSLATORS: the first argument is hour, followed by the
242#. translation for either 'behind' or 'ahead'242#. translation for either 'behind' or 'ahead'
243#: ../app/worldclock/UserWorldCityDelegate.qml:167243#: ../app/worldclock/UserWorldCityDelegate.qml:153
244#, qt-format244#, qt-format
245msgid "%1h %2"245msgid "%1h %2"
246msgstr ""246msgstr ""
247247
248#. TRANSLATORS: the first argument is minute, followed by the248#. TRANSLATORS: the first argument is minute, followed by the
249#. translation for either 'behind' or 'ahead'249#. translation for either 'behind' or 'ahead'
250#: ../app/worldclock/UserWorldCityDelegate.qml:175250#: ../app/worldclock/UserWorldCityDelegate.qml:161
251#, qt-format251#, qt-format
252msgid "%1m %2"252msgid "%1m %2"
253msgstr ""253msgstr ""
254254
255#: ../app/worldclock/UserWorldCityDelegate.qml:181255#: ../app/worldclock/UserWorldCityDelegate.qml:167
256msgid "Same time"256msgid "Same time"
257msgstr ""257msgstr ""
258258

Subscribers

People subscribed via source and target branches