Merge lp:~nik90/podbird/11-enable-rotation into lp:podbird
- 11-enable-rotation
- Merge into trunk
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Michael Sheldon | ||||
Approved revision: | 85 | ||||
Merged at revision: | 85 | ||||
Proposed branch: | lp:~nik90/podbird/11-enable-rotation | ||||
Merge into: | lp:podbird | ||||
Prerequisite: | lp:~nik90/podbird/10-organize-project-structure | ||||
Diff against target: |
817 lines (+351/-266) 10 files modified
app/components/BlurredBackground.qml (+1/-2) app/components/Walkthrough.qml (+4/-0) app/podbird.qml (+7/-0) app/settings/About.qml (+60/-51) app/settings/CleanSetting.qml (+7/-0) app/settings/Credits.qml (+32/-33) app/settings/DownloadSetting.qml (+7/-0) app/settings/ThemeSetting.qml (+7/-0) app/ui/NowPlayingPage.qml (+206/-160) po/com.mikeasoft.podbird.pot (+20/-20) |
||||
To merge this branch: | bzr merge lp:~nik90/podbird/11-enable-rotation | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Michael Sheldon | Approve | ||
Review via email: mp+257404@code.launchpad.net |
Commit message
Description of the change
This MP fixes the pages that break in landscape mode which are,
- Settings pages like about, credits, auto-download and auto-delete by using a flickable to allow scrolling of data.
- Now Playing Page by using a new layout for landscape layout
As such we can now enable automaticOrient
Warning: All apps on devel-proposed crash when accessing the tab-menu in landscape mode. This has been reported upstream in https:/
- 78. By Nekhelesh Ramananthan
-
Disable automatic orientation during welcome wizard since the slides are not landscape friendly
- 79. By Nekhelesh Ramananthan
-
Simplified now playing landscape implementation
- 80. By Nekhelesh Ramananthan
-
merged prerequisite lp:~nik90/podbird/10-organize-project-structure
- 81. By Nekhelesh Ramananthan
-
Made credits page easier to maintain and also tweaked header style to match rest of app
- 82. By Nekhelesh Ramananthan
-
Revert the tweaked header style in the credits page
- 83. By Nekhelesh Ramananthan
-
merged lp:podbird
- 84. By Nekhelesh Ramananthan
-
Disabled automaticOrient
ation and added fix me note
Nekhelesh Ramananthan (nik90) wrote : | # |
- 85. By Nekhelesh Ramananthan
-
Disabled the automatic orientation change done by welcome wizard as well
Michael Sheldon (michael-sheldon) wrote : | # |
Looks good, tested with shell rotation and it works nicely. I made one small tweak to the NowPlaying layout as the scrubber overlapped the artist name when the title wraps onto a second line.
Michael Sheldon (michael-sheldon) wrote : | # |
We will need to make the wizard landscape friendly before OTA-5 though (as the shell rotation will mean orientation changes will be enabled through-out the app)
Preview Diff
1 | === modified file 'app/components/BlurredBackground.qml' |
2 | --- app/components/BlurredBackground.qml 2015-04-20 20:52:20 +0000 |
3 | +++ app/components/BlurredBackground.qml 2015-06-13 16:50:32 +0000 |
4 | @@ -35,10 +35,9 @@ |
5 | anchors.verticalCenter: parent.verticalCenter |
6 | asynchronous: true |
7 | fillMode: Image.PreserveAspectCrop |
8 | - height: parent.height |
9 | + anchors.fill: parent |
10 | source: art // this has to be fixed for the default cover art to work - cant find in this dir |
11 | visible: false |
12 | - width: Math.max(parent.height, parent.width) |
13 | } |
14 | |
15 | // the blur |
16 | |
17 | === modified file 'app/components/Walkthrough.qml' |
18 | --- app/components/Walkthrough.qml 2015-04-20 20:52:20 +0000 |
19 | +++ app/components/Walkthrough.qml 2015-06-13 16:50:32 +0000 |
20 | @@ -44,6 +44,10 @@ |
21 | // Property to signal walkthrough completion |
22 | signal finished |
23 | |
24 | + // Disable automatic orientation during welcome wizard since it is not landscape friendly yet. |
25 | + // Component.onCompleted: podbird.automaticOrientation = false |
26 | + // Component.onDestruction: podbird.automaticOrientation = true |
27 | + |
28 | // ListView to show the slides |
29 | ListView { |
30 | id: listView |
31 | |
32 | === modified file 'app/podbird.qml' |
33 | --- app/podbird.qml 2015-04-28 12:09:05 +0000 |
34 | +++ app/podbird.qml 2015-06-13 16:50:32 +0000 |
35 | @@ -37,6 +37,13 @@ |
36 | useDeprecatedToolbar: false |
37 | anchorToKeyboard: true |
38 | |
39 | + /* |
40 | + FIXME: Opening tabs in landscape mode causes apps to crash in the current vivid images. |
41 | + As such this is disabled until upstream bug https://pad.lv/1448017 is fixed and released |
42 | + to the production phones. |
43 | + */ |
44 | + automaticOrientation: false |
45 | + |
46 | width: units.gu(50) |
47 | height: units.gu(75) |
48 | |
49 | |
50 | === modified file 'app/settings/About.qml' |
51 | --- app/settings/About.qml 2015-04-23 23:45:18 +0000 |
52 | +++ app/settings/About.qml 2015-06-13 16:50:32 +0000 |
53 | @@ -24,65 +24,74 @@ |
54 | |
55 | title: i18n.tr("About") |
56 | |
57 | - Column { |
58 | - spacing: units.gu(3) |
59 | + Flickable { |
60 | + id: flickable |
61 | + |
62 | anchors.fill: parent |
63 | - anchors.topMargin: units.gu(5) |
64 | - anchors.bottomMargin: units.gu(10) |
65 | - |
66 | - Image { |
67 | - height: width |
68 | - width: Math.min(parent.width/2, parent.height/2) |
69 | - source: "../graphics/podbird.png" |
70 | - anchors.horizontalCenter: parent.horizontalCenter |
71 | - } |
72 | - |
73 | - Column { |
74 | - width: parent.width |
75 | - Label { |
76 | - width: parent.width |
77 | - fontSize: "x-large" |
78 | - font.weight: Font.DemiBold |
79 | - horizontalAlignment: Text.AlignHCenter |
80 | - text: "Podbird" |
81 | - } |
82 | - Label { |
83 | - width: parent.width |
84 | - horizontalAlignment: Text.AlignHCenter |
85 | - // TRANSLATORS: Podbird version number e.g Version 0.6 |
86 | - text: i18n.tr("Version %1").arg("0.6") |
87 | - } |
88 | - } |
89 | - |
90 | - Column { |
91 | + contentHeight: dataColumn.height + units.gu(10) + dataColumn.anchors.topMargin |
92 | + |
93 | + Column { |
94 | + id: dataColumn |
95 | + |
96 | + spacing: units.gu(3) |
97 | anchors { |
98 | - left: parent.left |
99 | - right: parent.right |
100 | - margins: units.gu(2) |
101 | - } |
102 | + top: parent.top; left: parent.left; right: parent.right; topMargin: units.gu(5) |
103 | + } |
104 | + |
105 | + Image { |
106 | + height: width |
107 | + width: Math.min(parent.width/2, parent.height/2) |
108 | + source: "../graphics/podbird.png" |
109 | + anchors.horizontalCenter: parent.horizontalCenter |
110 | + } |
111 | + |
112 | + Column { |
113 | + width: parent.width |
114 | + Label { |
115 | + width: parent.width |
116 | + fontSize: "x-large" |
117 | + font.weight: Font.DemiBold |
118 | + horizontalAlignment: Text.AlignHCenter |
119 | + text: "Podbird" |
120 | + } |
121 | + Label { |
122 | + width: parent.width |
123 | + horizontalAlignment: Text.AlignHCenter |
124 | + // TRANSLATORS: Podbird version number e.g Version 0.6 |
125 | + text: i18n.tr("Version %1").arg("0.6") |
126 | + } |
127 | + } |
128 | + |
129 | + Column { |
130 | + anchors { |
131 | + left: parent.left |
132 | + right: parent.right |
133 | + margins: units.gu(2) |
134 | + } |
135 | + Label { |
136 | + width: parent.width |
137 | + wrapMode: Text.WordWrap |
138 | + horizontalAlignment: Text.AlignHCenter |
139 | + text: "(C) 2015 Podbird Team" |
140 | + } |
141 | + Label { |
142 | + fontSize: "small" |
143 | + width: parent.width |
144 | + wrapMode: Text.WordWrap |
145 | + horizontalAlignment: Text.AlignHCenter |
146 | + text: i18n.tr("Released under the terms of the GNU GPL v3") |
147 | + } |
148 | + } |
149 | + |
150 | Label { |
151 | width: parent.width |
152 | wrapMode: Text.WordWrap |
153 | - horizontalAlignment: Text.AlignHCenter |
154 | - text: "(C) 2015 Podbird Team" |
155 | - } |
156 | - Label { |
157 | fontSize: "small" |
158 | - width: parent.width |
159 | - wrapMode: Text.WordWrap |
160 | horizontalAlignment: Text.AlignHCenter |
161 | - text: i18n.tr("Released under the terms of the GNU GPL v3") |
162 | + linkColor: podbird.appTheme.linkText |
163 | + text: i18n.tr("Source code available on %1").arg("<a href=\"https://launchpad.net/podbird\">launchpad.net</a>") |
164 | + onLinkActivated: Qt.openUrlExternally(link) |
165 | } |
166 | } |
167 | - |
168 | - Label { |
169 | - width: parent.width |
170 | - wrapMode: Text.WordWrap |
171 | - fontSize: "small" |
172 | - horizontalAlignment: Text.AlignHCenter |
173 | - linkColor: podbird.appTheme.linkText |
174 | - text: i18n.tr("Source code available on %1").arg("<a href=\"https://launchpad.net/podbird\">launchpad.net</a>") |
175 | - onLinkActivated: Qt.openUrlExternally(link) |
176 | - } |
177 | } |
178 | } |
179 | |
180 | === modified file 'app/settings/CleanSetting.qml' |
181 | --- app/settings/CleanSetting.qml 2015-03-31 08:35:54 +0000 |
182 | +++ app/settings/CleanSetting.qml 2015-06-13 16:50:32 +0000 |
183 | @@ -45,6 +45,13 @@ |
184 | model: cleanupModel |
185 | anchors.fill: parent |
186 | |
187 | + // Required to accomodate the now playing bar being shown in landscape mode which |
188 | + // can hide a setting if not for this footer. |
189 | + footer: Item { |
190 | + width: parent.width |
191 | + height: units.gu(8) |
192 | + } |
193 | + |
194 | delegate: ListItem.Standard { |
195 | text: model.name |
196 | onClicked: { |
197 | |
198 | === modified file 'app/settings/Credits.qml' |
199 | --- app/settings/Credits.qml 2015-04-23 23:45:18 +0000 |
200 | +++ app/settings/Credits.qml 2015-06-13 16:50:32 +0000 |
201 | @@ -25,41 +25,40 @@ |
202 | |
203 | title: i18n.tr("Credits") |
204 | |
205 | - Column { |
206 | - anchors.topMargin: units.gu(1) |
207 | + ListModel { |
208 | + id: creditsModel |
209 | + Component.onCompleted: initialize() |
210 | + function initialize() { |
211 | + // TRANSLATORS: The first argument is the name of creator of Podbird (Michael Sheldon) |
212 | + creditsModel.append({ name: i18n.tr("%1 (Creator)").arg("Michael Sheldon"), title: i18n.tr("Developers") }) |
213 | + creditsModel.append({ name: "Nekhelesh Ramananthan", title: i18n.tr("Developers") }) |
214 | + creditsModel.append({ name: "Kevin Feyder", title: i18n.tr("Designer") }) |
215 | + creditsModel.append({ name: "Ubuntu Translators Community", title: i18n.tr("Translators") }) |
216 | + } |
217 | + } |
218 | + |
219 | + UbuntuListView { |
220 | + id: credits |
221 | + |
222 | + model: creditsModel |
223 | anchors.fill: parent |
224 | |
225 | - ListItem.Header { |
226 | - text: i18n.tr("Developers") |
227 | - } |
228 | - |
229 | - ListItem.Standard { |
230 | - showDivider: false |
231 | - // TRANSLATORS: The first argument is the name of creator of Podbird (Michael Sheldon) |
232 | - text: i18n.tr("%1 (Creator)").arg("Michael Sheldon") |
233 | - } |
234 | - |
235 | - ListItem.Standard { |
236 | - showDivider: false |
237 | - text: "Nekhelesh Ramananthan" |
238 | - } |
239 | - |
240 | - ListItem.Header { |
241 | - text: i18n.tr("Designer") |
242 | - } |
243 | - |
244 | - ListItem.Standard { |
245 | - showDivider: false |
246 | - text: "Kevin Feyder" |
247 | - } |
248 | - |
249 | - ListItem.Header { |
250 | - text: i18n.tr("Translators") |
251 | - } |
252 | - |
253 | - ListItem.Standard { |
254 | - showDivider: false |
255 | - text: "Ubuntu Translators Team" |
256 | + section.property: "title" |
257 | + section.labelPositioning: ViewSection.InlineLabels |
258 | + section.delegate: ListItem.Header { |
259 | + text: section |
260 | + } |
261 | + |
262 | + // Required to accomodate the now playing bar being shown in landscape mode which |
263 | + // can hide a setting if not for this footer. |
264 | + footer: Item { |
265 | + width: parent.width |
266 | + height: units.gu(8) |
267 | + } |
268 | + |
269 | + delegate: ListItem.Standard { |
270 | + text: model.name |
271 | + showDivider: false |
272 | } |
273 | } |
274 | } |
275 | |
276 | === modified file 'app/settings/DownloadSetting.qml' |
277 | --- app/settings/DownloadSetting.qml 2015-03-30 20:51:35 +0000 |
278 | +++ app/settings/DownloadSetting.qml 2015-06-13 16:50:32 +0000 |
279 | @@ -44,6 +44,13 @@ |
280 | model: episodeDownloadNumber |
281 | anchors.fill: parent |
282 | |
283 | + // Required to accomodate the now playing bar being shown in landscape mode which |
284 | + // can hide a setting if not for this footer. |
285 | + footer: Item { |
286 | + width: parent.width |
287 | + height: units.gu(8) |
288 | + } |
289 | + |
290 | delegate: ListItem.Standard { |
291 | text: model.name |
292 | onClicked: { |
293 | |
294 | === modified file 'app/settings/ThemeSetting.qml' |
295 | --- app/settings/ThemeSetting.qml 2015-04-23 23:45:18 +0000 |
296 | +++ app/settings/ThemeSetting.qml 2015-06-13 16:50:32 +0000 |
297 | @@ -43,6 +43,13 @@ |
298 | model: themeModel |
299 | anchors.fill: parent |
300 | |
301 | + // Required to accomodate the now playing bar being shown in landscape mode which |
302 | + // can hide a setting if not for this footer. |
303 | + footer: Item { |
304 | + width: parent.width |
305 | + height: units.gu(8) |
306 | + } |
307 | + |
308 | delegate: ListItem.Standard { |
309 | text: model.name |
310 | onClicked: { |
311 | |
312 | === modified file 'app/ui/NowPlayingPage.qml' |
313 | --- app/ui/NowPlayingPage.qml 2015-04-23 23:45:18 +0000 |
314 | +++ app/ui/NowPlayingPage.qml 2015-06-13 16:50:32 +0000 |
315 | @@ -29,6 +29,40 @@ |
316 | title: i18n.tr("Now Playing") |
317 | |
318 | property bool isNowPlayingPage: true |
319 | + property bool isLandscapeMode: width > height |
320 | + |
321 | + // Landscape rule |
322 | + states: [ |
323 | + State { |
324 | + name: "landscape" |
325 | + when: isLandscapeMode |
326 | + |
327 | + PropertyChanges { |
328 | + target: blurredBackground |
329 | + width: parent.width/2.2 |
330 | + height: parent.height |
331 | + } |
332 | + |
333 | + AnchorChanges { |
334 | + target: blurredBackground |
335 | + anchors { |
336 | + top: parent.top |
337 | + left: parent.left |
338 | + right: undefined |
339 | + } |
340 | + } |
341 | + |
342 | + AnchorChanges { |
343 | + target: dataContainer |
344 | + anchors { |
345 | + top: parent.top |
346 | + left: blurredBackground.right |
347 | + right: parent.right |
348 | + bottom: parent.bottom |
349 | + } |
350 | + } |
351 | + } |
352 | + ] |
353 | |
354 | BlurredBackground { |
355 | id: blurredBackground |
356 | @@ -50,171 +84,183 @@ |
357 | } |
358 | } |
359 | |
360 | - Label { |
361 | - id: title |
362 | - anchors.left: parent.left |
363 | - anchors.right: parent.right |
364 | - anchors.top: blurredBackground.bottom |
365 | - anchors.margins: units.gu(2) |
366 | - text: currentName |
367 | - elide: Text.ElideRight |
368 | - fontSize: "large" |
369 | - maximumLineCount: 2 |
370 | - wrapMode: Text.WordWrap |
371 | - color: podbird.appTheme.baseText |
372 | - } |
373 | - |
374 | - Label { |
375 | - id: artist |
376 | - anchors.left: title.left |
377 | - anchors.right: title.right |
378 | - anchors.top: title.bottom |
379 | - anchors.topMargin: units.gu(1) |
380 | - text: currentArtist |
381 | - elide: Text.ElideRight |
382 | - fontSize: "small" |
383 | - color: podbird.appTheme.baseSubText |
384 | - } |
385 | - |
386 | - Slider { |
387 | - id: scrubber |
388 | + Item { |
389 | + id: dataContainer |
390 | |
391 | anchors { |
392 | + top: blurredBackground.bottom |
393 | left: parent.left |
394 | right: parent.right |
395 | + bottom: parent.bottom |
396 | margins: units.gu(2) |
397 | - bottom: controls.top |
398 | - bottomMargin: units.gu(2) |
399 | - } |
400 | - |
401 | - live: true |
402 | - minimumValue: 0 |
403 | - maximumValue: player.duration |
404 | - value: player.position |
405 | - height: units.gu(2) |
406 | - |
407 | - onValueChanged: { |
408 | - if (pressed) { |
409 | - player.seek(value); |
410 | - } |
411 | - } |
412 | - |
413 | - function formatValue(v) { return Podcasts.formatTime(v/1000); } |
414 | - } |
415 | - |
416 | - Connections { |
417 | - target: player |
418 | - onPositionChanged: scrubber.value = player.position |
419 | - } |
420 | - |
421 | - Label { |
422 | - id: startTime |
423 | - fontSize: "small" |
424 | - anchors.left: scrubber.left |
425 | - anchors.top: scrubber.bottom |
426 | - color: podbird.appTheme.baseText |
427 | - text: Podcasts.formatTime(player.position / 1000) |
428 | - } |
429 | - |
430 | - Label { |
431 | - id: endTime |
432 | - fontSize: "small" |
433 | - anchors.right: scrubber.right |
434 | - anchors.top: scrubber.bottom |
435 | - color: podbird.appTheme.baseText |
436 | - text: Podcasts.formatTime(player.duration / 1000) |
437 | - } |
438 | - |
439 | - Row { |
440 | - id: controls |
441 | - anchors.bottom: parent.bottom |
442 | - anchors.horizontalCenter: parent.horizontalCenter |
443 | - spacing: units.gu(2) |
444 | - |
445 | - AbstractButton { |
446 | - id: skipBackwardButton |
447 | - width: units.gu(6) |
448 | - height: width |
449 | - anchors.verticalCenter: parent.verticalCenter |
450 | - opacity: player.position === 0 ? 0.4 : 1.0 |
451 | - onClicked: { |
452 | - if (player.position > 0) { |
453 | - player.seek(player.position - 15 * 1000); |
454 | - } |
455 | - } |
456 | - |
457 | - Row { |
458 | - spacing: units.gu(1) |
459 | - anchors.centerIn: parent |
460 | - |
461 | - Label { |
462 | - // TRANSLATORS: The string shown in the UI is -15s to denote the number of seconds that the podcast playback will skip backward. |
463 | - // xgettext: no-c-format |
464 | - text: i18n.tr("-%1s").arg("15") |
465 | - fontSize: "xx-small" |
466 | - color: podbird.appTheme.baseText |
467 | - anchors.verticalCenter: skipBackwardIcon.verticalCenter |
468 | - } |
469 | - |
470 | - Icon { |
471 | - id: skipBackwardIcon |
472 | - width: units.gu(3) |
473 | - height: width |
474 | - name: "media-seek-backward" |
475 | - color: podbird.appTheme.baseIcon |
476 | - } |
477 | - } |
478 | - } |
479 | - |
480 | - AbstractButton { |
481 | - id: playButton |
482 | - width: units.gu(10) |
483 | - height: width |
484 | - opacity: playButton.pressed ? 0.4 : 1.0 |
485 | - onClicked: player.playbackState === MediaPlayer.PlayingState ? player.pause() : player.play() |
486 | - |
487 | - Icon { |
488 | - id: playIcon |
489 | - width: units.gu(6) |
490 | - height: width |
491 | - anchors.centerIn: parent |
492 | - color: podbird.appTheme.baseIcon |
493 | - name: player.playbackState === MediaPlayer.PlayingState ? "media-playback-pause" |
494 | - : "media-playback-start" |
495 | - } |
496 | - } |
497 | - |
498 | - AbstractButton { |
499 | - id: skipForwardButton |
500 | - width: units.gu(6) |
501 | - height: width |
502 | - anchors.verticalCenter: parent.verticalCenter |
503 | - opacity: player.position === 0 ? 0.4 : 1.0 |
504 | - onClicked: { |
505 | - if (player.position > 0) { |
506 | - player.seek(player.position + 15 * 1000); |
507 | - } |
508 | - } |
509 | - |
510 | - Row { |
511 | - spacing: units.gu(1) |
512 | - anchors.centerIn: parent |
513 | - |
514 | - Icon { |
515 | - id: skipForwardIcon |
516 | - width: units.gu(3) |
517 | - height: width |
518 | - name: "media-seek-forward" |
519 | - color: podbird.appTheme.baseIcon |
520 | - } |
521 | - |
522 | - Label { |
523 | - // TRANSLATORS: The string shown in the UI is +15s to denote the number of seconds that the podcast playback will skip forward. |
524 | - // xgettext: no-c-format |
525 | - text: i18n.tr("+%1s").arg("15") |
526 | - fontSize: "xx-small" |
527 | - color: podbird.appTheme.baseText |
528 | - anchors.verticalCenter: skipForwardIcon.verticalCenter |
529 | + bottomMargin: isLandscapeMode ? units.gu(4) : units.gu(2) |
530 | + } |
531 | + |
532 | + Label { |
533 | + id: title |
534 | + anchors.left: parent.left |
535 | + anchors.right: parent.right |
536 | + anchors.top: parent.top |
537 | + text: currentName |
538 | + elide: Text.ElideRight |
539 | + fontSize: "large" |
540 | + maximumLineCount: 2 |
541 | + wrapMode: Text.WordWrap |
542 | + color: podbird.appTheme.baseText |
543 | + } |
544 | + |
545 | + Label { |
546 | + id: artist |
547 | + anchors.left: title.left |
548 | + anchors.right: title.right |
549 | + anchors.top: title.bottom |
550 | + anchors.topMargin: units.gu(1) |
551 | + text: currentArtist |
552 | + elide: Text.ElideRight |
553 | + fontSize: "small" |
554 | + color: podbird.appTheme.baseSubText |
555 | + } |
556 | + |
557 | + Slider { |
558 | + id: scrubber |
559 | + |
560 | + anchors { |
561 | + left: parent.left |
562 | + right: parent.right |
563 | + bottom: controls.top |
564 | + bottomMargin: isLandscapeMode ? units.gu(4) : units.gu(2) |
565 | + } |
566 | + |
567 | + live: true |
568 | + minimumValue: 0 |
569 | + maximumValue: player.duration |
570 | + value: player.position |
571 | + height: units.gu(2) |
572 | + |
573 | + onValueChanged: { |
574 | + if (pressed) { |
575 | + player.seek(value); |
576 | + } |
577 | + } |
578 | + |
579 | + function formatValue(v) { return Podcasts.formatTime(v/1000); } |
580 | + } |
581 | + |
582 | + Connections { |
583 | + target: player |
584 | + onPositionChanged: scrubber.value = player.position |
585 | + } |
586 | + |
587 | + Label { |
588 | + id: startTime |
589 | + fontSize: "small" |
590 | + anchors.left: scrubber.left |
591 | + anchors.top: scrubber.bottom |
592 | + color: podbird.appTheme.baseText |
593 | + text: Podcasts.formatTime(player.position / 1000) |
594 | + } |
595 | + |
596 | + Label { |
597 | + id: endTime |
598 | + fontSize: "small" |
599 | + anchors.right: scrubber.right |
600 | + anchors.top: scrubber.bottom |
601 | + color: podbird.appTheme.baseText |
602 | + text: Podcasts.formatTime(player.duration / 1000) |
603 | + } |
604 | + |
605 | + Row { |
606 | + id: controls |
607 | + |
608 | + anchors.bottom: parent.bottom |
609 | + anchors.horizontalCenter: parent.horizontalCenter |
610 | + spacing: units.gu(2) |
611 | + |
612 | + AbstractButton { |
613 | + id: skipBackwardButton |
614 | + width: units.gu(6) |
615 | + height: width |
616 | + anchors.verticalCenter: parent.verticalCenter |
617 | + opacity: player.position === 0 ? 0.4 : 1.0 |
618 | + onClicked: { |
619 | + if (player.position > 0) { |
620 | + player.seek(player.position - 15 * 1000); |
621 | + } |
622 | + } |
623 | + |
624 | + Row { |
625 | + spacing: units.gu(1) |
626 | + anchors.centerIn: parent |
627 | + |
628 | + Label { |
629 | + // TRANSLATORS: The string shown in the UI is -15s to denote the number of seconds that the podcast playback will skip backward. |
630 | + // xgettext: no-c-format |
631 | + text: i18n.tr("-%1s").arg("15") |
632 | + fontSize: "xx-small" |
633 | + color: podbird.appTheme.baseText |
634 | + anchors.verticalCenter: skipBackwardIcon.verticalCenter |
635 | + } |
636 | + |
637 | + Icon { |
638 | + id: skipBackwardIcon |
639 | + width: units.gu(3) |
640 | + height: width |
641 | + name: "media-seek-backward" |
642 | + color: podbird.appTheme.baseIcon |
643 | + } |
644 | + } |
645 | + } |
646 | + |
647 | + AbstractButton { |
648 | + id: playButton |
649 | + width: units.gu(10) |
650 | + height: width |
651 | + opacity: playButton.pressed ? 0.4 : 1.0 |
652 | + onClicked: player.playbackState === MediaPlayer.PlayingState ? player.pause() : player.play() |
653 | + |
654 | + Icon { |
655 | + id: playIcon |
656 | + width: units.gu(6) |
657 | + height: width |
658 | + anchors.centerIn: parent |
659 | + color: podbird.appTheme.baseIcon |
660 | + name: player.playbackState === MediaPlayer.PlayingState ? "media-playback-pause" |
661 | + : "media-playback-start" |
662 | + } |
663 | + } |
664 | + |
665 | + AbstractButton { |
666 | + id: skipForwardButton |
667 | + width: units.gu(6) |
668 | + height: width |
669 | + anchors.verticalCenter: parent.verticalCenter |
670 | + opacity: player.position === 0 ? 0.4 : 1.0 |
671 | + onClicked: { |
672 | + if (player.position > 0) { |
673 | + player.seek(player.position + 15 * 1000); |
674 | + } |
675 | + } |
676 | + |
677 | + Row { |
678 | + spacing: units.gu(1) |
679 | + anchors.centerIn: parent |
680 | + |
681 | + Icon { |
682 | + id: skipForwardIcon |
683 | + width: units.gu(3) |
684 | + height: width |
685 | + name: "media-seek-forward" |
686 | + color: podbird.appTheme.baseIcon |
687 | + } |
688 | + |
689 | + Label { |
690 | + // TRANSLATORS: The string shown in the UI is +15s to denote the number of seconds that the podcast playback will skip forward. |
691 | + // xgettext: no-c-format |
692 | + text: i18n.tr("+%1s").arg("15") |
693 | + fontSize: "xx-small" |
694 | + color: podbird.appTheme.baseText |
695 | + anchors.verticalCenter: skipForwardIcon.verticalCenter |
696 | + } |
697 | } |
698 | } |
699 | } |
700 | |
701 | === modified file 'po/com.mikeasoft.podbird.pot' |
702 | --- po/com.mikeasoft.podbird.pot 2015-04-28 12:09:05 +0000 |
703 | +++ po/com.mikeasoft.podbird.pot 2015-06-13 16:50:32 +0000 |
704 | @@ -8,7 +8,7 @@ |
705 | msgstr "" |
706 | "Project-Id-Version: \n" |
707 | "Report-Msgid-Bugs-To: \n" |
708 | -"POT-Creation-Date: 2015-04-28 12:08+0000\n" |
709 | +"POT-Creation-Date: 2015-04-28 14:20+0000\n" |
710 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
711 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
712 | "Language-Team: LANGUAGE <LL@li.org>\n" |
713 | @@ -18,25 +18,25 @@ |
714 | "Content-Transfer-Encoding: 8bit\n" |
715 | "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" |
716 | |
717 | -#: ../app/components/Walkthrough.qml:87 |
718 | +#: ../app/components/Walkthrough.qml:91 |
719 | msgid "Skip" |
720 | msgstr "" |
721 | |
722 | #. TRANSLATORS: this refers to a number of songs greater than one. The actual number will be prepended to the string automatically (plural forms are not yet fully supported in usermetrics, the library that displays that string) |
723 | -#: ../app/podbird.qml:165 |
724 | +#: ../app/podbird.qml:166 |
725 | #, qt-format |
726 | msgid "Podcasts listened to today: <b>%1</b>" |
727 | msgstr "" |
728 | |
729 | -#: ../app/podbird.qml:166 |
730 | +#: ../app/podbird.qml:167 |
731 | msgid "No podcasts listened to today" |
732 | msgstr "" |
733 | |
734 | -#: ../app/podbird.qml:228 |
735 | +#: ../app/podbird.qml:229 |
736 | msgid "Add New Podcasts" |
737 | msgstr "" |
738 | |
739 | -#: ../app/podbird.qml:242 |
740 | +#: ../app/podbird.qml:243 |
741 | msgid "Settings" |
742 | msgstr "" |
743 | |
744 | @@ -61,16 +61,16 @@ |
745 | msgstr "" |
746 | |
747 | #. TRANSLATORS: Podbird version number e.g Version 0.6 |
748 | -#: ../app/settings/About.qml:53 |
749 | +#: ../app/settings/About.qml:61 |
750 | #, qt-format |
751 | msgid "Version %1" |
752 | msgstr "" |
753 | |
754 | -#: ../app/settings/About.qml:74 |
755 | +#: ../app/settings/About.qml:82 |
756 | msgid "Released under the terms of the GNU GPL v3" |
757 | msgstr "" |
758 | |
759 | -#: ../app/settings/About.qml:84 |
760 | +#: ../app/settings/About.qml:92 |
761 | #, qt-format |
762 | msgid "Source code available on %1" |
763 | msgstr "" |
764 | @@ -109,21 +109,21 @@ |
765 | msgid "Credits" |
766 | msgstr "" |
767 | |
768 | +#. TRANSLATORS: The first argument is the name of creator of Podbird (Michael Sheldon) |
769 | #: ../app/settings/Credits.qml:33 |
770 | +#, qt-format |
771 | +msgid "%1 (Creator)" |
772 | +msgstr "" |
773 | + |
774 | +#: ../app/settings/Credits.qml:33 ../app/settings/Credits.qml:34 |
775 | msgid "Developers" |
776 | msgstr "" |
777 | |
778 | -#. TRANSLATORS: The first argument is the name of creator of Podbird (Michael Sheldon) |
779 | -#: ../app/settings/Credits.qml:39 |
780 | -#, qt-format |
781 | -msgid "%1 (Creator)" |
782 | -msgstr "" |
783 | - |
784 | -#: ../app/settings/Credits.qml:48 |
785 | +#: ../app/settings/Credits.qml:35 |
786 | msgid "Designer" |
787 | msgstr "" |
788 | |
789 | -#: ../app/settings/Credits.qml:57 |
790 | +#: ../app/settings/Credits.qml:36 |
791 | msgid "Translators" |
792 | msgstr "" |
793 | |
794 | @@ -244,13 +244,13 @@ |
795 | msgstr "" |
796 | |
797 | #. TRANSLATORS: The string shown in the UI is -15s to denote the number of seconds that the podcast playback will skip backward. |
798 | -#: ../app/ui/NowPlayingPage.qml:153 |
799 | +#: ../app/ui/NowPlayingPage.qml:198 |
800 | #, no-c-format, qt-format |
801 | msgid "-%1s" |
802 | msgstr "" |
803 | |
804 | #. TRANSLATORS: The string shown in the UI is +15s to denote the number of seconds that the podcast playback will skip forward. |
805 | -#: ../app/ui/NowPlayingPage.qml:214 |
806 | +#: ../app/ui/NowPlayingPage.qml:259 |
807 | #, no-c-format, qt-format |
808 | msgid "+%1s" |
809 | msgstr "" |
810 | @@ -512,6 +512,6 @@ |
811 | msgid "Finish" |
812 | msgstr "" |
813 | |
814 | -#: /home/krnekhelesh/Documents/Ubuntu-Projects/MP-Reviews/builddir/build-10-rearrange-project-structure-UbuntuSDK_for_armhf_GCC_ubuntu_sdk_15_04_vivid-Default/po/Podbird.desktop.in.h:1 |
815 | +#: /home/krnekhelesh/Documents/Ubuntu-Projects/MP-Reviews/builddir/build-11-enable-rotation-UbuntuSDK_for_armhf_GCC_ubuntu_sdk_15_04_vivid-Default/po/Podbird.desktop.in.h:1 |
816 | msgid "The chirpiest podcast manager for Ubuntu" |
817 | msgstr "" |
As per our conversation on irc, I have disabled automaticOrient ation until the above mentioned upstream bug is fixed.