Merge lp:~ubuntu-clock-dev/ubuntu-clock-app/ubuntu-clock-app-new-design into lp:ubuntu-clock-app
- ubuntu-clock-app-new-design
- Merge into trunk
Status: | Merged | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Approved by: | Nekhelesh Ramananthan | ||||||||||||||||||||
Approved revision: | 475 | ||||||||||||||||||||
Merged at revision: | 442 | ||||||||||||||||||||
Proposed branch: | lp:~ubuntu-clock-dev/ubuntu-clock-app/ubuntu-clock-app-new-design | ||||||||||||||||||||
Merge into: | lp:ubuntu-clock-app | ||||||||||||||||||||
Diff against target: |
2371 lines (+525/-765) 37 files modified
app/MainPage.qml (+3/-2) app/alarm/AlarmDelegate.qml (+94/-128) app/alarm/AlarmRepeat.qml (+19/-30) app/alarm/AlarmSettingsPage.qml (+74/-89) app/alarm/AlarmSound.qml (+29/-59) app/alarm/EditAlarmPage.qml (+31/-12) app/clock/ClockPage.qml (+18/-13) app/clock/MainClock.qml (+5/-4) app/components/ActionIcon.qml (+4/-3) app/components/AnalogMode.qml (+53/-0) app/components/Background.qml (+0/-32) app/components/CMakeLists.txt (+0/-2) app/components/Clock.qml (+2/-5) app/components/ClockCircle.qml (+16/-25) app/components/DigitalMode.qml (+2/-2) app/components/EmptyState.qml (+1/-1) app/components/ExpandableListItem.qml (+25/-32) app/components/HeaderNavigation.qml (+8/-31) app/components/SubtitledListItem.qml (+0/-59) app/graphics/CMakeLists.txt (+3/-3) app/graphics/Stopwatch_Placeholder.svg (+0/-19) app/graphics/WorldClock_Placeholder.svg (+0/-21) app/stopwatch/LapListView.qml (+18/-22) app/stopwatch/StopwatchFace.qml (+22/-28) app/stopwatch/StopwatchPage.qml (+25/-8) app/ubuntu-clock-app.qml (+1/-11) app/upstreamcomponents/FastScroll.qml (+2/-2) app/worldclock/AddWorldCityButton.qml (+7/-13) app/worldclock/UserWorldCityDelegate.qml (+8/-6) app/worldclock/WorldCityList.qml (+10/-37) backend/modules/Stopwatch/formattime.cpp (+1/-10) po/com.ubuntu.clock.pot (+39/-39) tests/unit/ClockTestCase.qml (+1/-1) tests/unit/tst_alarmLabel.qml (+1/-1) tests/unit/tst_alarmRepeat.qml (+1/-1) tests/unit/tst_alarmUtils.qml (+2/-2) tests/unit/tst_stopwatchUtils.qml (+0/-12) |
||||||||||||||||||||
To merge this branch: | bzr merge lp:~ubuntu-clock-dev/ubuntu-clock-app/ubuntu-clock-app-new-design | ||||||||||||||||||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Jenkins Bot | continuous-integration | Approve | |
Nekhelesh Ramananthan | Approve | ||
Bartosz Kosiorek | Approve | ||
Review via email:
|
Commit message
Clock New Design Implementation
Description of the change
Clock New Design Implementation

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:453
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 454. By Michal Predotka
-
Change stopwatch buttons size, start/stop stopwatch by clicking on the clock face
- 455. By Michal Predotka
-
Add fold to clock face

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:455
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 456. By Michal Predotka
-
Change world clock list sizes

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:456
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 457. By Bartosz Kosiorek
-
Improve seconds hand visuals
- 458. By Bartosz Kosiorek
-
Merge with trunk
- 459. By Bartosz Kosiorek
-
Update pot template

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:459
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/

Bartosz Kosiorek (gang65) wrote : | # |
Generally it works awensome.
Some coding style and comment improvements needs to be done, before merging.
- 460. By Bartosz Kosiorek
-
Fix code style issues

Bartosz Kosiorek (gang65) wrote : | # |
It seems that run time of Clock application are the same with new Design (around 4,697s)

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:460
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/

Nekhelesh Ramananthan (nik90) wrote : | # |
> It seems that run time of Clock application are the same with new Design
> (around 4,697s)
Really? That's surprising considering that we removed the background image and are using the new listitem layouts etc. I didnt expect a huge reduction in startup time, but a small decrease of maybe 1-2% atleast :/.
@Bartosz, we need to fix the AP tests before we can merge this branch.
- 461. By Bartosz Kosiorek
-
Increase size of font to Medium

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:461
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 462. By Michal Predotka
-
Move fold a bit
- 463. By Bartosz Kosiorek
-
Change hands of clock according to design

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:462
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 464. By Bartosz Kosiorek
-
Fix second hand shadow

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:464
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 465. By Nekhelesh Ramananthan
-
Properly hide header. This should fix the page header animations for the settings and bottom-edge page

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:465
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 466. By Bartosz Kosiorek
-
Clock hands improvements
- 467. By Bartosz Kosiorek
-
Add shadows to hands
- 468. By Bartosz Kosiorek
-
FIx Second hand
- 469. By Bartosz Kosiorek
-
Add shadows to clock hands
- 470. By Bartosz Kosiorek
-
Some small shadow fixes

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:470
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 471. By Michal Predotka
-
Update clock hands graphics

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:471
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 472. By Nekhelesh Ramananthan
-
Fixed failing tst_alarmLabel.qml unit tests
- 473. By Nekhelesh Ramananthan
-
Fixed failing stopwatchUtils and alarmUtils unit tests
- 474. By Nekhelesh Ramananthan
-
removed outdated comment

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:474
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/
- 475. By Nekhelesh Ramananthan
-
Fixed the failing worldcity AP tests

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:475
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/

Jenkins Bot (ubuntu-core-apps-jenkins-bot) wrote : | # |
FAILED: Continuous integration, rev:475
https:/
Executed test runs:
None: https:/
Click here to trigger a rebuild:
https:/

Nekhelesh Ramananthan (nik90) wrote : | # |
I am top-approving this branch. Let's continue any further changes in the next MP. There are still 3 AP tests failing, but it seems to be the case in trunk as well and not specific to this MP.

