Merge lp:~vthompson/ubuntu-clock-app/fix-1285960 into lp:ubuntu-clock-app/saucy

Proposed by Victor Thompson
Status: Merged
Approved by: Nekhelesh Ramananthan
Approved revision: 363
Merged at revision: 363
Proposed branch: lp:~vthompson/ubuntu-clock-app/fix-1285960
Merge into: lp:ubuntu-clock-app/saucy
Diff against target: 56 lines (+24/-22)
1 file modified
alarm/AddAlarmPage.qml (+24/-22)
To merge this branch: bzr merge lp:~vthompson/ubuntu-clock-app/fix-1285960
Reviewer Review Type Date Requested Status
Nekhelesh Ramananthan Approve
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Review via email: mp+208914@code.launchpad.net

Commit message

* Prevent selector from setting alarm data when not visible

Description of the change

* Prevent selector from setting alarm data when not visible

To post a comment you must log in.
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Nekhelesh Ramananthan (nik90) wrote :

nice..a very clean fix. I was trying all sorts of stuff to figure out why this was happening.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'alarm/AddAlarmPage.qml'
2--- alarm/AddAlarmPage.qml 2014-02-20 22:31:32 +0000
3+++ alarm/AddAlarmPage.qml 2014-03-01 04:33:32 +0000
4@@ -583,28 +583,30 @@
5 selectedIndex: alarm.date.getDay();
6
7 onSelectedIndexChanged: {
8- switch (selectedIndex) {
9- case 0:
10- alarm.daysOfWeek = Alarm.Sunday;
11- break;
12- case 1:
13- alarm.daysOfWeek = Alarm.Monday;
14- break;
15- case 2:
16- alarm.daysOfWeek = Alarm.Tuesday;
17- break;
18- case 3:
19- alarm.daysOfWeek = Alarm.Wednesday;
20- break;
21- case 4:
22- alarm.daysOfWeek = Alarm.Thursday;
23- break;
24- case 5:
25- alarm.daysOfWeek = Alarm.Friday;
26- break;
27- case 6:
28- alarm.daysOfWeek = Alarm.Saturday;
29- break;
30+ if (visible) {
31+ switch (selectedIndex) {
32+ case 0:
33+ alarm.daysOfWeek = Alarm.Sunday;
34+ break;
35+ case 1:
36+ alarm.daysOfWeek = Alarm.Monday;
37+ break;
38+ case 2:
39+ alarm.daysOfWeek = Alarm.Tuesday;
40+ break;
41+ case 3:
42+ alarm.daysOfWeek = Alarm.Wednesday;
43+ break;
44+ case 4:
45+ alarm.daysOfWeek = Alarm.Thursday;
46+ break;
47+ case 5:
48+ alarm.daysOfWeek = Alarm.Friday;
49+ break;
50+ case 6:
51+ alarm.daysOfWeek = Alarm.Saturday;
52+ break;
53+ }
54 }
55 }
56 }

Subscribers

People subscribed via source and target branches