Merge lp:~vthompson/music-app/fixes-1308048-music-tab-cover-sizes into lp:music-app/trusty
- fixes-1308048-music-tab-cover-sizes
- Merge into trusty
Status: | Merged |
---|---|
Approved by: | Victor Thompson |
Approved revision: | 428 |
Merged at revision: | 428 |
Proposed branch: | lp:~vthompson/music-app/fixes-1308048-music-tab-cover-sizes |
Merge into: | lp:music-app/trusty |
Diff against target: |
694 lines (+339/-339) 1 file modified
MusicStart.qml (+339/-339) |
To merge this branch: | bzr merge lp:~vthompson/music-app/fixes-1308048-music-tab-cover-sizes |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Andrew Hayzen | Approve | ||
Ubuntu Phone Apps Jenkins Bot | continuous-integration | Approve | |
Review via email: mp+215997@code.launchpad.net |
Commit message
Make cover art a bit smaller on the Music tab
Description of the change
Make cover art a bit smaller on the Music tab. Most of the diff is due to fixing spacing issues. To get a better diff execute the following after branching: bzr diff --diff-options='-w' -r425.
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote : | # |
Alan Pope πΊπ§π± π¦ (popey) wrote : | # |
Tested on desktop but not on device. Can someone please confirm it's good on device?
Victor Thompson (vthompson) wrote : | # |
To expedite any opinions, this is what it looks like when the app starts [1] and after the toolbar minimizes a few seconds later [2]. I'm not sure I personally like having smaller icons on the Music tab, but I think it improves the usability issues described in the bug and also makes it easier to see the content while moving through the list quickly.
[1] http://
[2] http://
Nekhelesh Ramananthan (nik90) wrote : | # |
hmm victor how do I run this on device? When I try running it, I get org.nemomobile.
Victor Thompson (vthompson) wrote : | # |
Hi Nekhelesh, the plugins aren't packaged when the click is deployed. You'll need to do the following as root from the phone:
cp -r /usr/share/
Andrew Hayzen (ahayzen) wrote : | # |
Hey Nekhelesh,
Due to confinement we have to run the following command to copy grilo over.
cp -r /usr/share/
click.ubuntu.
(Assuming you have used click-buddy to install the music-app)
Thanks,
Andrew
On 16 April 2014 14:45, Nekhelesh Ramananthan <email address hidden> wrote:
> hmm victor how do I run this on device? When I try running it, I get
> org.nemomobile.
> --
>
> https:/
> Your team Music App Developers is requested to review the proposed merge
> of lp:~vthompson/music-app/fixes-1308048-music-tab-cover-sizes into
> lp:music-app.
>
Andrew Hayzen (ahayzen) wrote : | # |
Looks good to me, it resolves the issue of both the vertical and horizontal scrolls not being initially obvious.
Preview Diff
1 | === modified file 'MusicStart.qml' |
2 | --- MusicStart.qml 2014-03-27 23:44:29 +0000 |
3 | +++ MusicStart.qml 2014-04-16 03:22:43 +0000 |
4 | @@ -63,351 +63,351 @@ |
5 | width: mainpage.width |
6 | height: mainpage.height |
7 | |
8 | - contentHeight: mainView.hasRecent ? recentlyPlayed.height + recentlist.height + genres.height + genrelist.height + albums.height + albumlist.height + units.gu(3) |
9 | - : genres.height + genrelist.height + albums.height + albumlist.height + units.gu(2) |
10 | + contentHeight: mainView.hasRecent ? recentlyPlayed.height + recentlist.height + genres.height + genrelist.height + albums.height + albumlist.height + units.gu(4) |
11 | + : genres.height + genrelist.height + albums.height + albumlist.height + units.gu(3) |
12 | contentWidth: width |
13 | |
14 | focus: true |
15 | |
16 | - ListItem.Standard { |
17 | - id: recentlyPlayed |
18 | - text: i18n.tr("Recent") |
19 | - visible: mainView.hasRecent |
20 | - } |
21 | - |
22 | - ListView { |
23 | - id: recentlist |
24 | - anchors.top: recentlyPlayed.bottom |
25 | - anchors.topMargin: units.gu(1) |
26 | - width: parent.width |
27 | - spacing: units.gu(2) |
28 | - height: units.gu(22) |
29 | - // TODO: Update when view counts are collected |
30 | - model: recentModel.model |
31 | - delegate: recentDelegate |
32 | - header: Item { |
33 | - id: spacer |
34 | - width: units.gu(1) |
35 | - } |
36 | - footer: Item { |
37 | - id: clearRecent |
38 | - width: units.gu(20) |
39 | - height: units.gu(20) |
40 | - visible: mainView.hasRecent && !loading.visible |
41 | - Button { |
42 | - id: clearRecentButton |
43 | - anchors.centerIn: parent |
44 | - text: "Clear History" |
45 | - onClicked: { |
46 | - Library.clearRecentHistory() |
47 | - mainView.hasRecent = false |
48 | - recentModel.filterRecent() |
49 | - } |
50 | - } |
51 | - } |
52 | - orientation: ListView.Horizontal |
53 | - visible: mainView.hasRecent |
54 | - |
55 | - Component { |
56 | - id: recentDelegate |
57 | - Item { |
58 | - property string title: model.title |
59 | - property string title2: model.title2 |
60 | - property var covers: type === "playlist" ? Playlists.getPlaylistCovers(title) : [Library.getAlbumCover(title)] |
61 | - property string type: model.type |
62 | - property string time: model.time |
63 | - property string key: model.key |
64 | - id: recentItem |
65 | - height: units.gu(20) |
66 | - width: units.gu(20) |
67 | - CoverRow { |
68 | - id: recentShape |
69 | - anchors { |
70 | - top: parent.top |
71 | - left: parent.left |
72 | - verticalCenter: parent.verticalCenter |
73 | - } |
74 | - count: recentItem.covers.length |
75 | - size: recentItem.width |
76 | - covers: recentItem.covers |
77 | - spacing: units.gu(2) |
78 | - } |
79 | - UbuntuShape { // Background so can see text in current state |
80 | - id: albumBg2 |
81 | - anchors.bottom: parent.bottom |
82 | - color: styleMusic.common.black |
83 | - height: units.gu(4) |
84 | - width: parent.width |
85 | - } |
86 | - Rectangle { // Background so can see text in current state |
87 | - id: albumBg |
88 | - anchors.bottom: parent.bottom |
89 | - anchors.bottomMargin: units.gu(2) |
90 | - color: styleMusic.common.black |
91 | - height: units.gu(3) |
92 | - width: parent.width |
93 | - } |
94 | - Label { |
95 | - id: albumArtist |
96 | - anchors.bottom: parent.bottom |
97 | - anchors.bottomMargin: units.gu(3) |
98 | - anchors.left: parent.left |
99 | - anchors.leftMargin: units.gu(1) |
100 | - anchors.right: parent.right |
101 | - anchors.rightMargin: units.gu(1) |
102 | - color: styleMusic.common.white |
103 | - elide: Text.ElideRight |
104 | - text: title |
105 | - fontSize: "small" |
106 | - } |
107 | - Label { |
108 | - id: albumLabel |
109 | - anchors.left: parent.left |
110 | - anchors.leftMargin: units.gu(1) |
111 | - anchors.bottom: parent.bottom |
112 | - anchors.bottomMargin: units.gu(1) |
113 | - anchors.right: parent.right |
114 | - anchors.rightMargin: units.gu(1) |
115 | - color: styleMusic.nowPlaying.labelSecondaryColor |
116 | - elide: Text.ElideRight |
117 | - text: title2 |
118 | - fontSize: "x-small" |
119 | - } |
120 | - MouseArea { |
121 | - anchors.fill: parent |
122 | - onClicked: { |
123 | - if (type === "playlist") { |
124 | - albumTracksModel.filterPlaylistTracks(key) |
125 | - } else { |
126 | - albumTracksModel.filterAlbumTracks(title) |
127 | - } |
128 | - |
129 | - songsSheet.line1 = title2 |
130 | - songsSheet.line2 = title |
131 | - songsSheet.covers = recentItem.covers |
132 | - PopupUtils.open(songsSheet.sheet) |
133 | - songsSheet.isAlbum = (type === "album") |
134 | - } |
135 | - } |
136 | - } |
137 | - } |
138 | - } |
139 | - |
140 | - ListItem.ThinDivider { |
141 | - id: genreDivider |
142 | - anchors.top: mainView.hasRecent ? recentlist.bottom : parent.top |
143 | - } |
144 | - ListItem.Standard { |
145 | - id: genres |
146 | - anchors.top: genreDivider.bottom |
147 | - text: i18n.tr("Genres") |
148 | - } |
149 | - // TODO: add music genres. frequency of play? most tracks? |
150 | - ListView { |
151 | - id: genrelist |
152 | - width: parent.width |
153 | - anchors.top: genres.bottom |
154 | - anchors.topMargin: units.gu(1) |
155 | - spacing: units.gu(2) |
156 | - height: units.gu(22) |
157 | - model: genreModel.model |
158 | - delegate: genreDelegate |
159 | - header: Item { |
160 | - id: spacer |
161 | - width: units.gu(1) |
162 | - } |
163 | - orientation: ListView.Horizontal |
164 | - |
165 | - Component { |
166 | - id: genreDelegate |
167 | - Item { |
168 | - property string artist: model.artist |
169 | - property string album: model.album |
170 | - property string title: model.title |
171 | - property var covers: Library.getGenreCovers(model.genre) |
172 | - property string length: model.length |
173 | - property string file: model.file |
174 | - property string year: model.year |
175 | - property string genre: model.genre |
176 | - |
177 | - id: genreItem |
178 | - objectName: "genreItemObject" |
179 | - height: units.gu(20) |
180 | - width: units.gu(20) |
181 | - CoverRow { |
182 | - id: genreShape |
183 | - anchors { |
184 | - top: parent.top |
185 | - left: parent.left |
186 | - verticalCenter: parent.verticalCenter |
187 | - } |
188 | - count: genreItem.covers.length |
189 | - size: genreItem.width |
190 | - covers: genreItem.covers |
191 | - spacing: units.gu(2) |
192 | - } |
193 | - MouseArea { |
194 | - anchors.fill: parent |
195 | - onClicked: { |
196 | - albumTracksModel.filterGenreTracks(genre) |
197 | - songsSheet.line1 = "Genre" |
198 | - songsSheet.line2 = genre |
199 | - songsSheet.isAlbum = false |
200 | - songsSheet.covers = covers |
201 | - PopupUtils.open(songsSheet.sheet) |
202 | - } |
203 | - } |
204 | - Rectangle { // Background so can see text in current state |
205 | - id: genreBg |
206 | - anchors.bottom: parent.bottom |
207 | - anchors.bottomMargin: units.gu(2) |
208 | - color: styleMusic.common.black |
209 | - height: units.gu(3) |
210 | - width: parent.width |
211 | - } |
212 | - UbuntuShape { // Background so can see text in current state |
213 | - id: genreBg2 |
214 | - anchors.bottom: parent.bottom |
215 | - color: styleMusic.common.black |
216 | - height: units.gu(4) |
217 | - width: parent.width |
218 | - } |
219 | - Label { |
220 | - id: genreLabel |
221 | - anchors.bottom: parent.bottom |
222 | - anchors.bottomMargin: units.gu(1) |
223 | - anchors.left: parent.left |
224 | - anchors.leftMargin: units.gu(1) |
225 | - anchors.right: parent.right |
226 | - anchors.rightMargin: units.gu(1) |
227 | - color: styleMusic.common.white |
228 | - elide: Text.ElideRight |
229 | - text: genre |
230 | - fontSize: "small" |
231 | - } |
232 | - Label { |
233 | - id: genreTotal |
234 | - anchors.bottom: parent.bottom |
235 | - anchors.bottomMargin: units.gu(3) |
236 | - anchors.left: parent.left |
237 | - anchors.leftMargin: units.gu(1) |
238 | - anchors.right: parent.right |
239 | - anchors.rightMargin: units.gu(1) |
240 | - color: styleMusic.nowPlaying.labelSecondaryColor |
241 | - elide: Text.ElideRight |
242 | - text: i18n.tr("%1 song", "%1 songs", model.total).arg(model.total) |
243 | - fontSize: "x-small" |
244 | - } |
245 | - } |
246 | - } |
247 | - } |
248 | - |
249 | - ListItem.ThinDivider { |
250 | - id: albumsDivider |
251 | - anchors.top: genrelist.bottom |
252 | - } |
253 | - ListItem.Standard { |
254 | - id: albums |
255 | - text: i18n.tr("Albums") |
256 | - anchors.top: albumsDivider.bottom |
257 | - } |
258 | - |
259 | - ListView { |
260 | - id: albumlist |
261 | - width: parent.width |
262 | - anchors.top: albums.bottom |
263 | - anchors.topMargin: units.gu(1) |
264 | - spacing: units.gu(2) |
265 | - height: units.gu(22) |
266 | - model: albumModel.model |
267 | - delegate: albumDelegate |
268 | - header: Item { |
269 | - id: albumSpacer |
270 | - width: units.gu(1) |
271 | - } |
272 | - orientation: ListView.Horizontal |
273 | - |
274 | - Component { |
275 | - id: albumDelegate |
276 | - Item { |
277 | - property string artist: model.artist |
278 | - property string album: model.album |
279 | - property var covers: [Library.getAlbumCover(album)] |
280 | - property string length: model.length |
281 | - property string file: model.file |
282 | - property string year: model.year |
283 | - property string genre: model.genre |
284 | - |
285 | - id: albumItem |
286 | - objectName: "albumItemObject" |
287 | - height: units.gu(20) |
288 | - width: units.gu(20) |
289 | - CoverRow { |
290 | - id: albumShape |
291 | - anchors { |
292 | - top: parent.top |
293 | - left: parent.left |
294 | - verticalCenter: parent.verticalCenter |
295 | - } |
296 | - count: albumItem.covers.length |
297 | - size: albumItem.width |
298 | - covers: albumItem.covers |
299 | - spacing: units.gu(2) |
300 | - } |
301 | - MouseArea { |
302 | - anchors.fill: parent |
303 | - onClicked: { |
304 | - albumTracksModel.filterAlbumTracks(album) |
305 | - songsSheet.line1 = artist |
306 | - songsSheet.line2 = album |
307 | - songsSheet.isAlbum = true |
308 | - songsSheet.covers = covers |
309 | - PopupUtils.open(songsSheet.sheet) |
310 | - } |
311 | - } |
312 | - Rectangle { // Background so can see text in current state |
313 | - id: albumBg |
314 | - anchors.bottom: parent.bottom |
315 | - anchors.bottomMargin: units.gu(2) |
316 | - color: styleMusic.common.black |
317 | - height: units.gu(3) |
318 | - width: parent.width |
319 | - } |
320 | - UbuntuShape { // Background so can see text in current state |
321 | - id: albumBg2 |
322 | - anchors.bottom: parent.bottom |
323 | - color: styleMusic.common.black |
324 | - height: units.gu(4) |
325 | - width: parent.width |
326 | - } |
327 | - Label { |
328 | - id: albumLabel |
329 | - anchors.bottom: parent.bottom |
330 | - anchors.bottomMargin: units.gu(1) |
331 | - anchors.left: parent.left |
332 | - anchors.leftMargin: units.gu(1) |
333 | - anchors.right: parent.right |
334 | - anchors.rightMargin: units.gu(1) |
335 | - color: styleMusic.nowPlaying.labelSecondaryColor |
336 | - elide: Text.ElideRight |
337 | - text: artist |
338 | - fontSize: "x-small" |
339 | - } |
340 | - Label { |
341 | - id: albumLabel2 |
342 | - anchors.bottom: parent.bottom |
343 | - anchors.bottomMargin: units.gu(3) |
344 | - anchors.left: parent.left |
345 | - anchors.leftMargin: units.gu(1) |
346 | - anchors.right: parent.right |
347 | - anchors.rightMargin: units.gu(1) |
348 | - color: styleMusic.common.white |
349 | - elide: Text.ElideRight |
350 | - text: album |
351 | - fontSize: "small" |
352 | - } |
353 | + ListItem.Standard { |
354 | + id: recentlyPlayed |
355 | + text: i18n.tr("Recent") |
356 | + visible: mainView.hasRecent |
357 | + } |
358 | + |
359 | + ListView { |
360 | + id: recentlist |
361 | + anchors.top: recentlyPlayed.bottom |
362 | + anchors.topMargin: units.gu(1) |
363 | + width: parent.width |
364 | + spacing: units.gu(1) |
365 | + height: units.gu(18) |
366 | + // TODO: Update when view counts are collected |
367 | + model: recentModel.model |
368 | + delegate: recentDelegate |
369 | + header: Item { |
370 | + id: spacer |
371 | + width: units.gu(1) |
372 | + } |
373 | + footer: Item { |
374 | + id: clearRecent |
375 | + width: recentlist.height - units.gu(2) |
376 | + height: width |
377 | + visible: mainView.hasRecent && !loading.visible |
378 | + Button { |
379 | + id: clearRecentButton |
380 | + anchors.centerIn: parent |
381 | + text: "Clear History" |
382 | + onClicked: { |
383 | + Library.clearRecentHistory() |
384 | + mainView.hasRecent = false |
385 | + recentModel.filterRecent() |
386 | + } |
387 | + } |
388 | + } |
389 | + orientation: ListView.Horizontal |
390 | + visible: mainView.hasRecent |
391 | + |
392 | + Component { |
393 | + id: recentDelegate |
394 | + Item { |
395 | + property string title: model.title |
396 | + property string title2: model.title2 |
397 | + property var covers: type === "playlist" ? Playlists.getPlaylistCovers(title) : [Library.getAlbumCover(title)] |
398 | + property string type: model.type |
399 | + property string time: model.time |
400 | + property string key: model.key |
401 | + id: recentItem |
402 | + height: recentlist.height - units.gu(1) |
403 | + width: height |
404 | + CoverRow { |
405 | + id: recentShape |
406 | + anchors { |
407 | + top: parent.top |
408 | + left: parent.left |
409 | + verticalCenter: parent.verticalCenter |
410 | + } |
411 | + count: recentItem.covers.length |
412 | + size: recentItem.width |
413 | + covers: recentItem.covers |
414 | + spacing: units.gu(2) |
415 | + } |
416 | + UbuntuShape { // Background so can see text in current state |
417 | + id: albumBg2 |
418 | + anchors.bottom: parent.bottom |
419 | + color: styleMusic.common.black |
420 | + height: units.gu(4) |
421 | + width: parent.width |
422 | + } |
423 | + Rectangle { // Background so can see text in current state |
424 | + id: albumBg |
425 | + anchors.bottom: parent.bottom |
426 | + anchors.bottomMargin: units.gu(2) |
427 | + color: styleMusic.common.black |
428 | + height: units.gu(3) |
429 | + width: parent.width |
430 | + } |
431 | + Label { |
432 | + id: albumArtist |
433 | + anchors.bottom: parent.bottom |
434 | + anchors.bottomMargin: units.gu(3) |
435 | + anchors.left: parent.left |
436 | + anchors.leftMargin: units.gu(1) |
437 | + anchors.right: parent.right |
438 | + anchors.rightMargin: units.gu(1) |
439 | + color: styleMusic.common.white |
440 | + elide: Text.ElideRight |
441 | + text: title |
442 | + fontSize: "small" |
443 | + } |
444 | + Label { |
445 | + id: albumLabel |
446 | + anchors.left: parent.left |
447 | + anchors.leftMargin: units.gu(1) |
448 | + anchors.bottom: parent.bottom |
449 | + anchors.bottomMargin: units.gu(1) |
450 | + anchors.right: parent.right |
451 | + anchors.rightMargin: units.gu(1) |
452 | + color: styleMusic.nowPlaying.labelSecondaryColor |
453 | + elide: Text.ElideRight |
454 | + text: title2 |
455 | + fontSize: "x-small" |
456 | + } |
457 | + MouseArea { |
458 | + anchors.fill: parent |
459 | + onClicked: { |
460 | + if (type === "playlist") { |
461 | + albumTracksModel.filterPlaylistTracks(key) |
462 | + } else { |
463 | + albumTracksModel.filterAlbumTracks(title) |
464 | + } |
465 | + |
466 | + songsSheet.line1 = title2 |
467 | + songsSheet.line2 = title |
468 | + songsSheet.covers = recentItem.covers |
469 | + PopupUtils.open(songsSheet.sheet) |
470 | + songsSheet.isAlbum = (type === "album") |
471 | + } |
472 | + } |
473 | + } |
474 | + } |
475 | + } |
476 | + |
477 | + ListItem.ThinDivider { |
478 | + id: genreDivider |
479 | + anchors.top: mainView.hasRecent ? recentlist.bottom : parent.top |
480 | + } |
481 | + ListItem.Standard { |
482 | + id: genres |
483 | + anchors.top: genreDivider.bottom |
484 | + text: i18n.tr("Genres") |
485 | + } |
486 | + // TODO: add music genres. frequency of play? most tracks? |
487 | + ListView { |
488 | + id: genrelist |
489 | + width: parent.width |
490 | + anchors.top: genres.bottom |
491 | + anchors.topMargin: units.gu(1) |
492 | + spacing: units.gu(1) |
493 | + height: units.gu(18) |
494 | + model: genreModel.model |
495 | + delegate: genreDelegate |
496 | + header: Item { |
497 | + id: spacer |
498 | + width: units.gu(1) |
499 | + } |
500 | + orientation: ListView.Horizontal |
501 | + |
502 | + Component { |
503 | + id: genreDelegate |
504 | + Item { |
505 | + property string artist: model.artist |
506 | + property string album: model.album |
507 | + property string title: model.title |
508 | + property var covers: Library.getGenreCovers(model.genre) |
509 | + property string length: model.length |
510 | + property string file: model.file |
511 | + property string year: model.year |
512 | + property string genre: model.genre |
513 | + |
514 | + id: genreItem |
515 | + objectName: "genreItemObject" |
516 | + height: genrelist.height - units.gu(1) |
517 | + width: height |
518 | + CoverRow { |
519 | + id: genreShape |
520 | + anchors { |
521 | + top: parent.top |
522 | + left: parent.left |
523 | + verticalCenter: parent.verticalCenter |
524 | + } |
525 | + count: genreItem.covers.length |
526 | + size: genreItem.width |
527 | + covers: genreItem.covers |
528 | + spacing: units.gu(2) |
529 | + } |
530 | + MouseArea { |
531 | + anchors.fill: parent |
532 | + onClicked: { |
533 | + albumTracksModel.filterGenreTracks(genre) |
534 | + songsSheet.line1 = "Genre" |
535 | + songsSheet.line2 = genre |
536 | + songsSheet.isAlbum = false |
537 | + songsSheet.covers = covers |
538 | + PopupUtils.open(songsSheet.sheet) |
539 | + } |
540 | + } |
541 | + Rectangle { // Background so can see text in current state |
542 | + id: genreBg |
543 | + anchors.bottom: parent.bottom |
544 | + anchors.bottomMargin: units.gu(2) |
545 | + color: styleMusic.common.black |
546 | + height: units.gu(3) |
547 | + width: parent.width |
548 | + } |
549 | + UbuntuShape { // Background so can see text in current state |
550 | + id: genreBg2 |
551 | + anchors.bottom: parent.bottom |
552 | + color: styleMusic.common.black |
553 | + height: units.gu(4) |
554 | + width: parent.width |
555 | + } |
556 | + Label { |
557 | + id: genreLabel |
558 | + anchors.bottom: parent.bottom |
559 | + anchors.bottomMargin: units.gu(1) |
560 | + anchors.left: parent.left |
561 | + anchors.leftMargin: units.gu(1) |
562 | + anchors.right: parent.right |
563 | + anchors.rightMargin: units.gu(1) |
564 | + color: styleMusic.common.white |
565 | + elide: Text.ElideRight |
566 | + text: genre |
567 | + fontSize: "small" |
568 | + } |
569 | + Label { |
570 | + id: genreTotal |
571 | + anchors.bottom: parent.bottom |
572 | + anchors.bottomMargin: units.gu(3) |
573 | + anchors.left: parent.left |
574 | + anchors.leftMargin: units.gu(1) |
575 | + anchors.right: parent.right |
576 | + anchors.rightMargin: units.gu(1) |
577 | + color: styleMusic.nowPlaying.labelSecondaryColor |
578 | + elide: Text.ElideRight |
579 | + text: i18n.tr("%1 song", "%1 songs", model.total).arg(model.total) |
580 | + fontSize: "x-small" |
581 | + } |
582 | + } |
583 | + } |
584 | + } |
585 | + |
586 | + ListItem.ThinDivider { |
587 | + id: albumsDivider |
588 | + anchors.top: genrelist.bottom |
589 | + } |
590 | + ListItem.Standard { |
591 | + id: albums |
592 | + text: i18n.tr("Albums") |
593 | + anchors.top: albumsDivider.bottom |
594 | + } |
595 | + |
596 | + ListView { |
597 | + id: albumlist |
598 | + width: parent.width |
599 | + anchors.top: albums.bottom |
600 | + anchors.topMargin: units.gu(1) |
601 | + spacing: units.gu(1) |
602 | + height: units.gu(18) |
603 | + model: albumModel.model |
604 | + delegate: albumDelegate |
605 | + header: Item { |
606 | + id: albumSpacer |
607 | + width: units.gu(1) |
608 | + } |
609 | + orientation: ListView.Horizontal |
610 | + |
611 | + Component { |
612 | + id: albumDelegate |
613 | + Item { |
614 | + property string artist: model.artist |
615 | + property string album: model.album |
616 | + property var covers: [Library.getAlbumCover(album)] |
617 | + property string length: model.length |
618 | + property string file: model.file |
619 | + property string year: model.year |
620 | + property string genre: model.genre |
621 | + |
622 | + id: albumItem |
623 | + objectName: "albumItemObject" |
624 | + height: albumlist.height - units.gu(1) |
625 | + width: height |
626 | + CoverRow { |
627 | + id: albumShape |
628 | + anchors { |
629 | + top: parent.top |
630 | + left: parent.left |
631 | + verticalCenter: parent.verticalCenter |
632 | + } |
633 | + count: albumItem.covers.length |
634 | + size: albumItem.width |
635 | + covers: albumItem.covers |
636 | + spacing: units.gu(2) |
637 | + } |
638 | + MouseArea { |
639 | + anchors.fill: parent |
640 | + onClicked: { |
641 | + albumTracksModel.filterAlbumTracks(album) |
642 | + songsSheet.line1 = artist |
643 | + songsSheet.line2 = album |
644 | + songsSheet.isAlbum = true |
645 | + songsSheet.covers = covers |
646 | + PopupUtils.open(songsSheet.sheet) |
647 | + } |
648 | + } |
649 | + Rectangle { // Background so can see text in current state |
650 | + id: albumBg |
651 | + anchors.bottom: parent.bottom |
652 | + anchors.bottomMargin: units.gu(2) |
653 | + color: styleMusic.common.black |
654 | + height: units.gu(3) |
655 | + width: parent.width |
656 | + } |
657 | + UbuntuShape { // Background so can see text in current state |
658 | + id: albumBg2 |
659 | + anchors.bottom: parent.bottom |
660 | + color: styleMusic.common.black |
661 | + height: units.gu(4) |
662 | + width: parent.width |
663 | + } |
664 | + Label { |
665 | + id: albumLabel |
666 | + anchors.bottom: parent.bottom |
667 | + anchors.bottomMargin: units.gu(1) |
668 | + anchors.left: parent.left |
669 | + anchors.leftMargin: units.gu(1) |
670 | + anchors.right: parent.right |
671 | + anchors.rightMargin: units.gu(1) |
672 | + color: styleMusic.nowPlaying.labelSecondaryColor |
673 | + elide: Text.ElideRight |
674 | + text: artist |
675 | + fontSize: "x-small" |
676 | + } |
677 | + Label { |
678 | + id: albumLabel2 |
679 | + anchors.bottom: parent.bottom |
680 | + anchors.bottomMargin: units.gu(3) |
681 | + anchors.left: parent.left |
682 | + anchors.leftMargin: units.gu(1) |
683 | + anchors.right: parent.right |
684 | + anchors.rightMargin: units.gu(1) |
685 | + color: styleMusic.common.white |
686 | + elide: Text.ElideRight |
687 | + text: album |
688 | + fontSize: "small" |
689 | } |
690 | } |
691 | } |
692 | } |
693 | } |
694 | +} |
PASSED: Continuous integration, rev:428 91.189. 93.70:8080/ job/music- app-ci/ 722/ 91.189. 93.70:8080/ job/generic- mediumtests- trusty/ 2136 91.189. 93.70:8080/ job/music- app-raring- amd64-ci/ 722 91.189. 93.70:8080/ job/music- app-saucy- amd64-ci/ 724 91.189. 93.70:8080/ job/music- app-trusty- amd64-ci/ 443
http://
Executed test runs:
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
SUCCESS: http://
Click here to trigger a rebuild: 91.189. 93.70:8080/ job/music- app-ci/ 722/rebuild
http://