Jenkins Bot (ubuntu-core-apps-jenkins-bot) : | # |
Preview Diff
1 | === modified file 'app/MainPage.qml' |
2 | --- app/MainPage.qml 2016-01-16 08:52:49 +0000 |
3 | +++ app/MainPage.qml 2016-02-25 18:41:31 +0000 |
4 | @@ -80,8 +80,9 @@ |
5 | } |
6 | } |
7 | |
8 | - head.visible: false |
9 | - head.locked: true |
10 | + header: PageHeader { |
11 | + visible: false |
12 | + } |
13 | |
14 | HeaderNavigation { |
15 | id: headerRow |
16 | |
17 | === modified file 'app/alarm/AlarmDelegate.qml' |
18 | --- app/alarm/AlarmDelegate.qml 2016-01-05 10:56:20 +0000 |
19 | +++ app/alarm/AlarmDelegate.qml 2016-02-25 18:41:31 +0000 |
20 | @@ -17,7 +17,6 @@ |
21 | */ |
22 | |
23 | import QtQuick 2.4 |
24 | -import QtQuick.Layouts 1.1 |
25 | import Ubuntu.Components 1.3 |
26 | |
27 | ListItem { |
28 | @@ -25,134 +24,101 @@ |
29 | |
30 | property var localTime |
31 | property bool showAlarmFrequency |
32 | - |
33 | - width: parent ? parent.width : 0 |
34 | - height: units.gu(9) |
35 | - divider.visible: true |
36 | + property string alarmOccurrence: type === Alarm.Repeating ? alarmUtils.format_day_string(daysOfWeek, type) |
37 | + : alarmUtils.get_time_to_alarm(model.date, localTime) |
38 | |
39 | onShowAlarmFrequencyChanged: { |
40 | if (type === Alarm.Repeating && model.enabled) { |
41 | - alarmSubtitle.animateTextChange() |
42 | - } |
43 | - } |
44 | - |
45 | - Column { |
46 | - id: alarmDetailsColumn |
47 | - |
48 | - spacing: units.gu(1) |
49 | - opacity: model.enabled ? 1.0 : 0.8 |
50 | - |
51 | - anchors { |
52 | - left: parent.left |
53 | - leftMargin: units.gu(2) |
54 | - right: alarmStatus.left |
55 | - rightMargin: units.gu(1) |
56 | - verticalCenter: parent.verticalCenter |
57 | - } |
58 | - |
59 | - Label { |
60 | - id: alarmTime |
61 | - objectName: "listAlarmTime" + index |
62 | - |
63 | - color: UbuntuColors.midAubergine |
64 | - fontSize: "x-large" |
65 | - text: Qt.formatTime(model.date) |
66 | - } |
67 | - |
68 | - RowLayout { |
69 | - width: parent.width |
70 | - spacing: units.gu(1) |
71 | - |
72 | - Label { |
73 | - id: alarmLabel |
74 | - objectName: "listAlarmLabel" + index |
75 | - |
76 | - text: message |
77 | - fontSize: "small" |
78 | - elide: Text.ElideRight |
79 | - Layout.maximumWidth: parent.width > alarmLabel.contentWidth + alarmSubtitle.contentWidth ? (parent.width - alarmSubtitle.contentWidth - units.gu(4)) |
80 | - : contentWidth |
81 | - } |
82 | - |
83 | - Label { |
84 | - text: "|" |
85 | - visible: alarmSubtitle.visible |
86 | - } |
87 | - |
88 | - Label { |
89 | - id: alarmSubtitle |
90 | - objectName: "listAlarmSubtitle" + index |
91 | - |
92 | - fontSize: "small" |
93 | - Layout.fillWidth: true |
94 | - visible: ((type === Alarm.Repeating) || model.enabled) && (model.status === Alarm.Ready) |
95 | - elide: Text.ElideRight |
96 | - text: type === Alarm.Repeating ? alarmUtils.format_day_string(daysOfWeek, type) : |
97 | - alarmUtils.get_time_to_alarm(model.date, localTime) |
98 | - |
99 | - function animateTextChange() { |
100 | - textChangeAnimation.start() |
101 | - } |
102 | - |
103 | - |
104 | - SequentialAnimation { |
105 | - id: textChangeAnimation |
106 | - PropertyAnimation { |
107 | - target: alarmSubtitle |
108 | - property: "opacity" |
109 | - to: 0 |
110 | - duration: UbuntuAnimation.BriskDuration |
111 | - } |
112 | - |
113 | - ScriptAction { |
114 | - script: alarmSubtitle.text = showAlarmFrequency ? alarmUtils.format_day_string(daysOfWeek, type) |
115 | - : alarmUtils.get_time_to_alarm(model.date, localTime) |
116 | - } |
117 | - |
118 | - PropertyAnimation { |
119 | - target: alarmSubtitle |
120 | - property: "opacity" |
121 | - to: 1.0 |
122 | - duration: UbuntuAnimation.BriskDuration |
123 | - } |
124 | - } |
125 | - } |
126 | - } |
127 | - } |
128 | - |
129 | - Switch { |
130 | - id: alarmStatus |
131 | - objectName: "listAlarmStatus" + index |
132 | - checked: model.enabled && (model.status === Alarm.Ready) |
133 | - |
134 | - anchors { |
135 | - right: parent.right |
136 | - rightMargin: units.gu(2) |
137 | - verticalCenter: parent.verticalCenter |
138 | - } |
139 | - |
140 | - onCheckedChanged: { |
141 | - if (checked !== model.enabled) { |
142 | - /* |
143 | - Calculate the alarm time if it is a one-time alarm. |
144 | - Repeating alarms do this automatically. |
145 | - */ |
146 | - if(type === Alarm.OneTime) { |
147 | - var date = new Date() |
148 | - date.setHours(model.date.getHours(), model.date.getMinutes(), 0) |
149 | - |
150 | - model.daysOfWeek = Alarm.AutoDetect |
151 | - if (date < new Date()) { |
152 | - var tomorrow = new Date() |
153 | - tomorrow.setDate(tomorrow.getDate() + 1) |
154 | - model.daysOfWeek = alarmUtils.get_alarm_day(tomorrow.getDay()) |
155 | - } |
156 | - model.date = date |
157 | - |
158 | - } |
159 | - model.enabled = checked |
160 | - model.save() |
161 | - } |
162 | - } |
163 | - } |
164 | + animateTextChange() |
165 | + } |
166 | + } |
167 | + |
168 | + function animateTextChange() { |
169 | + textChangeAnimation.start() |
170 | + } |
171 | + |
172 | + height: mainLayout.height + divider.height |
173 | + |
174 | + SequentialAnimation { |
175 | + id: textChangeAnimation |
176 | + |
177 | + PropertyAnimation { |
178 | + target: mainLayout.summary |
179 | + property: "opacity" |
180 | + to: 0 |
181 | + duration: UbuntuAnimation.BriskDuration |
182 | + } |
183 | + |
184 | + ScriptAction { |
185 | + script: alarmOccurrence = showAlarmFrequency ? alarmUtils.format_day_string(daysOfWeek, type) |
186 | + : alarmUtils.get_time_to_alarm(model.date, localTime) |
187 | + } |
188 | + |
189 | + PropertyAnimation { |
190 | + target: mainLayout.summary |
191 | + property: "opacity" |
192 | + to: 1.0 |
193 | + duration: UbuntuAnimation.BriskDuration |
194 | + } |
195 | + } |
196 | + |
197 | + ListItemLayout { |
198 | + id: mainLayout |
199 | + |
200 | + title.text: Qt.formatTime(model.date) // Alarm time |
201 | + title.font.weight: Font.Normal |
202 | + subtitle.text: message // Alarm name |
203 | + summary.text: alarmOccurrence |
204 | + |
205 | + Switch { |
206 | + id: alarmStatus |
207 | + |
208 | + objectName: "listAlarmStatus" + index |
209 | + anchors.verticalCenter: parent.verticalCenter |
210 | + SlotsLayout.position: SlotsLayout.Trailing |
211 | + SlotsLayout.overrideVerticalPositioning: true |
212 | + checked: model.enabled && (model.status === Alarm.Ready) |
213 | + onCheckedChanged: { |
214 | + if (checked !== model.enabled) { |
215 | + /* |
216 | + Calculate the alarm time if it is a one-time alarm. |
217 | + Repeating alarms do this automatically. |
218 | + */ |
219 | + if(type === Alarm.OneTime) { |
220 | + var date = new Date() |
221 | + date.setHours(model.date.getHours(), model.date.getMinutes(), 0) |
222 | + |
223 | + model.daysOfWeek = Alarm.AutoDetect |
224 | + if (date < new Date()) { |
225 | + var tomorrow = new Date() |
226 | + tomorrow.setDate(tomorrow.getDate() + 1) |
227 | + model.daysOfWeek = alarmUtils.get_alarm_day(tomorrow.getDay()) |
228 | + } |
229 | + model.date = date |
230 | + |
231 | + } |
232 | + model.enabled = checked |
233 | + model.save() |
234 | + } |
235 | + } |
236 | + |
237 | + Connections { |
238 | + target: model |
239 | + onStatusChanged: { |
240 | + /* |
241 | + Update switch value only when the alarm save() operation |
242 | + is complete to avoid switching it back. |
243 | + */ |
244 | + if (model.status === Alarm.Ready) { |
245 | + alarmStatus.checked = model.enabled; |
246 | + |
247 | + if (!alarmStatus.checked && type === Alarm.Repeating) { |
248 | + alarmOccurrence = alarmUtils.format_day_string(daysOfWeek, type) |
249 | + } |
250 | + } |
251 | + } |
252 | + } |
253 | + } |
254 | + } |
255 | + |
256 | } |
257 | |
258 | === modified file 'app/alarm/AlarmRepeat.qml' |
259 | --- app/alarm/AlarmRepeat.qml 2015-10-22 16:49:23 +0000 |
260 | +++ app/alarm/AlarmRepeat.qml 2016-02-25 18:41:31 +0000 |
261 | @@ -149,40 +149,29 @@ |
262 | |
263 | property alias isChecked: daySwitch.checked |
264 | |
265 | - Label { |
266 | + height: _alarmDay.height + divider.height |
267 | + |
268 | + ListItemLayout { |
269 | id: _alarmDay |
270 | objectName: 'alarmDay' + index |
271 | |
272 | - anchors { |
273 | - left: parent.left |
274 | - leftMargin: units.gu(2) |
275 | - verticalCenter: parent.verticalCenter |
276 | - } |
277 | - |
278 | - color: UbuntuColors.midAubergine |
279 | - text: day |
280 | - } |
281 | - |
282 | - CheckBox { |
283 | - id: daySwitch |
284 | - objectName: 'daySwitch' + index |
285 | - |
286 | - anchors { |
287 | - right: parent.right |
288 | - rightMargin: units.gu(2) |
289 | - verticalCenter: parent.verticalCenter |
290 | - } |
291 | - |
292 | - checked: (alarm.daysOfWeek & flag) == flag |
293 | - && alarm.type === Alarm.Repeating |
294 | - onCheckedChanged: { |
295 | - if (checked) { |
296 | - alarm.daysOfWeek |= flag |
297 | - } else { |
298 | - alarm.daysOfWeek &= ~flag |
299 | + title.text: day |
300 | + |
301 | + CheckBox { |
302 | + id: daySwitch |
303 | + objectName: 'daySwitch' + index |
304 | + SlotsLayout.position: SlotsLayout.Trailing |
305 | + checked: (alarm.daysOfWeek & flag) == flag |
306 | + && alarm.type === Alarm.Repeating |
307 | + onCheckedChanged: { |
308 | + if (checked) { |
309 | + alarm.daysOfWeek |= flag |
310 | + } else { |
311 | + alarm.daysOfWeek &= ~flag |
312 | + } |
313 | + |
314 | + detectAlarmType() |
315 | } |
316 | - |
317 | - detectAlarmType() |
318 | } |
319 | } |
320 | |
321 | |
322 | === modified file 'app/alarm/AlarmSettingsPage.qml' |
323 | --- app/alarm/AlarmSettingsPage.qml 2015-12-20 00:01:25 +0000 |
324 | +++ app/alarm/AlarmSettingsPage.qml 2016-02-25 18:41:31 +0000 |
325 | @@ -17,10 +17,8 @@ |
326 | */ |
327 | |
328 | import QtQuick 2.4 |
329 | -import QtQuick.Layouts 1.1 |
330 | import WorldClock 1.0 |
331 | import Alarm 1.0 |
332 | -import Ubuntu.Settings.Menus 0.1 as Menus |
333 | import Ubuntu.Components 1.3 |
334 | import "../components" |
335 | |
336 | @@ -85,67 +83,58 @@ |
337 | top: parent.top |
338 | left: parent.left |
339 | right: parent.right |
340 | - topMargin: units.gu(2) |
341 | - } |
342 | - |
343 | - Label { |
344 | - color: UbuntuColors.midAubergine |
345 | - text: i18n.tr("Alarm volume") |
346 | - anchors { |
347 | - left: parent.left |
348 | - leftMargin: units.gu(2) |
349 | - } |
350 | - } |
351 | - |
352 | - Menus.SliderMenu { |
353 | - anchors { |
354 | - left: parent.left |
355 | - right: parent.right |
356 | - } |
357 | - minimumValue: 1 |
358 | - maximumValue: 100 |
359 | - live: true |
360 | - value: alarmSettings.volume |
361 | - |
362 | - onValueChanged: { |
363 | - alarmSettings.volume = value |
364 | - } |
365 | - } |
366 | - |
367 | + } |
368 | + |
369 | + ListItem { |
370 | + height: alarmVolumeSlot.height + divider.height |
371 | + |
372 | + SlotsLayout { |
373 | + id: alarmVolumeSlot |
374 | + |
375 | + mainSlot: Column { |
376 | + Label { |
377 | + text: i18n.tr("Alarm volume") |
378 | + } |
379 | + |
380 | + Slider { |
381 | + minimumValue: 1 |
382 | + maximumValue: 100 |
383 | + live: true |
384 | + value: alarmSettings.volume |
385 | + function formatValue(v) { return v = "" } |
386 | + onValueChanged: { |
387 | + alarmSettings.volume = value |
388 | + } |
389 | + } |
390 | + } |
391 | + } |
392 | + } |
393 | + |
394 | ExpandableListItem { |
395 | id: _alarmDuration |
396 | |
397 | listViewHeight: units.gu(28) |
398 | - text: i18n.tr("Alarm stops after") |
399 | - subText: i18n.tr("%1 minute", "%1 minutes", alarmSettings.duration).arg(alarmSettings.duration) |
400 | + titleText.text: i18n.tr("Alarm stops after") |
401 | + subText.text: i18n.tr("%1 minute", "%1 minutes", alarmSettings.duration).arg(alarmSettings.duration) |
402 | |
403 | model: durationModel |
404 | |
405 | delegate: ListItem { |
406 | - RowLayout { |
407 | - anchors { |
408 | - left: parent.left |
409 | - right: parent.right |
410 | - margins: units.gu(2) |
411 | - verticalCenter: parent.verticalCenter |
412 | - } |
413 | - |
414 | - Label { |
415 | - text: model.text |
416 | - Layout.fillWidth: true |
417 | - } |
418 | + ListItemLayout { |
419 | + title.text: model.text |
420 | |
421 | Icon { |
422 | + SlotsLayout.position: SlotsLayout.Trailing |
423 | width: units.gu(2) |
424 | height: width |
425 | - name: "ok" |
426 | + name: "tick" |
427 | visible: alarmSettings.duration === duration |
428 | } |
429 | } |
430 | |
431 | onClicked: { |
432 | alarmSettings.duration = duration |
433 | - _alarmDuration.expanded = false |
434 | + _alarmDuration.expansion.expanded = false |
435 | } |
436 | } |
437 | } |
438 | @@ -154,66 +143,47 @@ |
439 | id: _alarmSnooze |
440 | |
441 | listViewHeight: units.gu(28) |
442 | - text: i18n.tr("Snooze for") |
443 | - subText: i18n.tr("%1 minute", "%1 minutes", alarmSettings.snoozeDuration).arg(alarmSettings.snoozeDuration) |
444 | + titleText.text: i18n.tr("Snooze for") |
445 | + subText.text: i18n.tr("%1 minute", "%1 minutes", alarmSettings.snoozeDuration).arg(alarmSettings.snoozeDuration) |
446 | |
447 | model: snoozeModel |
448 | |
449 | delegate: ListItem { |
450 | - RowLayout { |
451 | - anchors { |
452 | - left: parent.left |
453 | - right: parent.right |
454 | - margins: units.gu(2) |
455 | - verticalCenter: parent.verticalCenter |
456 | - } |
457 | - |
458 | - Label { |
459 | - text: model.text |
460 | - Layout.fillWidth: true |
461 | - } |
462 | + ListItemLayout { |
463 | + title.text: model.text |
464 | |
465 | Icon { |
466 | + SlotsLayout.position: SlotsLayout.Trailing |
467 | width: units.gu(2) |
468 | height: width |
469 | - name: "ok" |
470 | + name: "tick" |
471 | visible: alarmSettings.snoozeDuration === duration |
472 | } |
473 | } |
474 | |
475 | onClicked: { |
476 | alarmSettings.snoozeDuration = duration |
477 | - _alarmSnooze.expanded = false |
478 | + _alarmSnooze.expansion.expanded = false |
479 | } |
480 | } |
481 | } |
482 | |
483 | ListItem { |
484 | - Label { |
485 | - text: i18n.tr("Vibration") |
486 | - color: UbuntuColors.midAubergine |
487 | - anchors { |
488 | - left: parent.left |
489 | - leftMargin: units.gu(2) |
490 | - verticalCenter: parent.verticalCenter |
491 | - } |
492 | - } |
493 | - |
494 | - Switch { |
495 | - id: vibrateSwitch |
496 | - |
497 | - anchors { |
498 | - right: parent.right |
499 | - rightMargin: units.gu(2) |
500 | - verticalCenter: parent.verticalCenter |
501 | - } |
502 | - |
503 | - checked: alarmSettings.vibration === "pulse" |
504 | - onCheckedChanged: { |
505 | - if(checked) { |
506 | - alarmSettings.vibration = "pulse" |
507 | - } else { |
508 | - alarmSettings.vibration = "none" |
509 | + height: vibrationLayout.height + divider.height |
510 | + ListItemLayout { |
511 | + id: vibrationLayout |
512 | + title.text: i18n.tr("Vibration") |
513 | + |
514 | + Switch { |
515 | + id: vibrateSwitch |
516 | + SlotsLayout.position: SlotsLayout.Trailing |
517 | + checked: alarmSettings.vibration === "pulse" |
518 | + onCheckedChanged: { |
519 | + if(checked) { |
520 | + alarmSettings.vibration = "pulse" |
521 | + } else { |
522 | + alarmSettings.vibration = "none" |
523 | + } |
524 | } |
525 | } |
526 | } |
527 | @@ -223,13 +193,28 @@ |
528 | } |
529 | } |
530 | |
531 | - SubtitledListItem { |
532 | - text: i18n.tr("Change time and date") |
533 | - subText: localTimeSource.localizedCurrentDateString + " " + localTimeSource.localizedCurrentTimeString |
534 | + ListItem { |
535 | + height: timeAndDateLayout.height + divider.height |
536 | + ListItemLayout { |
537 | + id: timeAndDateLayout |
538 | + title.text: i18n.tr("Change time and date") |
539 | + subtitle.text: localTimeSource.localizedCurrentDateString + " " + localTimeSource.localizedCurrentTimeString |
540 | + |
541 | + Icon { |
542 | + SlotsLayout.position: SlotsLayout.Trailing |
543 | + SlotsLayout.overrideVerticalPositioning: true |
544 | + anchors.verticalCenter: parent.verticalCenter |
545 | + width: units.gu(2) |
546 | + height: width |
547 | + name: "go-next" |
548 | + } |
549 | + } |
550 | + |
551 | onClicked: { |
552 | Qt.openUrlExternally("settings:///system/time-date") |
553 | } |
554 | } |
555 | + |
556 | } |
557 | } |
558 | } |
559 | |
560 | === modified file 'app/alarm/AlarmSound.qml' |
561 | --- app/alarm/AlarmSound.qml 2015-12-11 02:13:16 +0000 |
562 | +++ app/alarm/AlarmSound.qml 2016-02-25 18:41:31 +0000 |
563 | @@ -21,7 +21,6 @@ |
564 | import QtMultimedia 5.0 |
565 | import Ubuntu.Content 1.1 |
566 | import Ubuntu.Components 1.3 |
567 | -import QtQuick.Layouts 1.1 |
568 | import Qt.labs.folderlistmodel 2.1 |
569 | |
570 | Page { |
571 | @@ -168,15 +167,16 @@ |
572 | id: _pageFlickable |
573 | |
574 | anchors.fill: parent |
575 | - contentHeight: defaultSoundModel.count * units.gu(7) + |
576 | - customSoundModel.count * units.gu(7) + |
577 | - customSoundListItem.height + |
578 | - 2 * customSoundsHeader.implicitHeight + units.gu(4) |
579 | + contentHeight: _alarmSoundColumn.height |
580 | |
581 | Column { |
582 | id: _alarmSoundColumn |
583 | |
584 | - anchors.fill: parent |
585 | + anchors { |
586 | + top: parent.top |
587 | + right: parent.right |
588 | + left: parent.left |
589 | + } |
590 | |
591 | ListItem { |
592 | height: customSoundsHeader.implicitHeight + units.gu(2) |
593 | @@ -216,11 +216,10 @@ |
594 | id: _customAlarmSoundDelegate |
595 | objectName: "customAlarmSoundDelegate" + index |
596 | |
597 | - property bool isChecked: alarmSound.subText === _customSoundName.text ? true |
598 | + property bool isChecked: alarmSound.subText === _customSoundName.title.text ? true |
599 | : false |
600 | |
601 | - height: units.gu(7) |
602 | - color: isChecked ? Theme.palette.selected.background : "Transparent" |
603 | + height: _customSoundName.height + divider.height |
604 | |
605 | leadingActions: ListItemActions { |
606 | actions: [ |
607 | @@ -277,29 +276,14 @@ |
608 | ] |
609 | } |
610 | |
611 | - RowLayout { |
612 | - spacing: units.gu(2) |
613 | - |
614 | - anchors { |
615 | - fill: parent |
616 | - leftMargin: units.gu(2) |
617 | - rightMargin: units.gu(2) |
618 | - } |
619 | - |
620 | - Label { |
621 | - id: _customSoundName |
622 | - objectName: "customSoundName" + index |
623 | - |
624 | - anchors.verticalCenter: parent.verticalCenter |
625 | - Layout.fillWidth: true |
626 | - |
627 | - elide: Text.ElideRight |
628 | - color: UbuntuColors.midAubergine |
629 | - fontSize: "medium" |
630 | - text: fileBaseName |
631 | - } |
632 | + ListItemLayout { |
633 | + id: _customSoundName |
634 | + objectName: "customSoundName" + index |
635 | + |
636 | + title.text: fileBaseName |
637 | |
638 | Icon { |
639 | + SlotsLayout.position: SlotsLayout.Trailing |
640 | width: units.gu(2) |
641 | height: width |
642 | name: "media-playback-pause" |
643 | @@ -309,17 +293,17 @@ |
644 | |
645 | Icon { |
646 | id: tickIcon |
647 | + SlotsLayout.position: SlotsLayout.Last |
648 | + opacity: _customAlarmSoundDelegate.isChecked ? 1 : 0 |
649 | width: units.gu(2) |
650 | height: width |
651 | name: "tick" |
652 | - visible: _customAlarmSoundDelegate.isChecked |
653 | - anchors.verticalCenter: parent.verticalCenter |
654 | } |
655 | } |
656 | |
657 | onIsCheckedChanged: { |
658 | if (isChecked) { |
659 | - alarmSound.subText = _customSoundName.text |
660 | + alarmSound.subText = _customSoundName.title.text |
661 | alarm.sound = fileURL |
662 | |
663 | // Ensures only one custom alarm sound is selected |
664 | @@ -369,34 +353,19 @@ |
665 | id: _alarmSoundDelegate |
666 | objectName: "alarmSoundDelegate" + index |
667 | |
668 | - property bool isChecked: alarmSound.subText === _soundName.text ? true |
669 | + property bool isChecked: alarmSound.subText === _soundName.title.text ? true |
670 | : false |
671 | |
672 | - height: units.gu(7) |
673 | - color: isChecked ? Theme.palette.selected.background : "Transparent" |
674 | - |
675 | - RowLayout { |
676 | - spacing: units.gu(2) |
677 | - |
678 | - anchors { |
679 | - fill: parent |
680 | - leftMargin: units.gu(2) |
681 | - rightMargin: units.gu(2) |
682 | - } |
683 | - |
684 | - Label { |
685 | - id: _soundName |
686 | - objectName: "soundName" + index |
687 | - |
688 | - anchors.verticalCenter: parent.verticalCenter |
689 | - Layout.fillWidth: true |
690 | - |
691 | - color: UbuntuColors.midAubergine |
692 | - fontSize: "medium" |
693 | - text: fileBaseName |
694 | - } |
695 | + height: _soundName.height + divider.height |
696 | + |
697 | + ListItemLayout { |
698 | + id: _soundName |
699 | + objectName: "soundName" + index |
700 | + |
701 | + title.text: fileBaseName |
702 | |
703 | Icon { |
704 | + SlotsLayout.position: SlotsLayout.Trailing |
705 | width: units.gu(2) |
706 | height: width |
707 | name: "media-playback-pause" |
708 | @@ -405,17 +374,18 @@ |
709 | } |
710 | |
711 | Icon { |
712 | + SlotsLayout.position: SlotsLayout.Last |
713 | + opacity: _alarmSoundDelegate.isChecked ? 1 : 0 |
714 | width: units.gu(2) |
715 | height: width |
716 | name: "tick" |
717 | - visible: _alarmSoundDelegate.isChecked |
718 | anchors.verticalCenter: parent.verticalCenter |
719 | } |
720 | } |
721 | |
722 | onIsCheckedChanged: { |
723 | if (isChecked) { |
724 | - alarmSound.subText = _soundName.text |
725 | + alarmSound.subText = _soundName.title.text |
726 | alarm.sound = fileURL |
727 | |
728 | // Ensures only one alarm sound is selected |
729 | |
730 | === modified file 'app/alarm/EditAlarmPage.qml' |
731 | --- app/alarm/EditAlarmPage.qml 2015-12-11 02:11:11 +0000 |
732 | +++ app/alarm/EditAlarmPage.qml 2016-02-25 18:41:31 +0000 |
733 | @@ -118,8 +118,7 @@ |
734 | if (alarmObject.error !== Alarm.NoError) { |
735 | console.log("[ERROR]: Error saving alarm, code: " + alarmObject.error) |
736 | return false |
737 | - } |
738 | - else { |
739 | + } else { |
740 | return true |
741 | } |
742 | } |
743 | @@ -266,34 +265,54 @@ |
744 | } |
745 | } |
746 | |
747 | - SubtitledListItem { |
748 | + ListItem { |
749 | id: _alarmRepeat |
750 | objectName: "alarmRepeat" |
751 | |
752 | - text: i18n.tr("Repeat") |
753 | - subText: alarmUtils.format_day_string(_alarm.daysOfWeek, _alarm.type) |
754 | + property string subText: alarmUtils.format_day_string(_alarm.daysOfWeek, _alarm.type) |
755 | + height: alarmRepeatLayout.height + divider.height |
756 | + |
757 | + ListItemLayout { |
758 | + id: alarmRepeatLayout |
759 | + |
760 | + title.text: i18n.tr("Repeat") |
761 | + subtitle.text: _alarmRepeat.subText |
762 | + } |
763 | onClicked: pageStack.push(Qt.resolvedUrl("AlarmRepeat.qml"), |
764 | {"alarm": _alarm, "alarmUtils": alarmUtils}) |
765 | } |
766 | |
767 | - SubtitledListItem { |
768 | + ListItem { |
769 | id: _alarmLabel |
770 | objectName: "alarmLabel" |
771 | - |
772 | - text: i18n.tr("Label") |
773 | - subText: _alarm.message |
774 | + height: alarmLabelLayout.height + divider.height |
775 | + |
776 | + ListItemLayout { |
777 | + id: alarmLabelLayout |
778 | + |
779 | + title.text: i18n.tr("Label") |
780 | + subtitle.text: _alarm.message |
781 | + } |
782 | onClicked: pageStack.push(Qt.resolvedUrl("AlarmLabel.qml"), |
783 | {"alarm": _alarm}) |
784 | } |
785 | |
786 | - SubtitledListItem { |
787 | + ListItem { |
788 | id: _alarmSound |
789 | objectName: "alarmSound" |
790 | |
791 | readonly property string defaultAlarmSound: "Alarm clock" |
792 | readonly property string defaultAlarmSoundFileName: "Alarm clock.ogg" |
793 | - |
794 | - text: i18n.tr("Sound") |
795 | + property string subText |
796 | + |
797 | + height: alarmSoundLayout.height + divider.height |
798 | + |
799 | + ListItemLayout { |
800 | + id: alarmSoundLayout |
801 | + |
802 | + title.text: i18n.tr("Sound") |
803 | + subtitle.text: _alarmSound.subText |
804 | + } |
805 | onClicked: pageStack.push(Qt.resolvedUrl("AlarmSound.qml"), { |
806 | "alarmSound": _alarmSound, |
807 | "alarm": _alarm |
808 | |
809 | === modified file 'app/clock/ClockPage.qml' |
810 | --- app/clock/ClockPage.qml 2016-01-16 08:18:05 +0000 |
811 | +++ app/clock/ClockPage.qml 2016-02-25 18:41:31 +0000 |
812 | @@ -192,7 +192,7 @@ |
813 | |
814 | anchors { |
815 | verticalCenter: parent.top |
816 | - verticalCenterOffset: units.gu(18) |
817 | + verticalCenterOffset: units.gu(14) |
818 | horizontalCenter: parent.horizontalCenter |
819 | } |
820 | } |
821 | @@ -201,16 +201,13 @@ |
822 | id: date |
823 | |
824 | anchors { |
825 | - top: parent.top |
826 | - topMargin: units.gu(41) |
827 | + top: clock.bottom |
828 | horizontalCenter: parent.horizontalCenter |
829 | } |
830 | |
831 | text: clock.localizedDateString |
832 | - |
833 | + textSize: Label.Medium |
834 | opacity: 0 |
835 | - color: locationRow.visible ? Theme.palette.normal.baseText : UbuntuColors.midAubergine |
836 | - fontSize: "medium" |
837 | } |
838 | |
839 | Row { |
840 | @@ -223,7 +220,7 @@ |
841 | |
842 | anchors { |
843 | top: date.bottom |
844 | - topMargin: units.gu(1) |
845 | + topMargin: units.gu(2) |
846 | horizontalCenter: parent.horizontalCenter |
847 | } |
848 | |
849 | @@ -231,16 +228,14 @@ |
850 | id: locationIcon |
851 | name: "location" |
852 | height: units.gu(2.2) |
853 | - color: "Grey" |
854 | + color: location.color |
855 | } |
856 | |
857 | Label { |
858 | id: location |
859 | objectName: "location" |
860 | |
861 | - fontSize: "medium" |
862 | anchors.verticalCenter: locationIcon.verticalCenter |
863 | - color: UbuntuColors.midAubergine |
864 | |
865 | text: { |
866 | if (userLocationDocument.contents.location === "Null" |
867 | @@ -256,14 +251,24 @@ |
868 | } |
869 | } |
870 | |
871 | + Rectangle { |
872 | + id: divider |
873 | + width: parent.width |
874 | + height: 1 |
875 | + color: "#cdcdcd" |
876 | + anchors { |
877 | + top: locationRow.bottom |
878 | + topMargin: units.gu(3) |
879 | + } |
880 | + } |
881 | + |
882 | MouseArea { |
883 | id: worldCityListMouseArea |
884 | |
885 | preventStealing: true |
886 | |
887 | anchors { |
888 | - top: locationRow.bottom |
889 | - topMargin: units.gu(2) |
890 | + top: divider.bottom |
891 | bottom: parent.bottom |
892 | left: parent.left |
893 | right: parent.right |
894 | @@ -311,7 +316,7 @@ |
895 | target: date |
896 | property: "anchors.topMargin" |
897 | from: units.gu(29) |
898 | - to: units.gu(37) |
899 | + to: units.gu(4) |
900 | duration: 900 |
901 | } |
902 | } |
903 | |
904 | === modified file 'app/clock/MainClock.qml' |
905 | --- app/clock/MainClock.qml 2016-01-16 08:18:05 +0000 |
906 | +++ app/clock/MainClock.qml 2016-02-25 18:41:31 +0000 |
907 | @@ -26,13 +26,14 @@ |
908 | // Property to keep track of the cold start status of the app |
909 | property bool isColdStart: true |
910 | |
911 | - fontSize: units.dp(62) |
912 | + fontSize: units.dp(44) |
913 | periodFontSize: units.dp(12) |
914 | - innerCircleWidth: units.gu(23) |
915 | + innerCircleWidth: units.gu(24) |
916 | |
917 | isMainClock: true |
918 | |
919 | isDigital: clockModeDocument.contents.digitalMode ? true : false |
920 | + height: width |
921 | |
922 | Component.onCompleted: { |
923 | clockOpenAnimation.start() |
924 | @@ -58,7 +59,7 @@ |
925 | { |
926 | "maxWidth": innerCircleWidth, |
927 | "maxTimeFontSize": fontSize, |
928 | - "maxPeriodFontSize": periodFontSize, |
929 | + "maxPeriodFontSize": periodFontSize |
930 | }) |
931 | } |
932 | else { |
933 | @@ -76,7 +77,7 @@ |
934 | UbuntuNumberAnimation { |
935 | target: mainClock |
936 | property: "width" |
937 | - to: units.gu(32) |
938 | + to: units.gu(24) |
939 | duration: 900 |
940 | } |
941 | |
942 | |
943 | === modified file 'app/components/ActionIcon.qml' |
944 | --- app/components/ActionIcon.qml 2015-10-22 16:49:23 +0000 |
945 | +++ app/components/ActionIcon.qml 2016-02-25 18:41:31 +0000 |
946 | @@ -25,8 +25,9 @@ |
947 | property alias iconName: _icon.name |
948 | property alias iconSource: _icon.source |
949 | property alias iconWidth: _icon.width |
950 | + property alias iconColor: _icon.color |
951 | |
952 | - width: units.gu(5) |
953 | + width: units.gu(4) |
954 | height: width |
955 | |
956 | Rectangle { |
957 | @@ -37,9 +38,9 @@ |
958 | |
959 | Icon { |
960 | id: _icon |
961 | - width: units.gu(3) |
962 | + width: units.gu(2) |
963 | height: width |
964 | anchors.centerIn: parent |
965 | - color: "#5B5B5B" |
966 | + color: "#5d5d5d" |
967 | } |
968 | } |
969 | |
970 | === modified file 'app/components/AnalogMode.qml' |
971 | --- app/components/AnalogMode.qml 2016-01-16 08:18:05 +0000 |
972 | +++ app/components/AnalogMode.qml 2016-02-25 18:41:31 +0000 |
973 | @@ -34,9 +34,28 @@ |
974 | _innerCircleAnimation.start() |
975 | } |
976 | |
977 | + isFoldVisible: isMainClock |
978 | width: units.gu(0) |
979 | |
980 | Image { |
981 | + id: hourHandShadow |
982 | + |
983 | + z: minuteHand.z + 1 |
984 | + width: parent.width |
985 | + anchors.centerIn: parent |
986 | + anchors.verticalCenterOffset: showSeconds ? units.dp(2) : units.dp(1) |
987 | + |
988 | + source: "../graphics/Hour_Hand_Shadow.png" |
989 | + fillMode: Image.PreserveAspectFit |
990 | + // notLocalizedDateTimeString.split(":")[3] is hours |
991 | + // notLocalizedDateTimeString.split(":")[4] is minutes |
992 | + // We need to calculate degree number for rotation (0 degrees means no rotation). |
993 | + // Full rotate has 360 degrees and we have 12 hours in clock face, |
994 | + // For hours: 360deg/12h=30 deg/h, for minutes 30deg/60min= 0.5 deg/min |
995 | + rotation: (parseInt(notLocalizedDateTimeString.split(":")[3]) * 30) + (parseInt(notLocalizedDateTimeString.split(":")[4]) * 0.5) |
996 | + } |
997 | + |
998 | + Image { |
999 | id: hourHand |
1000 | |
1001 | z: minuteHand.z + 1 |
1002 | @@ -55,6 +74,23 @@ |
1003 | } |
1004 | |
1005 | Image { |
1006 | + id: minuteHandShadow |
1007 | + |
1008 | + width: parent.width |
1009 | + anchors.centerIn: parent |
1010 | + anchors.verticalCenterOffset: showSeconds ? units.dp(2) : units.dp(1) |
1011 | + |
1012 | + source: "../graphics/Minute_Hand_Shadow.png" |
1013 | + fillMode: Image.PreserveAspectFit |
1014 | + // notLocalizedDateTimeString.split(":")[4] is minutes |
1015 | + // notLocalizedDateTimeString.split(":")[5] is seconds |
1016 | + // We need to calculate degree number for rotation (0 degrees means no rotation). |
1017 | + // Full rotate has 360 degrees and we have 60 miutes in clock face, |
1018 | + // For minutes: 360deg/60min=6 deg/min, for seconds 6deg/60sec= 0.1 deg/sec |
1019 | + rotation: (parseInt(notLocalizedDateTimeString.split(":")[4]) * 6) + (parseInt(notLocalizedDateTimeString.split(":")[5]) * 0.1) |
1020 | + } |
1021 | + |
1022 | + Image { |
1023 | id: minuteHand |
1024 | |
1025 | width: parent.width |
1026 | @@ -72,6 +108,23 @@ |
1027 | } |
1028 | |
1029 | Image { |
1030 | + id: secondHandShadow |
1031 | + |
1032 | + anchors.centerIn: parent |
1033 | + width: parent.width + units.gu(2) |
1034 | + anchors.verticalCenterOffset: units.dp(2) |
1035 | + |
1036 | + visible: showSeconds |
1037 | + source: "../graphics/Second_Hand_Shadow.png" |
1038 | + fillMode: Image.PreserveAspectFit |
1039 | + // notLocalizedDateTimeString.split(":")[5] is seconds |
1040 | + // We need to calculate degree number for rotation (0 degrees means no rotation). |
1041 | + // Full rotate has 360 degrees and we have 60 seconds in clock face, |
1042 | + // For seconds 360deg/60sec= 6 deg/sec |
1043 | + rotation: visible ? parseInt(notLocalizedDateTimeString.split(":")[5]) * 6 : 0 |
1044 | + } |
1045 | + |
1046 | + Image { |
1047 | id: secondHand |
1048 | |
1049 | anchors.centerIn: parent |
1050 | |
1051 | === removed file 'app/components/Background.qml' |
1052 | --- app/components/Background.qml 2015-10-22 16:49:23 +0000 |
1053 | +++ app/components/Background.qml 1970-01-01 00:00:00 +0000 |
1054 | @@ -1,32 +0,0 @@ |
1055 | -/* |
1056 | - * Copyright (C) 2014-2015 Canonical Ltd |
1057 | - * |
1058 | - * This file is part of Ubuntu Clock App |
1059 | - * |
1060 | - * Ubuntu Clock App is free software: you can redistribute it and/or modify |
1061 | - * it under the terms of the GNU General Public License version 3 as |
1062 | - * published by the Free Software Foundation. |
1063 | - * |
1064 | - * Ubuntu Clock App is distributed in the hope that it will be useful, |
1065 | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
1066 | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
1067 | - * GNU General Public License for more details. |
1068 | - * |
1069 | - * You should have received a copy of the GNU General Public License |
1070 | - * along with this program. If not, see <http://www.gnu.org/licenses/>. |
1071 | - */ |
1072 | - |
1073 | -import QtQuick 2.4 |
1074 | -import Ubuntu.Components 1.3 |
1075 | - |
1076 | -/* |
1077 | - Component to set the background of the app |
1078 | - */ |
1079 | - |
1080 | -Image { |
1081 | - id: _background |
1082 | - |
1083 | - asynchronous: true |
1084 | - anchors.fill: parent |
1085 | - source: "../graphics/Background_Texture.jpg" |
1086 | -} |
1087 | |
1088 | === modified file 'app/components/CMakeLists.txt' |
1089 | --- app/components/CMakeLists.txt 2016-01-19 12:47:55 +0000 |
1090 | +++ app/components/CMakeLists.txt 2016-02-25 18:41:31 +0000 |
1091 | @@ -2,7 +2,6 @@ |
1092 | ActionIcon.qml |
1093 | AnalogMode.qml |
1094 | AnalogShadow.qml |
1095 | - Background.qml |
1096 | Circle.qml |
1097 | Clock.qml |
1098 | ClockCircle.qml |
1099 | @@ -12,7 +11,6 @@ |
1100 | ExpandableListItem.qml |
1101 | HeaderNavigation.qml |
1102 | Shadow.qml |
1103 | - SubtitledListItem.qml |
1104 | ) |
1105 | |
1106 | # make the files visible in the qtcreator tree |
1107 | |
1108 | === modified file 'app/components/Clock.qml' |
1109 | --- app/components/Clock.qml 2015-10-22 16:49:23 +0000 |
1110 | +++ app/components/Clock.qml 2016-02-25 18:41:31 +0000 |
1111 | @@ -38,8 +38,8 @@ |
1112 | - Disable the clock hand in the child elements (world clock) as per the design |
1113 | spec. |
1114 | */ |
1115 | -ClockCircle { |
1116 | - id: _outerCircle |
1117 | +Item { |
1118 | + id: _clockContainer |
1119 | |
1120 | // String with not localized date and time in format "yyyy:MM:dd:hh:mm:ss", eg.: "2015:10:05:16:10:15" |
1121 | property string notLocalizedDateTimeString |
1122 | @@ -72,9 +72,6 @@ |
1123 | clockFlipAnimation.start() |
1124 | } |
1125 | |
1126 | - // Sets the style to outer circle |
1127 | - isOuter: true |
1128 | - |
1129 | Shadow { |
1130 | id: upperShadow |
1131 | rotation: 0 |
1132 | |
1133 | === modified file 'app/components/ClockCircle.qml' |
1134 | --- app/components/ClockCircle.qml 2016-01-16 08:35:09 +0000 |
1135 | +++ app/components/ClockCircle.qml 2016-02-25 18:41:31 +0000 |
1136 | @@ -23,38 +23,29 @@ |
1137 | /* |
1138 | Clock Circle with the shadows and background color set depending on the |
1139 | position of the circle. |
1140 | - |
1141 | - If used as the outer circle, the shadows are at the top and the background |
1142 | - has a 30% white shade. On the other hand, if used as the inner clock circle |
1143 | - then the shadows are at the bottom and the background has a 3% darker shade. |
1144 | - |
1145 | - If used as the inner circle, a textured background image is set as part of |
1146 | - the new design specs. |
1147 | - |
1148 | - The circle position is set by the public property "isOuter". If true, the |
1149 | - outer circle characteristics are set and vice-versa. |
1150 | */ |
1151 | Circle { |
1152 | id: _innerCircle |
1153 | |
1154 | - /* |
1155 | - Property to set if the circle is the outer or the inner circle |
1156 | - */ |
1157 | - property bool isOuter: false |
1158 | + property bool isFoldVisible: true |
1159 | |
1160 | - color: isOuter ? "#4DFFFFFF" : "#08000000" |
1161 | - borderWidth: units.gu(0.2) |
1162 | - borderColorTop: isOuter ? "#6E6E6E" : "#00000000" |
1163 | - borderColorBottom: isOuter ? "#00000000" : "#6E6E6E" |
1164 | + color: "#f7f7f7" |
1165 | + borderWidth: units.dp(1) |
1166 | + borderColorTop: "#00000000" |
1167 | + borderColorBottom: "#6E6E6E" |
1168 | borderOpacity: 0.65 |
1169 | - borderGradientPosition: isOuter ? 0.7 : 0.2 |
1170 | + borderGradientPosition: 0.2 |
1171 | |
1172 | - Image { |
1173 | + Rectangle { |
1174 | + visible: isFoldVisible |
1175 | anchors.fill: parent |
1176 | - anchors.margins: borderWidth / 2.0 |
1177 | - smooth: true |
1178 | - fillMode: Image.PreserveAspectFit |
1179 | - source: !isOuter ? "../graphics/Inner_Clock_Texture.png" : "" |
1180 | - cache: false |
1181 | + anchors.margins: borderWidth |
1182 | + radius: height / 2 |
1183 | + gradient: Gradient { |
1184 | + GradientStop { position: 0.0; color: "#f7f7f7" } |
1185 | + GradientStop { position: 0.5; color: "#f7f7f7" } |
1186 | + GradientStop { position: 0.5; color: "#fdfdfd" } |
1187 | + GradientStop { position: 1.0; color: "#fdfdfd" } |
1188 | + } |
1189 | } |
1190 | } |
1191 | |
1192 | === modified file 'app/components/DigitalMode.qml' |
1193 | --- app/components/DigitalMode.qml 2016-01-16 08:18:05 +0000 |
1194 | +++ app/components/DigitalMode.qml 2016-02-25 18:41:31 +0000 |
1195 | @@ -41,14 +41,15 @@ |
1196 | } |
1197 | |
1198 | width: maxWidth |
1199 | + isFoldVisible: isMainClock |
1200 | |
1201 | Label { |
1202 | id: _digitalTime |
1203 | |
1204 | anchors.centerIn: parent |
1205 | |
1206 | - color: UbuntuColors.midAubergine |
1207 | font.pixelSize: maxTimeFontSize |
1208 | + |
1209 | text: { |
1210 | if (localizedTimeString.search(Qt.locale().amText) !== -1) { |
1211 | // 12 hour format detected with the localised AM text |
1212 | @@ -71,7 +72,6 @@ |
1213 | anchors.top: _digitalTime.bottom |
1214 | anchors.horizontalCenter: parent.horizontalCenter |
1215 | |
1216 | - color: UbuntuColors.midAubergine |
1217 | font.pixelSize: maxPeriodFontSize |
1218 | visible: text !== "" |
1219 | text: { |
1220 | |
1221 | === modified file 'app/components/EmptyState.qml' |
1222 | --- app/components/EmptyState.qml 2015-10-22 16:49:23 +0000 |
1223 | +++ app/components/EmptyState.qml 2016-02-25 18:41:31 +0000 |
1224 | @@ -44,7 +44,7 @@ |
1225 | |
1226 | Label { |
1227 | id: emptyLabel |
1228 | - fontSize: "large" |
1229 | + textSize: Label.Large |
1230 | font.bold: true |
1231 | width: parent.width |
1232 | wrapMode: Text.WordWrap |
1233 | |
1234 | === modified file 'app/components/ExpandableListItem.qml' |
1235 | --- app/components/ExpandableListItem.qml 2015-10-22 16:49:23 +0000 |
1236 | +++ app/components/ExpandableListItem.qml 2016-02-25 18:41:31 +0000 |
1237 | @@ -18,7 +18,6 @@ |
1238 | |
1239 | import QtQuick 2.4 |
1240 | import Ubuntu.Components 1.3 |
1241 | -import Ubuntu.Components.ListItems 1.3 as ListItem |
1242 | |
1243 | /* |
1244 | Component which extends the SDK Expandable list item and provides a easy |
1245 | @@ -26,24 +25,19 @@ |
1246 | matches the design specification provided for clock. |
1247 | */ |
1248 | |
1249 | -ListItem.Expandable { |
1250 | +ListItem { |
1251 | id: expandableListItem |
1252 | |
1253 | // Public APIs |
1254 | property ListModel model |
1255 | property Component delegate |
1256 | - property alias text: expandableHeader.text |
1257 | - property alias subText: expandableHeader.subText |
1258 | + property alias titleText: expandableHeader.title |
1259 | + property alias subText: expandableHeader.subtitle |
1260 | property alias listViewHeight: expandableList.height |
1261 | |
1262 | - anchors { |
1263 | - left: parent.left |
1264 | - right: parent.right |
1265 | - margins: units.gu(-2) |
1266 | - } |
1267 | - |
1268 | - collapseOnClick: true |
1269 | - expandedHeight: contentColumn.height |
1270 | + height: expandableHeader.height + divider.height |
1271 | + expansion.height: contentColumn.height |
1272 | + onClicked: expansion.expanded = !expansion.expanded |
1273 | |
1274 | Column { |
1275 | id: contentColumn |
1276 | @@ -53,26 +47,25 @@ |
1277 | right: parent.right |
1278 | } |
1279 | |
1280 | - SubtitledListItem { |
1281 | - id: expandableHeader |
1282 | - height: expandableListItem.collapsedHeight |
1283 | - onClicked: expandableListItem.expanded = true |
1284 | - |
1285 | - Icon { |
1286 | - id: arrow |
1287 | - |
1288 | - width: units.gu(2) |
1289 | - height: width |
1290 | - anchors.right: parent.right |
1291 | - anchors.rightMargin: units.gu(2) |
1292 | - anchors.verticalCenter: parent.verticalCenter |
1293 | - |
1294 | - name: "go-down" |
1295 | - color: "Grey" |
1296 | - rotation: expandableListItem.expanded ? 180 : 0 |
1297 | - |
1298 | - Behavior on rotation { |
1299 | - UbuntuNumberAnimation {} |
1300 | + ListItem { |
1301 | + height: expandableHeader.height + divider.height |
1302 | + ListItemLayout { |
1303 | + id: expandableHeader |
1304 | + |
1305 | + Icon { |
1306 | + id: arrow |
1307 | + |
1308 | + width: units.gu(2) |
1309 | + height: width |
1310 | + SlotsLayout.position: SlotsLayout.Trailing |
1311 | + SlotsLayout.overrideVerticalPositioning: true |
1312 | + anchors.verticalCenter: parent.verticalCenter |
1313 | + name: "go-down" |
1314 | + rotation: expandableListItem.expansion.expanded ? 180 : 0 |
1315 | + |
1316 | + Behavior on rotation { |
1317 | + UbuntuNumberAnimation {} |
1318 | + } |
1319 | } |
1320 | } |
1321 | } |
1322 | |
1323 | === modified file 'app/components/HeaderNavigation.qml' |
1324 | --- app/components/HeaderNavigation.qml 2015-10-22 16:49:23 +0000 |
1325 | +++ app/components/HeaderNavigation.qml 2016-02-25 18:41:31 +0000 |
1326 | @@ -22,51 +22,28 @@ |
1327 | Item { |
1328 | id: headerRow |
1329 | |
1330 | - height: units.gu(7) |
1331 | + height: units.gu(6) |
1332 | |
1333 | Row { |
1334 | id: iconContainer |
1335 | |
1336 | anchors.centerIn: parent |
1337 | + spacing: units.gu(2) |
1338 | |
1339 | ActionIcon { |
1340 | - width: units.gu(5.5) |
1341 | - height: units.gu(4) |
1342 | - iconWidth: units.gu(4) |
1343 | - iconSource: Qt.resolvedUrl("../graphics/WorldClock_Placeholder.svg") |
1344 | + iconName: "clock" |
1345 | + iconColor: listview.currentIndex == 0 ? "#19b6ee" : "#5d5d5d" |
1346 | onClicked: listview.currentIndex = 0 |
1347 | } |
1348 | |
1349 | ActionIcon { |
1350 | - width: units.gu(5.5) |
1351 | - height: units.gu(4) |
1352 | - iconWidth: units.gu(4) |
1353 | - iconSource: Qt.resolvedUrl("../graphics/Stopwatch_Placeholder.svg") |
1354 | + iconName: "stopwatch" |
1355 | + iconColor: listview.currentIndex == 1 ? "#19b6ee" : "#5d5d5d" |
1356 | onClicked: listview.currentIndex = 1 |
1357 | } |
1358 | } |
1359 | |
1360 | - Rectangle { |
1361 | - id: outerProgressRectangle |
1362 | - anchors { |
1363 | - left: iconContainer.left |
1364 | - right: iconContainer.right |
1365 | - top: iconContainer.bottom |
1366 | - } |
1367 | - height: units.gu(0.3) |
1368 | - color: UbuntuColors.lightGrey |
1369 | - |
1370 | - Rectangle { |
1371 | - height: parent.height |
1372 | - x: listview.currentIndex == 0 ? 0 : parent.width - width |
1373 | - width: units.gu(5.5) |
1374 | - color: UbuntuColors.orange |
1375 | - Behavior on x { |
1376 | - UbuntuNumberAnimation {} |
1377 | - } |
1378 | - } |
1379 | - } |
1380 | - |
1381 | + |
1382 | ActionIcon { |
1383 | id: settingsIcon |
1384 | objectName: "settingsIcon" |
1385 | @@ -74,7 +51,7 @@ |
1386 | anchors { |
1387 | verticalCenter: parent.verticalCenter |
1388 | right: parent.right |
1389 | - rightMargin: units.gu(2) |
1390 | + rightMargin: units.gu(1) |
1391 | } |
1392 | |
1393 | iconName: "settings" |
1394 | |
1395 | === removed file 'app/components/SubtitledListItem.qml' |
1396 | --- app/components/SubtitledListItem.qml 2015-10-22 16:49:23 +0000 |
1397 | +++ app/components/SubtitledListItem.qml 1970-01-01 00:00:00 +0000 |
1398 | @@ -1,59 +0,0 @@ |
1399 | -/* |
1400 | - * Copyright (C) 2014-2015 Canonical Ltd |
1401 | - * |
1402 | - * This file is part of Ubuntu Clock App |
1403 | - * |
1404 | - * Ubuntu Clock App is free software: you can redistribute it and/or modify |
1405 | - * it under the terms of the GNU General Public License version 3 as |
1406 | - * published by the Free Software Foundation. |
1407 | - * |
1408 | - * Ubuntu Clock App is distributed in the hope that it will be useful, |
1409 | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
1410 | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
1411 | - * GNU General Public License for more details. |
1412 | - * |
1413 | - * You should have received a copy of the GNU General Public License |
1414 | - * along with this program. If not, see <http://www.gnu.org/licenses/>. |
1415 | - */ |
1416 | - |
1417 | -import QtQuick 2.4 |
1418 | -import Ubuntu.Components 1.3 |
1419 | - |
1420 | -/* |
1421 | - This component is almost an identical copy of the SDK's subtitled with the |
1422 | - exception of the font size and color required by the new clock app design. |
1423 | - |
1424 | - #TODO: Revert to using the SDK Subtitled Component when they change the |
1425 | - design to match the new clock app design. |
1426 | - */ |
1427 | -ListItem { |
1428 | - id: _subtitledContainer |
1429 | - |
1430 | - // Property to set the main text label |
1431 | - property alias text: _mainText.text |
1432 | - |
1433 | - // Property to set the subtitle label |
1434 | - property alias subText: _subText.text |
1435 | - |
1436 | - Column { |
1437 | - id: _labelColumn |
1438 | - |
1439 | - anchors { |
1440 | - left: parent.left |
1441 | - right: parent.right |
1442 | - margins: units.gu(2) |
1443 | - verticalCenter: parent.verticalCenter |
1444 | - } |
1445 | - |
1446 | - Label { |
1447 | - id: _mainText |
1448 | - fontSize: "medium" |
1449 | - color: UbuntuColors.midAubergine |
1450 | - } |
1451 | - |
1452 | - Label { |
1453 | - id: _subText |
1454 | - fontSize: "xx-small" |
1455 | - } |
1456 | - } |
1457 | -} |
1458 | |
1459 | === removed file 'app/graphics/Background_Texture.jpg' |
1460 | Binary files app/graphics/Background_Texture.jpg 2014-06-19 14:52:15 +0000 and app/graphics/Background_Texture.jpg 1970-01-01 00:00:00 +0000 differ |
1461 | === modified file 'app/graphics/CMakeLists.txt' |
1462 | --- app/graphics/CMakeLists.txt 2016-01-19 12:47:55 +0000 |
1463 | +++ app/graphics/CMakeLists.txt 2016-02-25 18:41:31 +0000 |
1464 | @@ -1,14 +1,14 @@ |
1465 | set(GRAPHICS_FILES |
1466 | - Background_Texture.jpg |
1467 | Hour_Hand@27.png |
1468 | + Hour_Hand_Shadow@27.png |
1469 | Inner_Clock_Texture@27.png |
1470 | Knob@27.png |
1471 | Minute_Hand@27.png |
1472 | + Minute_Hand_Shadow@27.png |
1473 | Second_Hand@27.png |
1474 | + Second_Hand_Shadow@27.png |
1475 | select-none.svg |
1476 | select.svg |
1477 | - Stopwatch_Placeholder.svg |
1478 | - WorldClock_Placeholder.svg |
1479 | ) |
1480 | |
1481 | # make the files visible in the qtcreator tree |
1482 | |
1483 | === modified file 'app/graphics/Hour_Hand@27.png' |
1484 | Binary files app/graphics/Hour_Hand@27.png 2015-09-04 22:16:01 +0000 and app/graphics/Hour_Hand@27.png 2016-02-25 18:41:31 +0000 differ |
1485 | === added file 'app/graphics/Hour_Hand@27.xcf' |
1486 | Binary files app/graphics/Hour_Hand@27.xcf 1970-01-01 00:00:00 +0000 and app/graphics/Hour_Hand@27.xcf 2016-02-25 18:41:31 +0000 differ |
1487 | === added file 'app/graphics/Hour_Hand_Shadow@27.png' |
1488 | Binary files app/graphics/Hour_Hand_Shadow@27.png 1970-01-01 00:00:00 +0000 and app/graphics/Hour_Hand_Shadow@27.png 2016-02-25 18:41:31 +0000 differ |
1489 | === added file 'app/graphics/Hour_Hand_Shadow@27.xcf' |
1490 | Binary files app/graphics/Hour_Hand_Shadow@27.xcf 1970-01-01 00:00:00 +0000 and app/graphics/Hour_Hand_Shadow@27.xcf 2016-02-25 18:41:31 +0000 differ |
1491 | === modified file 'app/graphics/Inner_Clock_Texture@27.png' |
1492 | Binary files app/graphics/Inner_Clock_Texture@27.png 2016-01-16 08:18:05 +0000 and app/graphics/Inner_Clock_Texture@27.png 2016-02-25 18:41:31 +0000 differ |
1493 | === modified file 'app/graphics/Knob@27.png' |
1494 | Binary files app/graphics/Knob@27.png 2015-09-04 22:16:01 +0000 and app/graphics/Knob@27.png 2016-02-25 18:41:31 +0000 differ |
1495 | === added file 'app/graphics/Knob@27.xcf' |
1496 | Binary files app/graphics/Knob@27.xcf 1970-01-01 00:00:00 +0000 and app/graphics/Knob@27.xcf 2016-02-25 18:41:31 +0000 differ |
1497 | === modified file 'app/graphics/Minute_Hand@27.png' |
1498 | Binary files app/graphics/Minute_Hand@27.png 2015-09-04 22:16:01 +0000 and app/graphics/Minute_Hand@27.png 2016-02-25 18:41:31 +0000 differ |
1499 | === added file 'app/graphics/Minute_Hand@27.xcf' |
1500 | Binary files app/graphics/Minute_Hand@27.xcf 1970-01-01 00:00:00 +0000 and app/graphics/Minute_Hand@27.xcf 2016-02-25 18:41:31 +0000 differ |
1501 | === added file 'app/graphics/Minute_Hand_Shadow@27.png' |
1502 | Binary files app/graphics/Minute_Hand_Shadow@27.png 1970-01-01 00:00:00 +0000 and app/graphics/Minute_Hand_Shadow@27.png 2016-02-25 18:41:31 +0000 differ |
1503 | === added file 'app/graphics/Minute_Hand_Shadow@27.xcf' |
1504 | Binary files app/graphics/Minute_Hand_Shadow@27.xcf 1970-01-01 00:00:00 +0000 and app/graphics/Minute_Hand_Shadow@27.xcf 2016-02-25 18:41:31 +0000 differ |
1505 | === modified file 'app/graphics/Second_Hand@27.png' |
1506 | Binary files app/graphics/Second_Hand@27.png 2015-09-04 22:16:01 +0000 and app/graphics/Second_Hand@27.png 2016-02-25 18:41:31 +0000 differ |
1507 | === added file 'app/graphics/Second_Hand@27.xcf' |
1508 | Binary files app/graphics/Second_Hand@27.xcf 1970-01-01 00:00:00 +0000 and app/graphics/Second_Hand@27.xcf 2016-02-25 18:41:31 +0000 differ |
1509 | === added file 'app/graphics/Second_Hand_Shadow@27.png' |
1510 | Binary files app/graphics/Second_Hand_Shadow@27.png 1970-01-01 00:00:00 +0000 and app/graphics/Second_Hand_Shadow@27.png 2016-02-25 18:41:31 +0000 differ |
1511 | === added file 'app/graphics/Second_Hand_Shadow@27.xcf' |
1512 | Binary files app/graphics/Second_Hand_Shadow@27.xcf 1970-01-01 00:00:00 +0000 and app/graphics/Second_Hand_Shadow@27.xcf 2016-02-25 18:41:31 +0000 differ |
1513 | === removed file 'app/graphics/Stopwatch_Placeholder.svg' |
1514 | --- app/graphics/Stopwatch_Placeholder.svg 2015-09-17 02:36:35 +0000 |
1515 | +++ app/graphics/Stopwatch_Placeholder.svg 1970-01-01 00:00:00 +0000 |
1516 | @@ -1,19 +0,0 @@ |
1517 | -<?xml version="1.0" encoding="UTF-8" standalone="no"?> |
1518 | -<svg width="100px" height="100px" viewBox="0 0 100 100" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns"> |
1519 | - <!-- Generator: Sketch 3.3.3 (12072) - http://www.bohemiancoding.com/sketch --> |
1520 | - <title>Placeholder Icons</title> |
1521 | - <desc>Created with Sketch.</desc> |
1522 | - <defs></defs> |
1523 | - <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage"> |
1524 | - <g id="Placeholder-Icons" sketch:type="MSArtboardGroup" stroke="#5B5B5B"> |
1525 | - <g id="Timer-+-Stopwatch-+-Clock-icon" sketch:type="MSLayerGroup" transform="translate(19.000000, 17.000000)"> |
1526 | - <g id="Stopwatch" transform="translate(3.000000, 0.000000)" sketch:type="MSShapeGroup"> |
1527 | - <circle id="Oval-125-Copy" stroke-width="3" cx="28.5" cy="37.5" r="28.5"></circle> |
1528 | - <path d="M22,1 L34.0300293,1.00149091" id="Line-Copy-3" stroke-width="5" stroke-linecap="square"></path> |
1529 | - <path d="M26,6 L30.0300293,6.00149091" id="Line-Copy-4" stroke-width="5" stroke-linecap="square"></path> |
1530 | - <path d="M34.6896914,37.7022985 L34.6896914,22.495895" id="Line-Copy-5" stroke-width="3" stroke-linecap="square" transform="translate(34.689691, 30.099097) rotate(-315.000000) translate(-34.689691, -30.099097) "></path> |
1531 | - </g> |
1532 | - </g> |
1533 | - </g> |
1534 | - </g> |
1535 | -</svg> |
1536 | \ No newline at end of file |
1537 | |
1538 | === removed file 'app/graphics/WorldClock_Placeholder.svg' |
1539 | --- app/graphics/WorldClock_Placeholder.svg 2015-09-17 02:36:35 +0000 |
1540 | +++ app/graphics/WorldClock_Placeholder.svg 1970-01-01 00:00:00 +0000 |
1541 | @@ -1,21 +0,0 @@ |
1542 | -<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns" width="100px" height="100px" viewBox="0 0 100 100" version="1.1"> |
1543 | - <!-- Generator: Sketch 3.3.3 (12072) - http://www.bohemiancoding.com/sketch --> |
1544 | - <title>Placeholder Icons</title> |
1545 | - <desc>Created with Sketch.</desc> |
1546 | - <defs/> |
1547 | - <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage"> |
1548 | - <g id="Placeholder-Icons" sketch:type="MSArtboardGroup"> |
1549 | - <g id="Timer-+-Stopwatch-+-Clock-icon" sketch:type="MSLayerGroup" transform="translate(19.000000, 17.000000)"> |
1550 | - <g id="Clock-icon" transform="translate(0.000000, 5.000000)" sketch:type="MSShapeGroup"> |
1551 | - <path d="M19.7838596 0 C2.47304842 0 0 2.5 0 19.9 L0 37.1 C0 54.5 2.5 57 19.8 57 L41.2161404 57 C58.5269504 57 61 54.5 61 37.1 L61 19.9 C61 2.5 58.5 0 41.2 0 L19.7838596 0 L19.7838596 0 Z" id="rect4158" stroke="#5B5B5B" stroke-width="3"/> |
1552 | - <g id="Hands" transform="translate(17.632812, 16.884454)"> |
1553 | - <path d="M0.026502832 4.2 L12.8671875 11.6" id="path4219" stroke="#5B5B5B" stroke-width="3"/> |
1554 | - <path d="M12.8671875 11.6 L32.7118814 0.1" id="path4231" stroke="#5B5B5B" stroke-width="2"/> |
1555 | - <ellipse id="path4221" fill="#5B5B5B" cx="12.9" cy="10.6" rx="4.4" ry="4.4"/> |
1556 | - <path d="M12.5 11.1 L12.5 31.7" id="path4223" stroke="#5B5B5B"/> |
1557 | - </g> |
1558 | - </g> |
1559 | - </g> |
1560 | - </g> |
1561 | - </g> |
1562 | -</svg> |
1563 | |
1564 | === modified file 'app/stopwatch/LapListView.qml' |
1565 | --- app/stopwatch/LapListView.qml 2015-10-22 16:49:23 +0000 |
1566 | +++ app/stopwatch/LapListView.qml 2016-02-25 18:41:31 +0000 |
1567 | @@ -32,38 +32,38 @@ |
1568 | |
1569 | header: ListItem { |
1570 | visible: count !== 0 |
1571 | + width: parent.width - units.gu(4) |
1572 | + anchors.horizontalCenter: parent.horizontalCenter |
1573 | + |
1574 | Row { |
1575 | anchors { |
1576 | left: parent.left |
1577 | right: parent.right |
1578 | verticalCenter: parent.verticalCenter |
1579 | - margins: units.gu(2) |
1580 | + margins: units.gu(1) |
1581 | } |
1582 | |
1583 | Label { |
1584 | // #TRANSLATORS: This refers to the stopwatch lap and is shown as a header where space is limited. Constrain |
1585 | // translation length to a few characters. |
1586 | text: i18n.tr("Lap") |
1587 | - width: parent.width / 7 |
1588 | + width: parent.width / 5 |
1589 | elide: Text.ElideRight |
1590 | - font.weight: Font.DemiBold |
1591 | - horizontalAlignment: Text.AlignHCenter |
1592 | + horizontalAlignment: Text.AlignLeft |
1593 | } |
1594 | |
1595 | Label { |
1596 | - width: 3 * parent.width / 7 |
1597 | + width: 2 * parent.width / 5 |
1598 | elide: Text.ElideRight |
1599 | text: i18n.tr("Lap Time") |
1600 | - font.weight: Font.DemiBold |
1601 | horizontalAlignment: Text.AlignHCenter |
1602 | } |
1603 | |
1604 | Label { |
1605 | - width: 3 * parent.width / 7 |
1606 | + width: 2 * parent.width / 5 |
1607 | elide: Text.ElideRight |
1608 | text: i18n.tr("Total Time") |
1609 | - font.weight: Font.DemiBold |
1610 | - horizontalAlignment: Text.AlignHCenter |
1611 | + horizontalAlignment: Text.AlignRight |
1612 | } |
1613 | } |
1614 | } |
1615 | @@ -77,6 +77,9 @@ |
1616 | |
1617 | delegate: ListItem { |
1618 | divider.visible: true |
1619 | + width: parent.width - units.gu(4) |
1620 | + anchors.horizontalCenter: parent.horizontalCenter |
1621 | + |
1622 | leadingActions: ListItemActions { |
1623 | actions: [ |
1624 | Action { |
1625 | @@ -93,18 +96,17 @@ |
1626 | left: parent.left |
1627 | right: parent.right |
1628 | verticalCenter: parent.verticalCenter |
1629 | - margins: units.gu(2) |
1630 | + leftMargin: units.gu(1) |
1631 | } |
1632 | |
1633 | Label { |
1634 | - color: UbuntuColors.midAubergine |
1635 | text: "#%1".arg(Number(count - index).toLocaleString(Qt.locale(), "f", 0)) |
1636 | - width: parent.width / 7 |
1637 | - horizontalAlignment: Text.AlignHCenter |
1638 | + width: parent.width / 5 |
1639 | + horizontalAlignment: Text.AlignLeft |
1640 | } |
1641 | |
1642 | Item { |
1643 | - width: 3 * parent.width / 7 |
1644 | + width: 2* parent.width / 5 |
1645 | height: childrenRect.height |
1646 | Row { |
1647 | anchors.horizontalCenter: parent.horizontalCenter |
1648 | @@ -112,27 +114,21 @@ |
1649 | text: stopwatchFormatTime.lapTimeToString(model.laptime) + "." |
1650 | } |
1651 | Label { |
1652 | - fontSize: "x-small" |
1653 | text: stopwatchFormatTime.millisToString(model.laptime) |
1654 | - anchors.bottom: parent.bottom |
1655 | - anchors.bottomMargin: units.dp(1) |
1656 | } |
1657 | } |
1658 | } |
1659 | |
1660 | Item { |
1661 | - width: 3 * parent.width / 7 |
1662 | + width: 2 * parent.width / 5 |
1663 | height: childrenRect.height |
1664 | Row { |
1665 | - anchors.horizontalCenter: parent.horizontalCenter |
1666 | + anchors.right: parent.right |
1667 | Label { |
1668 | text: stopwatchFormatTime.lapTimeToString(model.totaltime) + "." |
1669 | } |
1670 | Label { |
1671 | - fontSize: "x-small" |
1672 | text: stopwatchFormatTime.millisToString(model.totaltime) |
1673 | - anchors.bottom: parent.bottom |
1674 | - anchors.bottomMargin: units.dp(1) |
1675 | } |
1676 | } |
1677 | } |
1678 | |
1679 | === modified file 'app/stopwatch/StopwatchFace.qml' |
1680 | --- app/stopwatch/StopwatchFace.qml 2015-10-22 16:49:23 +0000 |
1681 | +++ app/stopwatch/StopwatchFace.qml 2016-02-25 18:41:31 +0000 |
1682 | @@ -22,41 +22,35 @@ |
1683 | import "../components" |
1684 | |
1685 | ClockCircle { |
1686 | - id: outerCirle |
1687 | + id: stopwatchCircle |
1688 | |
1689 | // Property to hold the total time (in milliseconds) |
1690 | property int milliseconds: 0 |
1691 | |
1692 | - isOuter: true |
1693 | - width: units.gu(32) |
1694 | + width: units.gu(24) |
1695 | |
1696 | StopwatchFormatTime { |
1697 | id: stopwatchFormatTime |
1698 | } |
1699 | |
1700 | - ClockCircle { |
1701 | - id: innerCircle |
1702 | - |
1703 | - width: units.gu(23) |
1704 | - anchors.centerIn: parent |
1705 | - } |
1706 | - |
1707 | - Column { |
1708 | - id: text |
1709 | - |
1710 | - anchors.centerIn: parent |
1711 | - |
1712 | - Label { |
1713 | - text: stopwatchFormatTime.millisToTimeString(milliseconds, true) |
1714 | - font.pixelSize: units.dp(34) |
1715 | - color: UbuntuColors.midAubergine |
1716 | - } |
1717 | - |
1718 | - Label { |
1719 | - text: stopwatchFormatTime.millisToString(milliseconds) |
1720 | - font.pixelSize: units.dp(18) |
1721 | - color: UbuntuColors.midAubergine |
1722 | - anchors.horizontalCenter: parent.horizontalCenter |
1723 | - } |
1724 | - } |
1725 | + Label { |
1726 | + id: time |
1727 | + |
1728 | + text: stopwatchFormatTime.millisToTimeString(milliseconds, true) |
1729 | + font.pixelSize: units.dp(36) |
1730 | + anchors.centerIn: parent |
1731 | + } |
1732 | + |
1733 | + Label { |
1734 | + id: miliseconds |
1735 | + |
1736 | + text: stopwatchFormatTime.millisToString(milliseconds) |
1737 | + textSize: Label.Large |
1738 | + anchors { |
1739 | + top: time.bottom |
1740 | + topMargin: units.gu(1.5) |
1741 | + horizontalCenter: parent.horizontalCenter |
1742 | + } |
1743 | + } |
1744 | + |
1745 | } |
1746 | |
1747 | === modified file 'app/stopwatch/StopwatchPage.qml' |
1748 | --- app/stopwatch/StopwatchPage.qml 2015-10-22 16:49:23 +0000 |
1749 | +++ app/stopwatch/StopwatchPage.qml 2016-02-25 18:41:31 +0000 |
1750 | @@ -45,15 +45,26 @@ |
1751 | topMargin: units.gu(2) |
1752 | horizontalCenter: parent.horizontalCenter |
1753 | } |
1754 | + MouseArea { |
1755 | + anchors.fill: parent |
1756 | + onClicked: { |
1757 | + if (stopwatchEngine.running) { |
1758 | + stopwatchEngine.pauseStopwatch(); |
1759 | + } else { |
1760 | + stopwatchEngine.startStopwatch(); |
1761 | + } |
1762 | + } |
1763 | + } |
1764 | } |
1765 | |
1766 | - Row { |
1767 | + Item { |
1768 | id: buttonRow |
1769 | |
1770 | - spacing: units.gu(2) |
1771 | + width: parent.width - units.gu(4) |
1772 | + height: units.gu(4) |
1773 | anchors { |
1774 | top: stopwatch.bottom |
1775 | - topMargin: units.gu(3) |
1776 | + topMargin: units.gu(4) |
1777 | left: parent.left |
1778 | right: parent.right |
1779 | margins: units.gu(2) |
1780 | @@ -61,7 +72,10 @@ |
1781 | |
1782 | Button { |
1783 | id: stopButton |
1784 | - width: stopwatchEngine.previousTimeOfStopwatch !== 0 || stopwatchEngine.running ? (parent.width - parent.spacing) / 2 : parent.width |
1785 | + |
1786 | + width: parent.width / 2 - units.gu(1) |
1787 | + height: units.gu(4) |
1788 | + x: stopwatchEngine.previousTimeOfStopwatch !== 0 || stopwatchEngine.running ? 0 : (parent.width - width) / 2 |
1789 | color: !stopwatchEngine.running ? UbuntuColors.green : UbuntuColors.red |
1790 | text: stopwatchEngine.running ? i18n.tr("Stop") : (stopwatchEngine.previousTimeOfStopwatch === 0 ? i18n.tr("Start") : i18n.tr("Resume")) |
1791 | onClicked: { |
1792 | @@ -71,7 +85,7 @@ |
1793 | stopwatchEngine.startStopwatch(); |
1794 | } |
1795 | } |
1796 | - Behavior on width { |
1797 | + Behavior on x { |
1798 | UbuntuNumberAnimation{ |
1799 | duration: UbuntuAnimation.BriskDuration |
1800 | } |
1801 | @@ -80,9 +94,12 @@ |
1802 | |
1803 | Button { |
1804 | id: lapButton |
1805 | + |
1806 | text: stopwatchEngine.running ? i18n.tr("Lap") : i18n.tr("Clear") |
1807 | - width: stopwatchEngine.previousTimeOfStopwatch !== 0 || stopwatchEngine.running ? (parent.width - parent.spacing) / 2 : 0 |
1808 | - strokeColor: UbuntuColors.lightGrey |
1809 | + width: parent.width / 2 - units.gu(1) |
1810 | + height: units.gu(4) |
1811 | + x: stopwatchEngine.previousTimeOfStopwatch !== 0 || stopwatchEngine.running ? parent.width - width : parent.width |
1812 | + color: "#f7f7f7" |
1813 | visible: stopwatchEngine.previousTimeOfStopwatch !== 0 || stopwatchEngine.running |
1814 | onClicked: { |
1815 | if (stopwatchEngine.running) { |
1816 | @@ -91,7 +108,7 @@ |
1817 | stopwatchEngine.clearStopwatch() |
1818 | } |
1819 | } |
1820 | - Behavior on width { |
1821 | + Behavior on x { |
1822 | UbuntuNumberAnimation{ |
1823 | duration: UbuntuAnimation.BriskDuration |
1824 | } |
1825 | |
1826 | === modified file 'app/ubuntu-clock-app.qml' |
1827 | --- app/ubuntu-clock-app.qml 2015-10-22 16:49:23 +0000 |
1828 | +++ app/ubuntu-clock-app.qml 2016-02-25 18:41:31 +0000 |
1829 | @@ -49,12 +49,10 @@ |
1830 | width: units.gu(40) |
1831 | height: units.gu(70) |
1832 | |
1833 | - backgroundColor: "#F5F5F5" |
1834 | + backgroundColor: "#FFFFFF" |
1835 | |
1836 | anchorToKeyboard: true |
1837 | |
1838 | - Background {} |
1839 | - |
1840 | // Database to store the user preferences locally |
1841 | U1db.Database { |
1842 | id: clockDB |
1843 | @@ -119,14 +117,6 @@ |
1844 | } |
1845 | |
1846 | /* |
1847 | - #FIXME: When the SDK support hiding the header, then enable the |
1848 | - clock page title. This will then set the correct window title on |
1849 | - the desktop. |
1850 | - |
1851 | - title: i18n.tr("Clock") |
1852 | - */ |
1853 | - |
1854 | - /* |
1855 | Create a new Date() object and pass the date, month, year, hour, minute |
1856 | and second received from the DateTime plugin manually to ensure the |
1857 | timezone info is set correctly. |
1858 | |
1859 | === modified file 'app/upstreamcomponents/FastScroll.qml' |
1860 | --- app/upstreamcomponents/FastScroll.qml 2015-10-22 16:49:23 +0000 |
1861 | +++ app/upstreamcomponents/FastScroll.qml 2016-02-25 18:41:31 +0000 |
1862 | @@ -102,7 +102,7 @@ |
1863 | horizontalAlignment: Text.AlignHCenter |
1864 | verticalAlignment: Text.AlignVCenter |
1865 | text: internal.desireSection |
1866 | - fontSize: "small" |
1867 | + textSize: Label.Small |
1868 | } |
1869 | |
1870 | Behavior on opacity { |
1871 | @@ -179,7 +179,7 @@ |
1872 | verticalAlignment: Text.AlignVCenter |
1873 | horizontalAlignment: Text.AlignHCenter |
1874 | text: modelData |
1875 | - fontSize: "x-small" |
1876 | + textSize: Label.XSmall |
1877 | color: cursor.y === y ? "white" : Theme.palette.selected.backgroundText |
1878 | opacity: !internal.modelDirty && Sections.contains(text) ? 1.0 : 0.5 |
1879 | } |
1880 | |
1881 | === modified file 'app/worldclock/AddWorldCityButton.qml' |
1882 | --- app/worldclock/AddWorldCityButton.qml 2015-10-22 16:49:23 +0000 |
1883 | +++ app/worldclock/AddWorldCityButton.qml 2016-02-25 18:41:31 +0000 |
1884 | @@ -28,7 +28,6 @@ |
1885 | |
1886 | Label { |
1887 | text: i18n.tr("Add") |
1888 | - color: UbuntuColors.midAubergine |
1889 | anchors { |
1890 | right: _addButton.left |
1891 | rightMargin: units.gu(1) |
1892 | @@ -39,7 +38,7 @@ |
1893 | ClockCircle { |
1894 | id: _addButton |
1895 | |
1896 | - isOuter: true |
1897 | + isFoldVisible: false |
1898 | width: units.gu(5) |
1899 | anchors { |
1900 | horizontalCenter: parent.horizontalCenter |
1901 | @@ -47,23 +46,18 @@ |
1902 | topMargin: units.gu(1) |
1903 | } |
1904 | |
1905 | - ClockCircle { |
1906 | - width: units.gu(3.5) |
1907 | + Icon { |
1908 | anchors.centerIn: parent |
1909 | - |
1910 | - Icon { |
1911 | - anchors.centerIn: parent |
1912 | - color: UbuntuColors.coolGrey |
1913 | - name: "add" |
1914 | - height: units.gu(2) |
1915 | - width: height |
1916 | - } |
1917 | + color: UbuntuColors.coolGrey |
1918 | + name: "add" |
1919 | + height: units.gu(2) |
1920 | + width: height |
1921 | } |
1922 | } |
1923 | |
1924 | + |
1925 | Label { |
1926 | text: i18n.tr("City") |
1927 | - color: UbuntuColors.midAubergine |
1928 | anchors { |
1929 | left: _addButton.right |
1930 | leftMargin: units.gu(1) |
1931 | |
1932 | === modified file 'app/worldclock/UserWorldCityDelegate.qml' |
1933 | --- app/worldclock/UserWorldCityDelegate.qml 2015-10-22 16:49:23 +0000 |
1934 | +++ app/worldclock/UserWorldCityDelegate.qml 2016-02-25 18:41:31 +0000 |
1935 | @@ -55,17 +55,19 @@ |
1936 | Label { |
1937 | text: model.cityName |
1938 | objectName: "userCityNameText" |
1939 | + textSize: Label.Small |
1940 | width: parent.width |
1941 | elide: Text.ElideRight |
1942 | - color: UbuntuColors.midAubergine |
1943 | + color: "#5d5d5d" |
1944 | } |
1945 | |
1946 | Label { |
1947 | text: model.countryName |
1948 | objectName: "userCountryNameText" |
1949 | - fontSize: "xx-small" |
1950 | + textSize: Label.Small |
1951 | width: parent.width |
1952 | elide: Text.ElideRight |
1953 | + color: "#888888" |
1954 | } |
1955 | } |
1956 | |
1957 | @@ -73,10 +75,9 @@ |
1958 | id: localTimeVisual |
1959 | objectName: "localTimeVisual" + index |
1960 | |
1961 | - fontSize: units.dp(14) |
1962 | periodFontSize: units.dp(7) |
1963 | - innerCircleWidth: units.gu(5) |
1964 | - width: units.gu(7) |
1965 | + innerCircleWidth: units.gu(6) |
1966 | + width: units.gu(6) |
1967 | |
1968 | notLocalizedDateTimeString: model.notLocalizedZoneTime |
1969 | localizedTimeString: model.localizedZoneTime |
1970 | @@ -120,7 +121,8 @@ |
1971 | anchors.right: parent.right |
1972 | anchors.verticalCenter: parent.verticalCenter |
1973 | |
1974 | - fontSize: "xx-small" |
1975 | + color: "#5d5d5d" |
1976 | + textSize: Label.Small |
1977 | wrapMode: Text.WordWrap |
1978 | maximumLineCount: 2 |
1979 | elide: Text.ElideRight |
1980 | |
1981 | === modified file 'app/worldclock/WorldCityList.qml' |
1982 | --- app/worldclock/WorldCityList.qml 2015-12-11 02:13:16 +0000 |
1983 | +++ app/worldclock/WorldCityList.qml 2016-02-25 18:41:31 +0000 |
1984 | @@ -321,45 +321,18 @@ |
1985 | } |
1986 | |
1987 | delegate: ListItem { |
1988 | - height: worldCityDelegateColumn.height + units.gu(2) |
1989 | divider.visible: false |
1990 | objectName: "defaultWorldCityItem" + index |
1991 | - |
1992 | - Column { |
1993 | - id: worldCityDelegateColumn |
1994 | - |
1995 | - anchors { |
1996 | - left: parent.left |
1997 | - leftMargin: units.gu(2) |
1998 | - right: _localTime.left |
1999 | - rightMargin: units.gu(1) |
2000 | - verticalCenter: parent.verticalCenter |
2001 | - } |
2002 | - |
2003 | - Label { |
2004 | - text: cityName |
2005 | - objectName: "defaultCityNameText" |
2006 | - width: parent.width |
2007 | - elide: Text.ElideRight |
2008 | - color: UbuntuColors.midAubergine |
2009 | - } |
2010 | - |
2011 | - Label { |
2012 | - text: countryName |
2013 | - objectName: "defaultCountryNameText" |
2014 | - fontSize: "xx-small" |
2015 | - width: parent.width |
2016 | - elide: Text.ElideRight |
2017 | - } |
2018 | - } |
2019 | - |
2020 | - Label { |
2021 | - id: _localTime |
2022 | - text: localizedZoneTime |
2023 | - anchors { |
2024 | - right: parent.right |
2025 | - rightMargin: units.gu(2) |
2026 | - verticalCenter: parent.verticalCenter |
2027 | + ListItemLayout { |
2028 | + title.text: cityName |
2029 | + title.objectName: "defaultCityNameText" |
2030 | + subtitle.text: countryName |
2031 | + subtitle.objectName: "defaultCountryNameText" |
2032 | + |
2033 | + Label { |
2034 | + id: _localTime |
2035 | + text: localizedZoneTime |
2036 | + SlotsLayout.position: SlotsLayout.Trailing |
2037 | } |
2038 | } |
2039 | |
2040 | |
2041 | === modified file 'backend/modules/Stopwatch/formattime.cpp' |
2042 | --- backend/modules/Stopwatch/formattime.cpp 2015-08-26 22:47:23 +0000 |
2043 | +++ backend/modules/Stopwatch/formattime.cpp 2016-02-25 18:41:31 +0000 |
2044 | @@ -65,14 +65,5 @@ |
2045 | |
2046 | QString FormatTime::lapTimeToString(int millis) const |
2047 | { |
2048 | - int hours = qFloor(millis / 1000 / 60 / 60); |
2049 | - |
2050 | - if (hours > 0) |
2051 | - { |
2052 | - return millisToTimeString(millis, true); |
2053 | - } |
2054 | - |
2055 | - else { |
2056 | - return millisToTimeString(millis, false); |
2057 | - } |
2058 | + return millisToTimeString(millis, true); |
2059 | } |
2060 | |
2061 | === modified file 'po/com.ubuntu.clock.pot' |
2062 | --- po/com.ubuntu.clock.pot 2015-10-19 02:18:36 +0000 |
2063 | +++ po/com.ubuntu.clock.pot 2016-02-25 18:41:31 +0000 |
2064 | @@ -8,7 +8,7 @@ |
2065 | msgstr "" |
2066 | "Project-Id-Version: \n" |
2067 | "Report-Msgid-Bugs-To: \n" |
2068 | -"POT-Creation-Date: 2015-10-19 04:17+0200\n" |
2069 | +"POT-Creation-Date: 2016-02-17 22:46+0100\n" |
2070 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
2071 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
2072 | "Language-Team: LANGUAGE <LL@li.org>\n" |
2073 | @@ -23,7 +23,7 @@ |
2074 | msgstr "" |
2075 | |
2076 | #: ../app/alarm/AlarmLabel.qml:33 ../app/alarm/AlarmLabel.qml:71 |
2077 | -#: ../app/alarm/EditAlarmPage.qml:283 |
2078 | +#: ../app/alarm/EditAlarmPage.qml:294 |
2079 | msgid "Label" |
2080 | msgstr "" |
2081 | |
2082 | @@ -62,61 +62,61 @@ |
2083 | msgid "Tap the + icon to add an alarm" |
2084 | msgstr "" |
2085 | |
2086 | -#: ../app/alarm/AlarmRepeat.qml:36 ../app/alarm/EditAlarmPage.qml:273 |
2087 | +#: ../app/alarm/AlarmRepeat.qml:36 ../app/alarm/EditAlarmPage.qml:279 |
2088 | msgid "Repeat" |
2089 | msgstr "" |
2090 | |
2091 | -#: ../app/alarm/AlarmSettingsPage.qml:29 |
2092 | +#: ../app/alarm/AlarmSettingsPage.qml:28 |
2093 | msgid "Settings" |
2094 | msgstr "" |
2095 | |
2096 | #. TRANSLATORS: Alarm stops after |
2097 | #. TRANSLATORS: Snooze for |
2098 | -#: ../app/alarm/AlarmSettingsPage.qml:54 ../app/alarm/AlarmSettingsPage.qml:55 |
2099 | -#: ../app/alarm/AlarmSettingsPage.qml:56 ../app/alarm/AlarmSettingsPage.qml:57 |
2100 | -#: ../app/alarm/AlarmSettingsPage.qml:67 ../app/alarm/AlarmSettingsPage.qml:68 |
2101 | -#: ../app/alarm/AlarmSettingsPage.qml:69 ../app/alarm/AlarmSettingsPage.qml:70 |
2102 | -#: ../app/alarm/AlarmSettingsPage.qml:126 |
2103 | -#: ../app/alarm/AlarmSettingsPage.qml:164 |
2104 | +#: ../app/alarm/AlarmSettingsPage.qml:53 ../app/alarm/AlarmSettingsPage.qml:54 |
2105 | +#: ../app/alarm/AlarmSettingsPage.qml:55 ../app/alarm/AlarmSettingsPage.qml:56 |
2106 | +#: ../app/alarm/AlarmSettingsPage.qml:66 ../app/alarm/AlarmSettingsPage.qml:67 |
2107 | +#: ../app/alarm/AlarmSettingsPage.qml:68 ../app/alarm/AlarmSettingsPage.qml:69 |
2108 | +#: ../app/alarm/AlarmSettingsPage.qml:118 |
2109 | +#: ../app/alarm/AlarmSettingsPage.qml:147 |
2110 | #, qt-format |
2111 | msgid "%1 minute" |
2112 | msgid_plural "%1 minutes" |
2113 | msgstr[0] "" |
2114 | msgstr[1] "" |
2115 | |
2116 | -#: ../app/alarm/AlarmSettingsPage.qml:94 |
2117 | +#: ../app/alarm/AlarmSettingsPage.qml:96 |
2118 | msgid "Alarm volume" |
2119 | msgstr "" |
2120 | |
2121 | -#: ../app/alarm/AlarmSettingsPage.qml:125 |
2122 | +#: ../app/alarm/AlarmSettingsPage.qml:117 |
2123 | msgid "Alarm stops after" |
2124 | msgstr "" |
2125 | |
2126 | -#: ../app/alarm/AlarmSettingsPage.qml:163 |
2127 | +#: ../app/alarm/AlarmSettingsPage.qml:146 |
2128 | msgid "Snooze for" |
2129 | msgstr "" |
2130 | |
2131 | -#: ../app/alarm/AlarmSettingsPage.qml:199 |
2132 | +#: ../app/alarm/AlarmSettingsPage.qml:175 |
2133 | msgid "Vibration" |
2134 | msgstr "" |
2135 | |
2136 | -#: ../app/alarm/AlarmSettingsPage.qml:233 |
2137 | +#: ../app/alarm/AlarmSettingsPage.qml:200 |
2138 | msgid "Change time and date" |
2139 | msgstr "" |
2140 | |
2141 | -#: ../app/alarm/AlarmSound.qml:31 ../app/alarm/EditAlarmPage.qml:296 |
2142 | +#: ../app/alarm/AlarmSound.qml:30 ../app/alarm/EditAlarmPage.qml:314 |
2143 | msgid "Sound" |
2144 | msgstr "" |
2145 | |
2146 | -#: ../app/alarm/AlarmSound.qml:186 |
2147 | +#: ../app/alarm/AlarmSound.qml:185 |
2148 | msgid "Custom alarm sounds" |
2149 | msgstr "" |
2150 | |
2151 | -#: ../app/alarm/AlarmSound.qml:201 |
2152 | +#: ../app/alarm/AlarmSound.qml:200 |
2153 | msgid "Add sound" |
2154 | msgstr "" |
2155 | |
2156 | -#: ../app/alarm/AlarmSound.qml:353 |
2157 | +#: ../app/alarm/AlarmSound.qml:336 |
2158 | msgid "Default alarm sounds" |
2159 | msgstr "" |
2160 | |
2161 | @@ -141,21 +141,21 @@ |
2162 | msgid "Next Alarm %1" |
2163 | msgstr "" |
2164 | |
2165 | -#: ../app/alarm/AlarmUtils.qml:89 |
2166 | +#: ../app/alarm/AlarmUtils.qml:103 |
2167 | msgid "Alarm Passed" |
2168 | msgstr "" |
2169 | |
2170 | -#: ../app/alarm/AlarmUtils.qml:99 |
2171 | +#: ../app/alarm/AlarmUtils.qml:113 |
2172 | #, no-c-format, qt-format |
2173 | msgid "in %1d %2h %3m" |
2174 | msgstr "" |
2175 | |
2176 | -#: ../app/alarm/AlarmUtils.qml:109 |
2177 | +#: ../app/alarm/AlarmUtils.qml:123 |
2178 | #, no-c-format, qt-format |
2179 | msgid "in %1h %2m" |
2180 | msgstr "" |
2181 | |
2182 | -#: ../app/alarm/AlarmUtils.qml:118 |
2183 | +#: ../app/alarm/AlarmUtils.qml:132 |
2184 | #, no-c-format, qt-format |
2185 | msgid "in %1m" |
2186 | msgstr "" |
2187 | @@ -168,7 +168,7 @@ |
2188 | msgid "Edit alarm" |
2189 | msgstr "" |
2190 | |
2191 | -#: ../app/alarm/EditAlarmPage.qml:316 |
2192 | +#: ../app/alarm/EditAlarmPage.qml:337 |
2193 | msgid "Delete alarm" |
2194 | msgstr "" |
2195 | |
2196 | @@ -177,37 +177,37 @@ |
2197 | msgid "Add sound from" |
2198 | msgstr "" |
2199 | |
2200 | -#: ../app/clock/ClockPage.qml:249 |
2201 | +#: ../app/clock/ClockPage.qml:245 |
2202 | msgid "Retrieving location..." |
2203 | msgstr "" |
2204 | |
2205 | #. TRANSLATORS: This refers to the stopwatch lap and is shown as a header where space is limited. Constrain |
2206 | #. translation length to a few characters. |
2207 | -#: ../app/stopwatch/LapListView.qml:46 ../app/stopwatch/StopwatchPage.qml:83 |
2208 | +#: ../app/stopwatch/LapListView.qml:49 ../app/stopwatch/StopwatchPage.qml:98 |
2209 | msgid "Lap" |
2210 | msgstr "" |
2211 | |
2212 | -#: ../app/stopwatch/LapListView.qml:56 |
2213 | +#: ../app/stopwatch/LapListView.qml:58 |
2214 | msgid "Lap Time" |
2215 | msgstr "" |
2216 | |
2217 | -#: ../app/stopwatch/LapListView.qml:64 |
2218 | +#: ../app/stopwatch/LapListView.qml:65 |
2219 | msgid "Total Time" |
2220 | msgstr "" |
2221 | |
2222 | -#: ../app/stopwatch/StopwatchPage.qml:66 |
2223 | +#: ../app/stopwatch/StopwatchPage.qml:80 |
2224 | msgid "Stop" |
2225 | msgstr "" |
2226 | |
2227 | -#: ../app/stopwatch/StopwatchPage.qml:66 |
2228 | +#: ../app/stopwatch/StopwatchPage.qml:80 |
2229 | msgid "Start" |
2230 | msgstr "" |
2231 | |
2232 | -#: ../app/stopwatch/StopwatchPage.qml:66 |
2233 | +#: ../app/stopwatch/StopwatchPage.qml:80 |
2234 | msgid "Resume" |
2235 | msgstr "" |
2236 | |
2237 | -#: ../app/stopwatch/StopwatchPage.qml:83 |
2238 | +#: ../app/stopwatch/StopwatchPage.qml:98 |
2239 | msgid "Clear" |
2240 | msgstr "" |
2241 | |
2242 | @@ -215,44 +215,44 @@ |
2243 | msgid "Add" |
2244 | msgstr "" |
2245 | |
2246 | -#: ../app/worldclock/AddWorldCityButton.qml:65 |
2247 | +#: ../app/worldclock/AddWorldCityButton.qml:60 |
2248 | #: ../app/worldclock/WorldCityList.qml:63 |
2249 | msgid "City" |
2250 | msgstr "" |
2251 | |
2252 | #. TRANSLATORS: this indicates if the time in a world clock |
2253 | #. is behind or ahead of the time at the current location |
2254 | -#: ../app/worldclock/UserWorldCityDelegate.qml:133 |
2255 | +#: ../app/worldclock/UserWorldCityDelegate.qml:135 |
2256 | msgid "behind" |
2257 | msgstr "" |
2258 | |
2259 | -#: ../app/worldclock/UserWorldCityDelegate.qml:134 |
2260 | +#: ../app/worldclock/UserWorldCityDelegate.qml:136 |
2261 | msgid "ahead" |
2262 | msgstr "" |
2263 | |
2264 | #. TRANSLATORS: the first argument is hour, followed by |
2265 | #. minute, and the translation for either 'behind' or |
2266 | #. 'ahead' |
2267 | -#: ../app/worldclock/UserWorldCityDelegate.qml:144 |
2268 | +#: ../app/worldclock/UserWorldCityDelegate.qml:146 |
2269 | #, qt-format |
2270 | msgid "%1h %2m %3" |
2271 | msgstr "" |
2272 | |
2273 | #. TRANSLATORS: the first argument is hour, followed by the |
2274 | #. translation for either 'behind' or 'ahead' |
2275 | -#: ../app/worldclock/UserWorldCityDelegate.qml:153 |
2276 | +#: ../app/worldclock/UserWorldCityDelegate.qml:155 |
2277 | #, qt-format |
2278 | msgid "%1h %2" |
2279 | msgstr "" |
2280 | |
2281 | #. TRANSLATORS: the first argument is minute, followed by the |
2282 | #. translation for either 'behind' or 'ahead' |
2283 | -#: ../app/worldclock/UserWorldCityDelegate.qml:161 |
2284 | +#: ../app/worldclock/UserWorldCityDelegate.qml:163 |
2285 | #, qt-format |
2286 | msgid "%1m %2" |
2287 | msgstr "" |
2288 | |
2289 | -#: ../app/worldclock/UserWorldCityDelegate.qml:167 |
2290 | +#: ../app/worldclock/UserWorldCityDelegate.qml:169 |
2291 | msgid "Same time" |
2292 | msgstr "" |
2293 | |
2294 | |
2295 | === modified file 'tests/unit/ClockTestCase.qml' |
2296 | --- tests/unit/ClockTestCase.qml 2015-08-14 05:34:49 +0000 |
2297 | +++ tests/unit/ClockTestCase.qml 2016-02-25 18:41:31 +0000 |
2298 | @@ -48,7 +48,7 @@ |
2299 | id: testUtils |
2300 | |
2301 | function pressHeaderButton(header, objectName) { |
2302 | - var headerButton = findChild(header, objectName + "_header_button") |
2303 | + var headerButton = findChild(header, objectName + "_button") |
2304 | mouseClick(headerButton, centerOf(headerButton).x, centerOf(headerButton).y) |
2305 | } |
2306 | |
2307 | |
2308 | === modified file 'tests/unit/tst_alarmLabel.qml' |
2309 | --- tests/unit/tst_alarmLabel.qml 2015-10-22 16:49:23 +0000 |
2310 | +++ tests/unit/tst_alarmLabel.qml 2016-02-25 18:41:31 +0000 |
2311 | @@ -51,7 +51,7 @@ |
2312 | header = findChild(mainView, "MainView_Header") |
2313 | alarmLabel = findChild(alarmLabelPage, "labelEntry") |
2314 | backButton = findChild(header, "customBackButton") |
2315 | - saveButton = findChild(header, "saveAction_header_button") |
2316 | + saveButton = findChild(header, "saveAction_button") |
2317 | } |
2318 | |
2319 | /* |
2320 | |
2321 | === modified file 'tests/unit/tst_alarmRepeat.qml' |
2322 | --- tests/unit/tst_alarmRepeat.qml 2015-10-22 16:49:23 +0000 |
2323 | +++ tests/unit/tst_alarmRepeat.qml 2016-02-25 18:41:31 +0000 |
2324 | @@ -70,7 +70,7 @@ |
2325 | spy.target = alarmRepeatPageLoader.item.Component |
2326 | header = findChild(mainView, "MainView_Header") |
2327 | backButton = findChild(header, "customBackButton") |
2328 | - saveButton = findChild(header, "saveAction_header_button") |
2329 | + saveButton = findChild(header, "saveAction_button") |
2330 | repeater = findChild(alarmRepeatPageLoader.item, "alarmDays") |
2331 | } |
2332 | |
2333 | |
2334 | === modified file 'tests/unit/tst_alarmUtils.qml' |
2335 | --- tests/unit/tst_alarmUtils.qml 2015-12-11 02:13:16 +0000 |
2336 | +++ tests/unit/tst_alarmUtils.qml 2016-02-25 18:41:31 +0000 |
2337 | @@ -103,11 +103,11 @@ |
2338 | */ |
2339 | function test_timeToNextAlarmStringMustShowAll() { |
2340 | var currentDateTime = new Date() |
2341 | - var timeInMilliseconds = ((5 * 24 + 2)* 60 + 15) * 60 * 1000; // 5 days, 2 hrs, 16 mins |
2342 | + var timeInMilliseconds = ((5 * 24 + 2)* 60 + 15) * 60 * 1000; // 5 days, 2 hrs, 15 mins |
2343 | |
2344 | var alarmDate = new Date(currentDateTime.getTime() + timeInMilliseconds); |
2345 | var result = alarmUtils.get_time_to_alarm(alarmDate, currentDateTime) |
2346 | - compare(result, "in 5d 2h 16m", "Time to next alarm string is incorrect") |
2347 | + compare(result, "in 5d 2h 15m", "Time to next alarm string is incorrect") |
2348 | } |
2349 | |
2350 | /* |
2351 | |
2352 | === modified file 'tests/unit/tst_stopwatchUtils.qml' |
2353 | --- tests/unit/tst_stopwatchUtils.qml 2015-10-22 16:49:23 +0000 |
2354 | +++ tests/unit/tst_stopwatchUtils.qml 2016-02-25 18:41:31 +0000 |
2355 | @@ -67,16 +67,4 @@ |
2356 | result = stopwatchFormatTime.addZeroPrefix(str, 4) |
2357 | compare(result, "0032", "Zero prefix not added correctly") |
2358 | } |
2359 | - |
2360 | - /* |
2361 | - This test checks if the lap time correctly shows or hides the hours |
2362 | - as requires and returns it as a string. |
2363 | - */ |
2364 | - function test_lapTimeIncludesHoursCorrectly() { |
2365 | - var result |
2366 | - result = stopwatchFormatTime.lapTimeToString(1123000) |
2367 | - compare(result, "18:43", "Lap time shows hours despite it not being greater than 0") |
2368 | - result = stopwatchFormatTime.lapTimeToString(8323000) |
2369 | - compare(result, "02:18:43", "Lap time not showing hours despite it being greater than 0") |
2370 | - } |
2371 | } |
Please merge https:/ /code.launchpad .net/~fboucault /ubuntu- clock-app/ fix_startup_ animation_ and_performance /+merge/ 282839 and resolve any code conflicts. That branch changes the animation and clock face shadow implementation which affects the changes made in this branch.